Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
@paprika/action-bar
Advanced tools
Readme
ActionBar
yarn add @paprika/action-bar
or with npm:
npm install @paprika/action-bar
Prop | Type | required | default | Description |
---|---|---|---|---|
children | node | true | - |
Prop | Type | required | default | Description |
---|---|---|---|---|
children | node | true | - | |
orderedColumnIds | arrayOf | true | - | |
onChangeOrder | func | true | - | |
onChangeVisibility | func | true | - | |
onHideAll | func | true | - | |
onShowAll | func | true | - | |
renderTriggerButton | func | false | null |
Prop | Type | required | default | Description |
---|---|---|---|---|
appliedNumber | number | false | 0 | |
children | node | false | null | |
columns | arrayOf | true | - | |
isAddSortDisabled | bool | false | false | |
onAddSort | func | true | - | |
onApply | func | true | - | |
onCancel | func | false | () => {} | |
onClose | func | false | () => {} | |
onOpen | func | false | () => {} |
Action Bar component contains 2 individual widgets.
<Sort />
and <ColumnsArrangement />
> npm install --save @paprika/action-bar
or
> yarn add @paprika/action-bar
<Sort appliedNumber={appliedNumber} columns={columns} onAddSort={onAddSort} onApply={onApply}>
<Sort.Field id={fieldId} onDelete={handleDelete} onChange={handleChange} isFirst />
<Sort.Field id={fieldId} onDelete={handleDelete} onChange={handleChange} isFirst={false} />
</Sort>
You can also use the hook useSort
const { appliedNumber, sortedFields, sortedData, onAddSort, onDeleteSort, onChangeSort, onApply } = useSort({
columns,
});
const handleDelete = fieldId => () => {
onDeleteSort(fieldId);
};
const handleChange = fieldId => params => {
onChangeSort({ ...params, id: fieldId });
};
return (
<Sort appliedNumber={appliedNumber} columns={columns} onAddSort={onAddSort} onApply={onApply}>
{sortedFields.map((field, index) => (
<Sort.Field
key={field.id}
{...field}
onDelete={handleDelete(field.id)}
onChange={handleChange(field.id)}
isFirst={index === 0}
/>
))}
</Sort>
// display sortedData
);
<ColumnsArrangement
columns={orderedColumns}
onChangeOrder={handleChangeOrder}
onHideAll={handleHideAll}
onShowAll={handleShowAll}
onChangeVisibility={handleChangeVisibility}
/>
You can also use the hook useColumnsArrangement
const {
orderedColumnIds,
onChangeVisibility,
onShowAll,
onHideAll,
onChangeOrder,
isColumnHidden,
} = useColumnsArrangement({ defaultOrderedColumnIds });
return (
<ColumnsArrangement
orderedColumnIds={orderedColumnIds}
onChangeOrder={onChangeOrder}
onHideAll={onHideAll}
onShowAll={onShowAll}
onChangeVisibility={onChangeVisibility}
>
<ColumnsArrangement.ColumnDefinition
id="columnId"
label="Column label"
isDisabled={false}
isHidden={isColumnHidden("columnId")}
/>
</ColumnsArrangement>
);
FAQs
ActionBar
The npm package @paprika/action-bar receives a total of 473 weekly downloads. As such, @paprika/action-bar popularity was classified as not popular.
We found that @paprika/action-bar demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 4 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
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.