Questions tagged [toggle]
To toggle a boolean variable is to switch it to its opposite state. If it is on, switch it off; if it is off, switch it on. In a desktop or web user interface, a toggle may be clickable switch or button that alternates the state of something in the application.
toggle
5,939
questions
0
votes
2
answers
41
views
Create Toggle to disable/enable class site wide?
I am trying to create a toggle that disables one class connected to a tag similar to the theme toggle I already have. Turning it off would disable the colored text for easier reading (I like it, ...
1
vote
1
answer
42
views
SwiftUI: Toggle inside List does not use full width in iOS 18 [duplicate]
I'm trying to have a View inside a List occupying the full width of the screen.
The standalone view does. Once in a List, it takes ~60% of the available space.
I tried already to use .frame(minWidth: ....
0
votes
0
answers
8
views
Divs eventlistner and Toggle
Please I am having issues with my code, I have 4 div which are flexed and I also have a read more button in each of the div and a P in each div that do not display until the button is clicked my ...
0
votes
1
answer
27
views
Switch toggle gets toggled off
I have a series of toggles in a recycler view(with individual terms and conditions) and one main toggle(to acknowlege all the terms and conditions).
If the main toggle is on or off, the rest of the ...
0
votes
1
answer
28
views
How can i switch between 2 react components on the same page?
I'm trying to create a Login and Sign Up page in React Js, the idea is that that they should be rendered on the same page, and user should be able to switch between them (something like this example:...
1
vote
0
answers
31
views
Error messages show when they are not suppose to show
I am starting to learn and I am coding a frontend mentor challenge which is almost done. It is an age calculator and I want the error messages to show when the input is not a number or when the number ...
1
vote
1
answer
40
views
I need two HTML tags so that one is visible when the other is hidden, and vice-versa
I am creating a page to learn Japanese words. Each word is contextualized within a sentence like this one.
故郷に手紙を出す write home to one's family
I made it so that I can only see the phonetic reading ...
0
votes
0
answers
51
views
What design pattern would this be, and is it a good idea for run-time selection?
We have a very common calculation Compute that can be done multiple ways. These inherit from some IFoo interface. We'll call them FooRed and FooBlue.
class FooRed : public IFoo
{
public:
FooRed() = ...
0
votes
0
answers
22
views
ion-menu not showing after clicking button
I'm working with Angular and trying to add a profile icon to the navbar. This icon should display options when clicking on it. I'm not using the Router outlet to open the menu from another Angular ...
0
votes
1
answer
49
views
HTML Buttons to make a show button act as a hide button as well as a show button
If you have a show button that when clicked shows a picture, how would you then make that button also act as a hide button to show the original picture like a hide reset sort of thing. below is my ...
-1
votes
1
answer
50
views
Class added by javascript but css not applied? [closed]
I am going to create a toggle menu using javascript and css
A class .menu-slider add with property display blok. But it's not working only class teggled and css not applied
Here is the code
<script&...
0
votes
1
answer
92
views
When I translate during the dark mode, background property disappears from card-content in Angular
`In my angular project, I did a toggle-switch via <mat-slide-toggle></mat-slide-toggle> for switching between dark mode and light mode. However, when I translate my application during dark ...
0
votes
0
answers
27
views
How can I add a toggle to switch on and off the display of my class?
I have problems integrating a .toggle to switch on and off my display for my class. Is it maybe something else ?
I tried to include .toggle in my line, but it doesnt seem to work, and mdn does not ...
0
votes
3
answers
91
views
Why does my Javascript not work when trying to toggle classes?
When I try to apply this code, which works perfectly fine on its own,
<style>
.ces-smiley {
cursor: pointer;
transition: stroke-width 0.3s, stroke 0.3s;
}
.selected ...
0
votes
0
answers
18
views
Is it possible to change multiple div elements' classes/properties with one button click?
I am looking to create my own toggle/accordion but it needs a background image that covers the module when closed with the H1 positioned in the middle over the image and a toggle button to the right.
...