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

feat(preset-mini)!: update content-x and change handler type #1741

Merged
merged 1 commit into from Oct 25, 2022

Conversation

chu121su12
Copy link
Collaborator

@chu121su12 chu121su12 commented Oct 13, 2022

This PR changes the behavior introduced in #1717

It turns out [raw:x] syntax that uses space will be difficult (never?) to get matched anywhere. So the behaviour is updated in this PR, such that:

  • [raw:x] is removed but may be re-introduced if needed.
  • [string:x] will produce an almost equal value to the original x, only replacing unescaped _ to space.
  • [quoted:x] is special case that (as of current css spec) would only be useful for content property. This is [string:x] as above with additional quoting with ". This would replace following rule:
    [/^content-\[(.+)\]$/, ([, v]) => ({ content: `"${v}"` })],
  • The regular bracket syntax for content-[x] is still avaiable but now behaves like regular bracket

@netlify
Copy link

netlify bot commented Oct 13, 2022

Deploy Preview for unocss ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 7af3e8e
🔍 Latest deploy log https://app.netlify.com/sites/unocss/deploys/63483ae92543a50009b67c7d
😎 Deploy Preview https://deploy-preview-1741--unocss.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

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

Successfully merging this pull request may close these issues.

None yet

2 participants