-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Feat: styles #81
Feat: styles #81
Conversation
89d86da
to
7110029
Compare
styleImport.then((styles: string) => { | ||
const style = document.createElement('style'); | ||
style.setAttribute('q:style', styleId); | ||
style.textContent = styles.replace(/�/g, styleId); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is /�/g
?
@@ -304,14 +304,18 @@ describe('q-render', () => { | |||
expectRendered( | |||
<hello-world | |||
on:q-render={HelloWorld.onRender} | |||
q:style={HelloWorld.styles as any} | |||
q:sstyle={HelloWorld_styles} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is q:sstyle
correct?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Scoped Style. Not loving it, but for now until we figure out something better.
@@ -40,7 +40,12 @@ export const enum AttributeMarker { | |||
/** | |||
* Component Styles. | |||
*/ | |||
ComponentStyles = 'q:style', | |||
ComponentStyles = 'q:sstyle', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok guess it's correct, but why the change from q:style
to q:sstyle
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So we can have both scoped and unscoped styles.
No description provided.