Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
@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 586,352 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.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.