Chakra UI is a component system for building products with speed ⚡️
Installations
npm install @chakra-ui/styled-system
Developer Guide
Typescript
Yes
Module System
CommonJS, ESM
Node Version
22.4.0
NPM Version
10.8.1
Score
98.8
Supply Chain
99.5
Quality
86.9
Maintenance
100
Vulnerability
99.6
License
Releases
@chakra-ui/react@3.5.1
Published on 24 Jan 2025
@chakra-ui/panda-preset@3.5.1
Published on 24 Jan 2025
@chakra-ui/cli@3.5.1
Published on 24 Jan 2025
@chakra-ui/react@3.5.0
Published on 24 Jan 2025
@chakra-ui/panda-preset@3.5.0
Published on 24 Jan 2025
@chakra-ui/cli@3.5.0
Published on 24 Jan 2025
Contributors
Languages
TypeScript (82.77%)
MDX (16.42%)
JavaScript (0.66%)
CSS (0.08%)
HTML (0.07%)
Developer
Download Statistics
Total Downloads
86,492,931
Last Day
136,009
Last Week
586,434
Last Month
2,622,105
Last Year
33,416,478
GitHub Statistics
38,399 Stars
10,411 Commits
3,343 Forks
202 Watching
12 Branches
674 Contributors
Bundle Size
55.23 kB
Minified
16.87 kB
Minified + Gzipped
Package Meta Information
Latest Version
2.12.0
Package Id
@chakra-ui/styled-system@2.12.0
Unpacked Size
246.74 kB
Size
51.56 kB
File Count
153
NPM Version
10.8.1
Node Version
22.4.0
Publised On
16 Oct 2024
Total Downloads
Cumulative downloads
Total Downloads
86,492,931
Last day
-2.6%
136,009
Compared to previous day
Last week
-16.3%
586,434
Compared to previous week
Last month
0.8%
2,622,105
Compared to previous month
Last year
23.8%
33,416,478
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
Dependencies
2
Dev Dependencies
3
@chakra-ui/styled-system
The framework's agnostic styling engine for Chakra UI. It's used in the system
package.
Installation
1npm i @chakra-ui/styled-system 2 3# or 4 5yarn add @chakra-ui/styled-system
CSS Logical Properties
Chakra UI provides pretty good support for bidirectional (bidi
) CSS
properties. For our shorthand props, we provide a *Bidi
suffix to manage the
rtl/ltr switching.
1import { css } from "@chakra-ui/styled-system" 2 3const theme = { 4 direction: "rtl", // ltr | rtl 5} 6 7const styles = css({ 8 mt: "40px", 9 // bi-directional `margin-right` 10 // `margin-right` in ltr, `margin-left` in rtl 11 mrBidi: "30px", 12})(theme)
References
1const cssLogicalValueMap = { 2 float: { left: "inline-start", right: "inline-end" }, 3 clear: { left: "inline-start", right: "inline-end" }, 4 resize: { horizontal: "block", vertical: "inline" }, 5 textAlign: { left: "start", right: "end" }, 6 captionSize: { top: "block-start", bottom: "block-end" }, 7} 8 9const cssLogicalPropertiesMap = { 10 // Margin and Padding Logical Properties 11 "marginTop|mt": "marginBlockStart", 12 "marginLeft|ml": "marginInlineStart", 13 "marginRight|mr": "marginInlineEnd", 14 "marginBottom|mb": "marginBlockEnd", 15 "paddingTop|pt": "paddingBlockStart", 16 "paddingBottom|pb": "paddingBlockEnd", 17 "paddingLeft|pl": "paddingInlineStart", 18 "paddingRight|pr": "paddingInlineEnd", 19 "marginY|my": "marginBlock", 20 "marginX|mx": "marginInline", 21 "paddingY|py": "paddingBlock", 22 "paddingX|px": "paddingInline", 23 24 // Floating and positioning logical properties 25 top: "insetBlockStart", 26 bottom: "insetBlockEnd", 27 left: "insetInlineStart", 28 right: "insetInlineEnd", 29 30 // Sizing Logical properties 31 "width|w": "inlineSize", 32 "minW|minWidth": "minInlineSize", 33 "maxW|maxWidth": "maxInlineSize", 34 "height|h": "blockSize", 35 "minH|minHeight": "minBlockSize", 36 "maxH|maxHeight": "maxBlockSize", 37 38 // Border logical properties 39 borderY: "borderBlock", 40 borderX: "borderInline", 41 42 borderTop: "borderBlockStart", 43 borderTopWidth: "borderBlockStartWidth", 44 borderTopStyle: "borderBlockStartStyle", 45 borderTopColor: "borderBlockStartColor", 46 47 borderBottom: "borderBlockEnd", 48 borderBottomWidth: "borderBlockEndWidth", 49 borderBottomStyle: "borderBlockEndStyle", 50 borderBottomColor: "borderBlockEndColor", 51 52 borderLeft: "borderInlineStart", 53 borderLeftWidth: "borderInlineStartWidth", 54 borderLeftStyle: "borderInlineStartStyle", 55 borderLeftColor: "borderInlineStartColor", 56 57 borderRight: "borderInlineEnd", 58 borderRightWidth: "borderInlineEndWidth", 59 borderRightStyle: "borderInlineEndStyle", 60 borderRightColor: "borderInlineEndColor", 61}
![Empty State](/_next/static/media/empty.e5fae2e5.png)
No vulnerabilities found.
Reason
30 commit(s) and 13 issue activity found in the last 90 days -- score normalized to 10
Reason
no dangerous workflow patterns detected
Reason
license file detected
Details
- Info: project has a license file: LICENSE:0
- Info: FSF or OSI recognized license: MIT License: LICENSE:0
Reason
no binaries found in the repo
Reason
5 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-pxg6-pf52-xh8x
- Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275
- Warn: Project is vulnerable to: GHSA-mwcw-c2x4-8c55
- Warn: Project is vulnerable to: GHSA-rhx6-c78j-4q9w
- Warn: Project is vulnerable to: GHSA-c76h-2ccp-4975
Reason
Found 7/21 approved changesets -- score normalized to 3
Reason
detected GitHub workflow tokens with excessive permissions
Details
- Warn: topLevel 'actions' permission set to 'write': .github/workflows/issue-stale.yml:10
- Warn: no topLevel permission defined: .github/workflows/pkg-pr.yml:1
- Warn: no topLevel permission defined: .github/workflows/quality.yml:1
- Warn: no topLevel permission defined: .github/workflows/release.yml:1
- Info: no jobLevel write permissions found
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/issue-stale.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/chakra-ui/chakra-ui/issue-stale.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pkg-pr.yml:11: update your workflow using https://app.stepsecurity.io/secureworkflow/chakra-ui/chakra-ui/pkg-pr.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pkg-pr.yml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/chakra-ui/chakra-ui/pkg-pr.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/quality.yml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/chakra-ui/chakra-ui/quality.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/quality.yml:27: update your workflow using https://app.stepsecurity.io/secureworkflow/chakra-ui/chakra-ui/quality.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/quality.yml:40: update your workflow using https://app.stepsecurity.io/secureworkflow/chakra-ui/chakra-ui/quality.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/quality.yml:53: update your workflow using https://app.stepsecurity.io/secureworkflow/chakra-ui/chakra-ui/quality.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/quality.yml:66: update your workflow using https://app.stepsecurity.io/secureworkflow/chakra-ui/chakra-ui/quality.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:20: update your workflow using https://app.stepsecurity.io/secureworkflow/chakra-ui/chakra-ui/release.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:33: update your workflow using https://app.stepsecurity.io/secureworkflow/chakra-ui/chakra-ui/release.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/release.yml:46: update your workflow using https://app.stepsecurity.io/secureworkflow/chakra-ui/chakra-ui/release.yml/main?enable=pin
- Info: 0 out of 10 GitHub-owned GitHubAction dependencies pinned
- Info: 0 out of 1 third-party GitHubAction dependencies pinned
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 16 are checked with a SAST tool
Score
4.6
/10
Last Scanned on 2025-01-27
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn MoreGathering detailed insights and metrics for @chakra-ui/styled-system