LearnNewsExamplesServices
Frontmatter
titleDomAccess: add rmc CSSsupports to access CSS.supports()
authorgplanansky
stateClosed
createdAtJan 27, 2025, 12:42 PM
updatedAtJan 27, 2025, 1:32 PM
closedAtJan 27, 2025, 1:32 PM
mergedAt
branchesdevdev
urlhttps://github.com/neomjs/neo/pull/6313
Closed
gplanansky
gplanansky commented on Jan 27, 2025, 12:42 PM

Add Neo.main.DomAccess.CSSsupports() remote method call, to give App worker logic access to the CSS.supports() method.

use case: test if user text field input, of a css color value, is a valid color value. This is a bear to do any other way. Too see how hard check: https://developer.mozilla.org/en-US/docs/Glossary/html_color_codes

What kind of change does this PR introduce? (check at least one)

  • Bugfix:

Does this PR introduce a breaking change? (check one)

  • No
tobiu
tobiu commented on Jan 27, 2025, 1:32 PM

DomAccess is meant for accessing the DOM => window.document

This would better fit the scope of Neo.Main, since it will access window.CSS

Before we add lots of methods for requesting very specific attributes or functions, let us do it in a more generic way.

Resolved via https://github.com/neomjs/neo/issues/6314