5,940 questions
1
vote
1
answer
58
views
Coloring the SwiftUI Toggle in macOS26 no longer works
on macOS26 / 26.1 Tahoe the Toggle stopped being colored / tinted by using modifier
.tint(toggleColor())
it just remains with the current system color... e.g. blue or the tint central to the whole ...
-4
votes
1
answer
74
views
I tried everything and I just wanna toggle my elements [closed]
I'm doing a mini project for a coding bootcamp and I'm trying to toggle elements.
I have a form on my page that I want to make invisible when you submit it, so that the rest of the page shows. It isn'...
0
votes
1
answer
93
views
Visibility of TextField label compared to Picker or Toggle in SwiftUI
If I place a Picker or a Toggle in a SwiftUI Form, the associated label is always visible:
But for a TextField, the label is only shown while the field is empty:
And as soon as I start to fill in ...
3
votes
2
answers
64
views
Why does this collapsible need 2 clicks to open, then 2 more clicks to close?
Description
I'm having an issue with a collapsible requiring 2 clicks of a button to open, then another 2 clicks to close. The Show/Hide text inside the button gets mixed up as well. I think it might ...
1
vote
1
answer
40
views
how to detect formly toggle field type is disabled?
I have a formly form with toggle field, I would like to detect when the user clicks on the toggle to disable it.
here is what I have done so far:
fields: {
key: myToggle,
...
5
votes
3
answers
153
views
Toggle switch with sliding background and labels of dynamic length
With Vue.js I'm trying to replicate this toggle button from TailGrids:
This kind of switch isn't among the TailGrids examples. I was able to reproduce the general style with Tailwind. I also found ...
0
votes
1
answer
80
views
How do I use Local Storage to save the state of a toggled class?
I'm trying use to use Local storage to save whether or not my class="crt" has been set or not for my comic's website resulting it in it either showing or not showing.
I only have a basic ...
1
vote
3
answers
63
views
CSS Toggle stopping halfway to the right so it's not covering the icon
I am making a theme toggle switch but when i click on the toggle button, it's not reaching the right end making some part of the icon visible. The left side is okay so it's only the right side.
I have ...
1
vote
1
answer
53
views
How to change toggle for some words in a string
I am tidying up my Ancestry tree, and have access to the SQL using SQLite.
I would like to standardize the descriptions I have for their census information.
For example I have
Relationship: Wife. ...
0
votes
1
answer
89
views
Buttons And Drop-Down Using Same Show/Hide jQuery With Conflicting Results - How To Mediate Issue
https://codepen.io/wammygiveaway/pen/VYwrRwG
What you are seeing is a jQuery version of a show-hide toggle created by user Kurt in response to a question from user1575698 on toggling multiple IDs. ...
1
vote
0
answers
178
views
Instantly switch between light and dark mode with Google Maps JS API using mapID
I previously used darkmode.addEventListener('change', ({ matches }) => map.setOptions({ styles: matches ? darkmodeStyles : null })); which worked great! But since Google Maps is deprecating google....
0
votes
1
answer
53
views
Custom Dropdown Remains Selected Even After Clicking Clear Button
I am building a custom dropdown menu using JavaScript and CSS, and I want the clear button to reset the selection. However, even after clicking the clear button, the dropdown remains selected, and the ...
2
votes
1
answer
67
views
Unable to create a toggle for gridlines on MatplotLib Python
I've been trying to make a toggle button to turn on and off the gridlines on my graph every time it's clicked. I understand how the toggle works as I was able to do it for some lines being animated ...
0
votes
1
answer
54
views
Angular Material 3 change slider toggle colors
Changes from material 2 to 3 breaked a lot of customized color changes.
I know that the main idea in material is to use themes, but I don't want to use a complex configuration to simply change an ...
-2
votes
1
answer
48
views
return event on second toggle
I have a burgermenu with an overlay using toggle to activate the overlay (upper right):
https://pitchlab.net/
I used JS to rotate the burgermenu on toggle... the overlay/menu slides down .but i cant ...
-1
votes
1
answer
91
views
Issues updating an element inside a struct within an array using a toggle in swiftui
Hi I'm a beginner coder in Swift and SwiftUI so I'm pretty sure this problem is due to a fundamental misunderstanding of what I'm doing. I'm trying to use a toggle to update a bool element of a struct ...
-1
votes
3
answers
182
views
How to show the number of toggles selected
I'm creating a list of toggles independent of each other. After the user selects all the relevant toggles, I like to create a button that add up the number of toggles selected.
I also like to assign a ...
0
votes
2
answers
73
views
LottieSwitch height
Im trying to place LottieSwitches on top of each other in a VStack with SwiftUI and it's leaving a larger vertical gap between the switches. Using .frame(height: XX) is correctly changing the height ...
1
vote
0
answers
153
views
Unable to setup PIRANHA BY UBER to remove stale code in my demo application
I am trying to setup PIRANHA BY UBER on my local for a demo java (Java 8) application. I am not able to perform a remove the stale code by building it.
Demo Application:
@Controller
public class ...
0
votes
1
answer
46
views
addEventListener in a keyboard button project
I have a mini project about a keyboard, I want to know how I can add the addEventListener in my JavaScript code to if I press a key in my own keyboard, show that button in my project and change the ...
0
votes
1
answer
963
views
Toggle Toolbar in Jupyter Notebook
I would like to toggle the toolbar in Jupyter Notebook (version 7.2.2). I know this function was present back in the day but now in the View menu there is only "Toggle Zen Mode".
Is there a ...
0
votes
1
answer
58
views
toggle many hidden objects at once
I have a blue square and when I hover over it, two other objects should appear.
So far, only one object (the text) appears and the other one (the red square) remains hidden.
How do I make that on ...
0
votes
2
answers
118
views
how to remove class from selected dom's siblings? how to open a div and have all the other ones close? do i use siblings() or what
i have this grid with 3 columns, and i wanted to make it so that when i click one of the divs it'll go down a row and span the whole row, it also closes back up when i click on it again. and i got ...
0
votes
3
answers
81
views
How to improve my JavaScript for my Accordion Menu to open
What am I doing wrong? Any idea how to make this accordion menu work?
I’ve been trying to figure out why my accordion menu for a Frontend Challenge isn’t working. It's currently throwing the following ...
0
votes
1
answer
74
views
I just want to show/hide my divs, but I'm having issues with my variables. Any ideas?
I'm making a mini project for a coding class, featuring a list of poems. I set the poems in divs and the divs in a section (per a suggestion), and I want to toggle the poems' text and images so that ...
1
vote
1
answer
380
views
Pi Pico PWM function and toggle() pin function
I am trying to write a program for the pi pico using Micropython to send pwm signals to a mosfet module to turn it on and off to send pulsed current through a DC electromagnet. The MOSFET switches ...
0
votes
1
answer
62
views
How do I call toggle method from a child component rendered inside parent containing ng_bootstrap accordion unit?
I'm trying to make an accordion with three sections, each of which has a collapsible component. From the ng_bootstrap docs, you can render a button outside of the ngbAccordion parent div, like this:
&...
0
votes
1
answer
72
views
Toggle button in Excel not actioning, but name is updating
I have two toggle buttons, one to hide some rows (tagged in column B with 2) and another to hide other rows (tagged in column B with 3) The button was working last week, but this morning it's stopped.
...
0
votes
2
answers
84
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
340
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
1
answer
41
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
37
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
36
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
51
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
54
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
1
answer
157
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
53
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
114
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
1
answer
39
views
Why is "toggle()" function not producing the same result as explicitly writing out a toggle?
The following block works:
Main File
import SwiftUI
struct Home: View {
@State private var ToDoItems: [ToDoItem] = [ToDoItem(title: "Task", description: "Need to do", urgent: ...
1
vote
0
answers
93
views
How can i Assign all prefabs with a certain Tag to a List in Unity?
Im developing a Game in Unity and currently im having a hard time making the inventory System Work. Im a beginner in Unity so the problem is possiblie something obvious to some of you.
The inventory ...
0
votes
1
answer
234
views
JavaScript remove Attribute or Property won"t work
The first step to open the menu works. But when i want to close it again it won't remove the inline style. Tried different ways to get the result but nothing of it will work.
CSS has just some text-...
0
votes
2
answers
107
views
Selecting all elements by specific class name and using toggle to change the class name
Desired Outcome
I want to be able to dynamicly select all the elements with the classname of "input" and change said class name to "input-dm" utilizing toggle. This is for a toggle ...
0
votes
1
answer
66
views
Toggle Different Classes Sequentially
Well i am trying to create a button that you can click more then 2 times..
This seems to work but only changes two classes.
$("#button").click(function() {
$('.box1').toggleClass('box4, box2, ...
0
votes
1
answer
98
views
How do I get the link text value to toggle using jQuery?
I have a large block of text with half of the text hidden. I'm using a Bootstrap 5x toggle to show and hide the block of text. This works fine.
However, I am also trying to change the button text from ...
0
votes
1
answer
40
views
React useState as a toggle triggers Re-render and re-initializes false on re-render
I have a simple question.
I am using a React toggle function based on useState toggle the rendering of a component.
It works, but on the Re-render of the parent component where the toggle function is ...
0
votes
1
answer
96
views
enable button with state of toggle
I am working on typescript with React and I am bit new. I have a button that has to be enable if the switch is off and on different valid states for when the switch is on. The valid states for when ...
0
votes
0
answers
44
views
Button in Header.vue that opens a Modal
The task is to create a Button, which opens a Modal. When I click the button, nothing opens. Can anyonee help? I have added the Button to the navbar of the header.vue component. I deleted the code for ...
-1
votes
1
answer
66
views
React using toggle switch to change state of sibling components
I'm working on an app where I want to change a value from lbs to kgs. I currently have the state set to lbs and am trying to add a toggle switch which will allow users to toggle between lbs and kgs. I'...
1
vote
3
answers
185
views
AJAX and PHP toggle button state not working properly
I am fairly new to AJAX and struggling with this thing which i believe is rather a problem with toggle.php. I have this code which works for the most part. But when page is reloaded manually and ...
0
votes
2
answers
229
views
Toggle Button With Props & emit
this is my first time using props and I can't figure out what's the problem
I want to make a component of the toggle button and then use it anywhere with an entry data,
but it doesn't work as I expect
...