Security News
GitHub Removes Malicious Pull Requests Targeting Open Source Repositories
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
@chakra-ui/anatomy
Advanced tools
@chakra-ui/anatomy is a utility package from Chakra UI that provides a set of predefined anatomy objects for various UI components. These anatomy objects help in creating consistent and accessible component structures by defining the parts and their respective styles.
Button Anatomy
The button anatomy defines the parts of a button component, such as 'container', 'icon', and 'label'. This helps in creating a consistent button structure across the application.
const { buttonAnatomy } = require('@chakra-ui/anatomy');
const parts = buttonAnatomy.keys;
console.log(parts); // ['container', 'icon', 'label']
Input Anatomy
The input anatomy defines the parts of an input component, such as 'addon', 'field', and 'element'. This ensures a consistent structure for input components.
const { inputAnatomy } = require('@chakra-ui/anatomy');
const parts = inputAnatomy.keys;
console.log(parts); // ['addon', 'field', 'element']
Modal Anatomy
The modal anatomy defines the parts of a modal component, such as 'overlay', 'dialogContainer', 'dialog', 'header', 'closeButton', 'body', and 'footer'. This helps in creating a consistent modal structure.
const { modalAnatomy } = require('@chakra-ui/anatomy');
const parts = modalAnatomy.keys;
console.log(parts); // ['overlay', 'dialogContainer', 'dialog', 'header', 'closeButton', 'body', 'footer']
React-Bootstrap is a popular UI library that provides pre-styled components based on Bootstrap. It offers a wide range of components with predefined structures and styles, similar to how @chakra-ui/anatomy provides predefined anatomy objects for consistent component structures.
Material-UI is a comprehensive UI library for React that implements Google's Material Design guidelines. It offers a variety of components with predefined structures and styles, similar to the anatomy objects provided by @chakra-ui/anatomy.
Ant Design (antd) is a UI library for React that provides a set of high-quality components with predefined structures and styles. Like @chakra-ui/anatomy, it helps in creating consistent and accessible UI components.
This package declares the anatomy for the Chakra UI components.
It was inspired the ::part()
selector from the
W3C CSS Shadow Parts Draft with
data-attributes.
This is an internal utility, not intended for public usage.
yarn add @chakra-ui/anatomy
# or
npm i @chakra-ui/anatomy
Yes please! See the contributing guidelines for details.
This project is licensed under the terms of the MIT license.
FAQs
The anatomy of all chakra components
The npm package @chakra-ui/anatomy receives a total of 255,425 weekly downloads. As such, @chakra-ui/anatomy popularity was classified as popular.
We found that @chakra-ui/anatomy demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.