Skip to content

Conversation

@jdufresne
Copy link
Contributor

Every instance of djToggleSwitch uses the same text to represent open &
close. Therefore, parameterizing it adds unnecessary HTML to each use. Now,
simply assume "-" and "+" will be used.

Should new uses of djToggleSwitch be added, this reduces the amount of
copy & paste necessary.

Every instance of djToggleSwitch uses the same text to represent open &
close. Therefore, parameterizing it adds unnecessary HTML to use. Now,
simply assume "-" and "+" will be used.

Should new uses of djToggleSwitch be added, this reduces the amount of
copy & paste necessary.
@matthiask
Copy link
Member

I haven't found a reason why these attributes were added in the first place; removing them (and simplifying the code) makes sense to me. Thanks!

@matthiask matthiask merged commit 763ac8f into django-commons:master Oct 4, 2020
@jdufresne jdufresne deleted the simplify-toggle branch October 4, 2020 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants