Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please make the striped background on readonly an opt-out feature #974

Closed
ROODAY opened this issue Jan 28, 2022 · 2 comments
Closed

Please make the striped background on readonly an opt-out feature #974

ROODAY opened this issue Jan 28, 2022 · 2 comments

Comments

@ROODAY
Copy link

ROODAY commented Jan 28, 2022

For the app my team is working on, we don't want the tags to be striped when set to readonly, as we just want them to render the same way they would when editable. After looking at the source SCSS file and fiddling in a codepen I was able to get rid of the styling with the following CSS override:

.tagify[readonly] > div::before {
  background: var(--tag-bg);
}

.tagify[readonly]:not(.tagify--mix):not(.tagify--select) .tagify__tag > div::before {
  background: var(--tag-bg);
}

But it would be nice to be able to set readonly styles through a prop or another CSS variable than having to work around the striping.

@yairEO
Copy link
Owner

yairEO commented Feb 6, 2022

This can now be configured using the CSS variable:

Example:

.tagify{ 
  --readonly-striped: 0; /* or 1 to enable */
}

@ROODAY
Copy link
Author

ROODAY commented Feb 7, 2022

Awesome, thanks so much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants