UI Styling Standard
The eslint plugin to enforce and educate on Atlassian's UI Styling Standard3.0.3
Patch Changes
64ee18b2949bf, (opens new window) - Give styling rule diagnostics concrete migration and recovery steps, and replace stale Emotion guidance with Compiled examples.- Updated dependencies
3.0.2
Patch Changes
8769f20fe2ebd, (opens new window) - Disable the legacyatlaskit-themerule in generated presets.
3.0.1
Patch Changes
2a6c8a9e812fc, (opens new window) -no-important-stylesnow reports!importantvalues wrapped in TypeScript expressions, e.g.color: 'red !important' as const, and values inside wrapped style objects such ascss({…} as const)or'&:hover': {…} as const. Previously these were skipped.
3.0.0
Major Changes
947cd9330812c, (opens new window) - Remove theno-top-layer-unsafe-selectorsrule from the plugin. It was in theallandall-flatpresets only, not inrecommended. ESLint reports an unknown rule for any config entry oreslint-disablecomment that names@atlaskit/ui-styling-standard/no-top-layer-unsafe-selectors, so delete those references.
2.4.1
Patch Changes
3e2e34bcc2601, (opens new window) -no-imported-style-values: no longer reports imported identifiers used in qualified type positions, such as'value' satisfies typeof Tokens.COLOR_TEXTor'value' satisfies Theme.Color. These are erased at runtime and are not imported style values.a5979af0b9045, (opens new window) -no-nested-selectorsnow lints computed keys wrapped in TypeScript expressions (satisfies,as, type assertions, non-null), e.g.['.foo' satisfies \.${typeof FOO_CLASS}`]`. Previously these keys were silently skipped.
2.4.0
Minor Changes
187f8c82f1f1e, (opens new window) - Raiseno-atlaskit-themefrom a warning to an error in the recommended config. Imports from@atlaskit/themenow fail lint unless they are removed or disabled.
Patch Changes
9ca54438f46bf, (opens new window) -no-unsafe-selectorsnow honours chained pseudos in its allowlist.&:focus:not(:focus-visible)was allowlisted but still reported, because each pseudo was checked on its own and:notis not allowed alone. Other uses of:not, such as&:hover:not(:focus-visible), are still reported.9ca54438f46bf, (opens new window) -no-unsafe-selectorsnow allows the vendor pseudo-elements that have no standard equivalent:::-moz-focus-inner,::-moz-focus-outer,::-moz-range-progress,::-moz-range-thumb,::-moz-range-track,::-webkit-slider-runnable-track, and::-webkit-slider-thumb. Other vendor pseudos, such as::-webkit-scrollbarand::-ms-clear, are still reported.
2.3.0
Minor Changes
-
0418e1c376844, (opens new window) - Add theno-top-layer-unsafe-selectorsrule. It reports selectors that a Design System layering surface rendered in the browser top layer can wrongly match or wrongly displace, and autofixes most of them to a guarded form with the same specificity. Positional pseudo-classes such as:first-childare reported without a fix, because no guard form for them survives the build.The rule is not in the
recommendedpreset, sorecommendedusers see no change. It is in theallandall-flatpresets aterror, so users of those presets get new errors.
Patch Changes
- Updated dependencies
2.2.0
Minor Changes
a5d06059c9ac7, (opens new window) - Add the no-atlaskit-theme lint rule and enable it as a warning in the recommended config. Imports from @atlaskit/theme are flagged without failing lint.
2.1.10
Patch Changes
62aaaa3da8184, (opens new window) - Speed up the atlaskit-theme lint rule by skipping files that do not import the banned theme mixins, and by checking each Compiled call once instead of every nested identifier.
2.1.9
Patch Changes
a4c26c5edfc0b, (opens new window) - Allow local literal style values constrained with TypeScriptsatisfiesexpressions.1715d48a722a2, (opens new window) - Migrate responsive styling to typed canonical CSS media-query keys. Allow those keys in the UI Styling Standard and report non-canonical queries used withsatisfies.
2.1.8
Patch Changes
2808e38fa97f7, (opens new window) - Allow static style keys and values annotated with TypeScriptsatisfiesexpressions98d68443fc958, (opens new window) - Handle TypeScript satisfies and assertion wrappers without rejecting safe inline style values or imported type references. Update the Platform ESLint plugin's Compiled ESLint dependency to ^0.20.2 to fix shorthand-property sorting crashes on inline satisfies expressions.
2.1.7
Patch Changes
f0c3543359684, (opens new window) - Allow safe local named dimension-based container queries
2.1.6
Patch Changes
eac2b82a415cd, (opens new window) - Allow statically written style keys annotated with TypeScriptsatisfiesexpressions.no-unsafe-valuesno longer reports a computed key that unwraps to a string literal, andno-imported-style-valuesno longer reports imported identifiers used in type positions.
2.1.5
Patch Changes
fdedfb06aa229, (opens new window) - Allow canonical typed media queries and typed container-query exceptions in styling lint rules.- Updated dependencies
2.1.4
Patch Changes
4b07551b64b89, (opens new window) - Improve the performance of theno-important-styles,no-nested-selectors, andno-unsafe-selectorsrules.
2.1.3
Patch Changes
153f1b982bd5c, (opens new window) - Improve selector parsing and style-import resolution performance- Updated dependencies
2.1.2
Patch Changes
00f3166426df4, (opens new window) - add eslint rule for cssMapScope and ratcheting rule- Updated dependencies
2.1.1
Patch Changes
- Updated dependencies
2.1.0
Minor Changes
2f56c78f969b8, (opens new window) - Update i18n NPM package versions for teamwork-graph (Group 16)
Patch Changes
- Updated dependencies
2.0.0
Major Changes
-
f2dc9097319f0, (opens new window) - ### Dropped support for legacy Typescript 4 types. Typescript 5 is now the new minimum.Removes the
typesVersionsproperty anddist/types-ts4.5directory from the dist.Types are now exclusively via the
"types": "dist/types/index.d.ts"property.- "typesVersions": { - ">=4.5 <4.9": { - "*": [ - "dist/types-ts4.5/*", - "dist/types-ts4.5/index.d.ts" - ] - } - },
Patch Changes
- Updated dependencies
1.6.4
Patch Changes
7affa87ae5857, (opens new window) - Add ESLint v9/v10 RuleContext compatibility for platform ESLint packages consumed by Jira.- Updated dependencies
1.6.3
Patch Changes
- Updated dependencies
1.6.2
Patch Changes
2c00950ad9e0b, (opens new window) - Align no-unsafe-selectors allowed pseudos with @compiled/react CSSPseudos: add &:popover-open and chained pseudos (e.g. &:hover::after, &:focus::before, &:visited:focus) so the constants tuple type-checks. Rule behavior unchanged; only type-sync with the platform.
1.6.1
Patch Changes
000d0a2d3aca2, (opens new window) - Remove non-erasable syntax (e.g. enums, namespaces with runtime code) from package- Updated dependencies
1.6.0
Minor Changes
5db9e3f21a52f, (opens new window) - Changes the@atlaskit/ui-styling-standard/enforce-style-propESLint rule to allow pass-through styles.
1.5.1
Patch Changes
ceba2f0da51d4, (opens new window) - Add @starting-style to ESLint ignoredAtRules to allow usage without eslint-disable comments
1.5.0
Minor Changes
d2b1c5a27d84a, (opens new window) - Fix two bugs in the no-unused-cssmap-properties rule:- Use getDeclaredVariables() instead of scope-based lookup to properly track references across nested scopes
- Fix isExported false positive by only checking direct export patterns instead of walking full parent tree
1.4.6
Patch Changes
a60a82196851a, (opens new window) - Internal refactors to remove unused variables. No functional or public changes.
1.4.5
Patch Changes
74c2f420ee49b, (opens new window) - Internal changes to how border radius is applied.
1.4.4
Patch Changes
23bcc5bbc9cee, (opens new window) - Internal changes to how border radius is applied.- Updated dependencies
1.4.3
Patch Changes
- #192710, (opens new window)
b3b30f3bc4453, (opens new window) - Internal changes to how border radius and border width values are applied. No visual change.
1.4.2
Patch Changes
- #120084, (opens new window)
ee978d7b2ba83, (opens new window) - Support BinaryExpression and ConditionalExpression logic when inspecting if an Identifier is static.
1.4.1
Patch Changes
- Updated dependencies
1.4.0
Minor Changes
- #115551, (opens new window)
b773fe465608e, (opens new window) - Allows@atlaskit/ui-styling-standard/no-classname-propto work with bounded pass-through, eg.className={props.xcss}
1.3.0
Minor Changes
- #113173, (opens new window)
46aad36c62f2f, (opens new window) - Cuts a new changeset to land ESLint v9 changes to NPM fully (shipped internally Feb 5th: https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/109855, (opens new window))
Patch Changes
- Updated dependencies
1.2.0
Minor Changes
- #112918, (opens new window)
fdd4f60b25c59, (opens new window) - Update rules to be compatible with ESLint v9, while maintaining compatibility with v8 via the@atlaskit/eslint-utilspackage.
Patch Changes
- Updated dependencies
1.1.1
Patch Changes
- Updated dependencies
1.1.0
Minor Changes
- #178147, (opens new window)
06f80813d818b, (opens new window) - Handle the false-positive of enforce-style-prop when assigned viastyle={style}passing around full objects, rather than simply inlinestyle={{ … }}objects.
1.0.4
Patch Changes
- #171997, (opens new window)
a433756c2ec76, (opens new window) - Remove dependency not longer needed
1.0.3
Patch Changes
- #171994, (opens new window)
be58e4bb2e387, (opens new window) - Migrating usages of UNSAFE types and entrypoints that have been renamed in@atlaskit/iconand@atlaskit/icon-lab.
1.0.2
Patch Changes
- Updated dependencies
1.0.1
Patch Changes
- #165531, (opens new window)
57f451bda8919, (opens new window) - Adds side-effect config to support Compiled css extraction in third-party apps
1.0.0
Major Changes
- #162439, (opens new window)
d4e7809eb2373, (opens new window) - Remove Compiled rules from plugin, please use @compiled/eslint-plugin directly
Patch Changes
- #157624, (opens new window)
1734bd61b5d9e, (opens new window) - Fix enforce-style-prop from erroring on type assertion, eg. '{…} as React.CSSProperties' which is a common pattern
0.21.0
Minor Changes
- #157735, (opens new window)
0138fda541246, (opens new window) - Adding flat config presets to @atlaskit/eslint-plugin-ui-styling-standard
0.20.1
Patch Changes
- #154199, (opens new window)
d13bf04a19535, (opens new window) - Bump @compiled/* and enable sorting of styles (where applicable)
0.20.0
Minor Changes
- #154669, (opens new window)
20db78434becd, (opens new window) - Bump to the latest version of @compiled/* - #154669, (opens new window)
20db78434becd, (opens new window) - Add and configure@compiled/jsx-pragmain the recommended preset for a better experience with@atlaskit/cssand the JSX pragma.
0.19.1
Patch Changes
- #152862, (opens new window)
8febdd40a9680, (opens new window) - Added &::-webkit-details-marker CSS psuedo into the allowed set of psuedos in @atlaskit/ui-styling-standard/no-unsafe-selectors rule
0.19.0
Minor Changes
- #128926, (opens new window)
5df26d24db3c7, (opens new window) - Remove configuration for '@atlaskit/design-system/no-exported-css' and '@atlaskit/design-system/no-exported-keyframes' as we expect '@atlaskit/ui-styling-standard/no-exported-styles' to cover these cases now.
0.18.4
Patch Changes
- #122050, (opens new window)
db22dc84c34c3, (opens new window) - Moves away from the use of ts-node to esbuild-register for local consumption
0.18.3
Patch Changes
- #116800, (opens new window)
4a3de9921ec28, (opens new window) - Updated documentation.
0.18.2
Patch Changes
- #120040, (opens new window)
5d9c0285bcb91, (opens new window) - Theno-imported-style-valuesrule will now allow usingcx()inside thexcssprop.
0.18.1
Patch Changes
- #117847, (opens new window)
5795b7b47ceac, (opens new window) - Removes redundant files from NPM deployment
0.18.0
Minor Changes
- #117005, (opens new window)
af9ff1e4ec472, (opens new window) - The recommended config now hasconsistent-css-prop-usagelinting enabled for thexcssprop.
0.17.0
Minor Changes
- #110617, (opens new window)
6c94f6748cd97, (opens new window) - turning warn to error for ui styling standard rules
0.16.6
Patch Changes
- #112386, (opens new window)
762c18186f898, (opens new window) - Internal refactoring to usecontext.getSourceCode()instead ofcontext.sourceCodeto better support older versions of eslint.
0.16.5
Patch Changes
- #111807, (opens new window)
a0bd2ff79dc32, (opens new window) - Fixesno-imported-style-valuesto allow imported identifiers when used in the LHS of conditional expressions in thecssprop. This enables dynamic application of styles using feature flags.
0.16.4
Patch Changes
- #111304, (opens new window)
df63ad1ddca6a, (opens new window) - Updated rule docs for better clarity and consistency
0.16.3
Patch Changes
- #110284, (opens new window)
34021a2db424f, (opens new window) - Internal refactoring to improve backwards compatibility with ESLint versions lower than 8
0.16.2
Patch Changes
- #109764, (opens new window)
5ceaeae2bef25, (opens new window) - Fixesno-imported-style-valuesto ignore imported values that exist in the type level
0.16.1
Patch Changes
- #110975, (opens new window)
47a912f14bb6f, (opens new window) - Fixed a bug inwalkStylePropertiesthat could result instyled(BaseComponent)({})styles to not be linted.
0.16.0
Minor Changes
- #109850, (opens new window)
9a18d4ad09473, (opens new window) - Added migration guide to styling standard documentation.
0.15.2
Patch Changes
- #105238, (opens new window)
8840e6d3180d, (opens new window) - Fixesno-nested-selectorsto handle additional APIs (such ascssMapandkeyframes) as well as catch more cases of nested selectors.
0.15.1
Patch Changes
- #105631, (opens new window)
68f222356b10, (opens new window) - Fixesno-unsafe-selectorto ignorexcsswhen checking for ambiguous pseudo-selectors. This is becausexcssdoes not support a leading&for properties.
0.15.0
Minor Changes
- #100969, (opens new window)
0bdf8e822b2f, (opens new window) - Addedno-unsafe-selectorsrule to enable static analysis and prevent regressions when migrating between styling APIs.
Patch Changes
- Updated dependencies
0.14.2
Patch Changes
- #101063, (opens new window)
d135d014f1ae, (opens new window) - Theatlaskit-themerule no longer reports on thefontFallbackimport from@atlaskit/theme/typography
0.14.1
Patch Changes
- #99639, (opens new window)
e9887b5c7698, (opens new window) - Internal refactoring ofno-important-stylesrule - Updated dependencies
0.14.0
Minor Changes
- #99733, (opens new window)
7051e483ab6d, (opens new window) - Added no-styled eslint rule to prevent usage of styled imports
0.13.0
Minor Changes
- #99544, (opens new window)
391edf6de450, (opens new window) - Addedno-global-stylesrule which prevents:- The
GlobalAPI from@emotion - The
createGlobalStyleandinjectGlobalAPIs fromstyled-components <style>elements in JSX- CSS imports (including SASS and LESS)
- The
0.12.0
Minor Changes
- #96162, (opens new window)
d68864c620d0, (opens new window) - Adduse-compiledrule to enforce usage of@compiled/reactinstead of other CSS-in-JS libraries
0.11.6
Patch Changes
- #97707, (opens new window)
764c0805b3c1, (opens new window) - Moved compiled/atlaskit-theme eslint rule to UI styling standard
0.11.5
Patch Changes
- #96532, (opens new window)
d54c7df2e836, (opens new window) - Editing enforce-style-prop rule to use eslint utils functions
0.11.4
Patch Changes
- #93427, (opens new window)
d6d428f334b0, (opens new window) - Theno-important-stylesrule now checks template literal values in style objects
0.11.3
Patch Changes
- #95279, (opens new window)
813a0e8d6227, (opens new window) - Deprecating @repo/internal/compiled/selectors ESlint rule
0.11.2
Patch Changes
- #94765, (opens new window)
8e5a3bddb686, (opens new window) - Adding no imported style values ESlint rule
0.11.1
Patch Changes
- #92963, (opens new window)
1bb8557fb0b6, (opens new window) - Added no-exported-styles eslint rule to disallow exports of css, cssMap, keyframes, styled and xcss styling
0.11.0
Minor Changes
- #87213, (opens new window)
fbfa5a58cf39, (opens new window) - Addsno-unsafe-valuesrule, which forbids most dynamic styling incss/styled/keyframes/cssMap/xcssfunction calls. This includes object spreading, function calls, and so on.
Patch Changes
- Updated dependencies
0.10.0
Minor Changes
- #91611, (opens new window)
943056d22c36, (opens new window) - Addno-dynamic-stylesrule which blocks function expressions as values in style declarations.
0.9.1
Patch Changes
- #90977, (opens new window)
becda03f375e, (opens new window) - Create eslint rule to enforce style prop usage by disallowing passing static css values
0.9.0
Minor Changes
- #91840, (opens new window)
997a3d2d0ca0, (opens new window) - Addno-array-argumentsrule which prevents passing array arguments to style declaration functions.
Patch Changes
- Updated dependencies
0.8.4
Patch Changes
- #89936, (opens new window)
eb8f66c5d0f3, (opens new window) - Add @atlaskit/eslint-plugin-ui-styling-standard to the internal Atlassian push model.
0.8.3
Patch Changes
- #87496, (opens new window)
d5b439e94043, (opens new window) - Improve coverage ofconvert-props-syntaxrule. Previously cases such ascss()andstyled(BaseComponent)()were not covered by the rule.
0.8.2
Patch Changes
- #88753, (opens new window)
df5cbd4957ea, (opens new window) - Fixed no nested selectors rule to skip @ queries, cssMap and keyFrames calls
0.8.1
Patch Changes
- #88029, (opens new window)
01d74d2899d5, (opens new window) - Disabled ESlint rule convert-props-syntax on .attrs() calls - #87476, (opens new window)
af296d200ad2, (opens new window) - Internal refactoring to usegetCreateLintRulefrom@atlaskit/eslint-utils - Updated dependencies
0.8.0
Minor Changes
- #87972, (opens new window)
1f420b2c4a9f, (opens new window) - The@atlaskit/design-system/no-styled-tagged-template-expressionrule will now lint againststyled-componentsby default in the preset configurations.
Patch Changes
- #86779, (opens new window)
4b4bbf195e39, (opens new window) - Created no nested selectors eslint rule to prevent setting styles for child elements
0.7.2
Patch Changes
- #86638, (opens new window)
f003f07e88e1, (opens new window) - Internal refactoring to use a shared@atlaskit/eslint-utilspackage - Updated dependencies
0.7.1
Patch Changes
- #84413, (opens new window)
2860b53c90d9, (opens new window) - Added eslint rule to block @container queries in css styling
0.7.0
Minor Changes
-
#83454, (opens new window)
be8b7ad6ff8e, (opens new window) - Remove name autofixer fromconsistent-css-prop-usage. Variables for css / xcss / cssMap functions will no longer be required to end with "Styles".[BREAKING] Some rule options have been changed:
fixNamesOnlyandautoFixNameshave been removed, as there is no longer an autofixer that enforces variable names.- If you use
fixNamesOnly: true, we recommend switching to usingautoFix: false. - Users of the
autoFixNamesoption should remove this from their configuration.
- If you use
autoFixoption has been added. This controls whether the remaining autofixers should run or not (e.g. hoistingcssfunction calls, wrapping objects incssfunction calls), and istrueby default.
0.6.3
Patch Changes
- #83463, (opens new window)
fee29cf1335a, (opens new window) - Extend convert-props-syntax to Emotion as well as it has a type issue.
0.6.2
Patch Changes
- #83116, (opens new window)
8d4e99057fe0, (opens new window) - Upgrade Typescript from4.9.5to5.4.2
0.6.1
Patch Changes
- #80129, (opens new window)
dc0ce9161fc1, (opens new window) - Addconvert-prop-syntaxto convert invalidstyled-componentsprops syntax to validstyled-componentsprops syntax. - #79686, (opens new window)
7dc7cf06a8b9, (opens new window) - Bump @compiled/react to v0.17.0
0.6.0
Minor Changes
- #81459, (opens new window)
08abd3b15614, (opens new window) - Addsno-classname-proprule which prevents the use ofclassNamein JSX.
0.5.2
Patch Changes
- #81702, (opens new window)
04e7850f449c, (opens new window) - Adding a missing LICENSE for this package, updating from "UNLICENSED" to make it clear this is available for use.
0.5.1
Patch Changes
- #81166, (opens new window)
a249a1bd29a6, (opens new window) - Upgrade ESLint to version 8
0.5.0
Minor Changes
- #80523, (opens new window)
1fbc903e5b7b, (opens new window) - Addsno-important-stylesrule which prevents the use of!importantflags in style declarations.
0.4.1
Patch Changes
- #76885, (opens new window)
06030bc18dd4, (opens new window) - Disablestyled-componentshandling forno-styled-tagged-template-expressionrule, due to edge case where props are converted to output that fails typechecking.
0.4.0
Minor Changes
- #75600, (opens new window)
8875d9de2e5d, (opens new window) - Migrates the ESLint rule from@atlaskit/design-system/local-cx-xcssto@atlaskit/ui-styling-standard/local-cx-xcssand overhauls the codegen to enable better documentation and rule distribution.
0.3.0
Minor Changes
-
#74981, (opens new window)
842300de03a1, (opens new window) - Add the following rules:consistent-css-prop-usage: Ensures consistency withcssandxcssprop usagesno-empty-styled-expression: Forbids any styled expression to be used when passing empty arguments to styled.div() (or other JSX elements).no-exported-css: Forbid exportingcssfunction calls.no-exported-keyframes: Forbid exportingkeyframesfunction calls.no-invalid-css-map: Checks the validity of a CSS map created through cssMap.
-
#72983, (opens new window)
878065bfc4c0, (opens new window) - Adds the following rules to the recommended preset:@atlaskit/design-system/no-css-tagged-template-expression@atlaskit/design-system/no-keyframes-tagged-template-expression@atlaskit/design-system/no-styled-tagged-template-expression
Patch Changes
- #75152, (opens new window)
c16a175d372b, (opens new window) - Change 'error' to 'warn' to unbreak AFM platform
0.2.1
Patch Changes
- #71319, (opens new window)
d716e2b5e102, (opens new window) - Ensures all dependencies are properly defined
0.2.0
Minor Changes
- #69723, (opens new window)
06cd0f04fefb, (opens new window) - Adds the following rules to the recommended config:local-cx-xcss- Ensures thecx()function is only used within thexcsspropno-supress-xcss- Disallows supressing type violations when using thexcsspropno-js-xcss- Disallows usingxcssprop inside JavaScript files
0.1.0
Minor Changes
- #63960, (opens new window)
8e3774cada83, (opens new window) - Created the design system styling standard package