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

Bump styled-system and @types/styled-system #43089

Merged
merged 16 commits into from
Jul 15, 2024

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Jun 17, 2024

Bumps styled-system and @types/styled-system. These dependencies needed to be updated together.
Updates styled-system from 3.2.1 to 5.1.5

Release notes

Sourced from styled-system's releases.

v4

  • Rewritten core for less code duplication
  • No longer merges returned style object, but returns arrays instead, which should work with common CSS-in-JS libraries
  • space function has been rewritten with the core style and compose utilities
  • Adds long-form props for margin and padding (e.g. marginTop). Shorthand aliases still work as before.
  • Reintroduces the alias argument to style utility
  • Removes the styles object export
  • Removes the util object export
  • Removes merge utility
  • Removes the mixed utility since it did not behave as expected
  • The theme "scale" is now passed as the second argument to the transformValue option in style utility
  • Removes the ratio style function
  • The following changes to the borders style function
    • The shorthand border props no longer transform numbers to pixel widths with a solid border-style
    • Adds borderWidth, borderStyle, borderColor, and borderRadius props
    • All border props are also available as individual imports
  • Removes styleType from prop types meta fields
  • Changes to the get utility: now returns the last argument as a fallback
Changelog

Sourced from styled-system's changelog.

v5.1.5 2020-02-17

  • @styled-system/css fix media query order #1137
  • Update dependencies

v5.1.4 2019-12-02

  • @styled-system/css add outlineColor support #825
  • Update dependencies

v5.1.3 2019-09-16

  • Add @styled-system/props utility #824

v5.1.2 2019-09-11

  • Update dependencies
  • Fix sort for media queries in plain object syntax #812

v5.1.1 2019-08-22

  • Fix for passing props through to transform function #723
  • Update dependencies

v5.1.0 2019-08-12

  • New variant API with support for inline variant definitions and theme-based style objects #699

v5.0.23 2019-08-12

  • Add support for overflowX and overflowY #682
  • @styled-system/css: add support for size #684
  • Update dependencies

v5.0.22 2019-08-09

  • @styled-system/css: add support for fill, stroke, and flexBasis #679

v5.0.21 2019-08-07

  • Fix publish

v5.0.20 2019-08-07

  • Add theme support for more border properties #670 & #671

v5.0.19 2019-08-05

  • @styled-system/css allow functional values to return responsive array values #654

... (truncated)

Commits
  • 629fa1a v5.1.5
  • d5ed7c6 Edit changelog
  • 50fcdad Merge pull request #1137 from RyanTheAllmighty/fix-responsive-null-styling
  • d8d2483 Merge pull request #1139 from styled-system/dependabot/npm_and_yarn/react-scr...
  • 841d2c2 Merge pull request #1144 from styled-system/dependabot/npm_and_yarn/rollup-1....
  • 9750f76 Merge pull request #1143 from styled-system/dependabot/npm_and_yarn/gatsby-pl...
  • 62c231b Merge pull request #1141 from styled-system/dependabot/npm_and_yarn/gatsby-2....
  • 1ea4ca7 Merge pull request #1142 from styled-system/dependabot/npm_and_yarn/husky-4.2.3
  • 4ee3c01 Bump rollup from 1.31.0 to 1.31.1
  • 2b722a6 Bump gatsby-plugin-mdx from 1.0.70 to 1.0.73
  • Additional commits viewable in compare view

Updates @types/styled-system from 3.2.2 to 5.1.22

Commits

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

@dependabot dependabot bot added dependencies Pull requests that update a dependency file no-changelog Indicates that a PR does not require a changelog entry ui labels Jun 17, 2024
@dependabot dependabot bot requested review from avatus, bl-nero, kimlisa and rudream June 17, 2024 10:58
@dependabot dependabot bot force-pushed the dependabot/npm_and_yarn/multi-6a96fda183 branch from 6667ee4 to 3bc9f53 Compare June 17, 2024 18:47
@avatus avatus removed the request for review from kimlisa June 17, 2024 20:00
@dependabot dependabot bot force-pushed the dependabot/npm_and_yarn/multi-6a96fda183 branch 6 times, most recently from e7a9759 to 5f62419 Compare June 21, 2024 17:17
@dependabot dependabot bot force-pushed the dependabot/npm_and_yarn/multi-6a96fda183 branch 3 times, most recently from 7ed3f51 to cdf8fe0 Compare July 3, 2024 15:35
@dependabot dependabot bot force-pushed the dependabot/npm_and_yarn/multi-6a96fda183 branch 2 times, most recently from 5ea8530 to d514c40 Compare July 8, 2024 15:42
dependabot bot and others added 6 commits July 9, 2024 12:49
Bumps [styled-components](https://github.com/styled-components/styled-components) from 5.3.11 to 6.1.11.
- [Release notes](https://github.com/styled-components/styled-components/releases)
- [Commits](styled-components/styled-components@v5.3.11...v6.1.11)

---
updated-dependencies:
- dependency-name: styled-components
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Bumps [styled-system](https://github.com/jxnblk/styled-system) and [@types/styled-system](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/styled-system). These dependencies needed to be updated together.

Updates `styled-system` from 3.2.1 to 5.1.5
- [Release notes](https://github.com/jxnblk/styled-system/releases)
- [Changelog](https://github.com/styled-system/styled-system/blob/master/CHANGELOG.md)
- [Commits](styled-system/styled-system@v3.2.1...v5.1.5)

Updates `@types/styled-system` from 3.2.2 to 5.1.22
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/styled-system)

---
updated-dependencies:
- dependency-name: styled-system
  dependency-type: direct:production
  update-type: version-update:semver-major
- dependency-name: "@types/styled-system"
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot force-pushed the dependabot/npm_and_yarn/multi-6a96fda183 branch from d514c40 to 9dab3ff Compare July 9, 2024 17:16
@bl-nero bl-nero force-pushed the dependabot/npm_and_yarn/multi-6a96fda183 branch from 9dab3ff to f3a7af5 Compare July 10, 2024 17:37
@bl-nero bl-nero changed the base branch from master to dependabot/npm_and_yarn/styled-components-6.1.11 July 10, 2024 17:39
@bl-nero
Copy link
Contributor

bl-nero commented Jul 10, 2024

All problems fixed, this PR is now ready for review. It's recommended to review it commit by commit.

Summary of changes:

  • The new styled-system changes the underlying algorithm a bit. The defaultProps are applied on top of missing props from the call site. The side effect is that in case if defaultProps define a shorthand property and the component call site defines a value for corresponding non-shorthand property, defaultProps wins, as it's applied later. To fix this, I moved style-related props from defaultProps right to the CSS definitions, and reapplied style functions where necessary.
  • Added ImageProps, it was required to support the alt attribute.
  • Replaced our borderRadius style function with the built-in one.

@bl-nero
Copy link
Contributor

bl-nero commented Jul 10, 2024

Accompanying Enterprise change: https://github.com/gravitational/teleport.e/pull/4617

Copy link
Contributor

@kimlisa kimlisa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

poked around a little in the web UI lgtm

MaxHeightProps,
AlignSelfProps {
alt?: string;
style?: React.CSSProperties;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is style required to do something like this?

<Image style={{css}} />

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. We might avoid listing these properties separately, and instead use the construct that basically says "all allowed attributes of Image element", but I encountered some problems there, and decided it's not worth generalizing if right now, we only use these two.

Base automatically changed from dependabot/npm_and_yarn/styled-components-6.1.11 to master July 12, 2024 10:50
@bl-nero bl-nero enabled auto-merge July 15, 2024 12:34
@bl-nero bl-nero force-pushed the dependabot/npm_and_yarn/multi-6a96fda183 branch from e03e9a5 to 9c33c7d Compare July 15, 2024 12:41
@bl-nero bl-nero added this pull request to the merge queue Jul 15, 2024
Merged via the queue into master with commit a9febc9 Jul 15, 2024
38 checks passed
@bl-nero bl-nero deleted the dependabot/npm_and_yarn/multi-6a96fda183 branch July 15, 2024 12:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file no-changelog Indicates that a PR does not require a changelog entry ui
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants