@nice2dev/icons 1.2.2 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +499 -0
- package/README.md +146 -134
- package/dist/cjs/NiceIconPicker.js +17 -19
- package/dist/cjs/createIcon.js +10 -2
- package/dist/cjs/iconParts.js +49 -0
- package/dist/cjs/icons/accessibility.js +12 -4
- package/dist/cjs/icons/actions.js +67 -25
- package/dist/cjs/icons/business.js +58 -28
- package/dist/cjs/icons/ecommerce.js +0 -20
- package/dist/cjs/icons/education.js +22 -9
- package/dist/cjs/icons/files.js +70 -56
- package/dist/cjs/icons/fun.js +39 -25
- package/dist/cjs/icons/gaming.js +29 -4
- package/dist/cjs/icons/health.js +11 -4
- package/dist/cjs/icons/index.js +55 -5
- package/dist/cjs/icons/input.js +120 -0
- package/dist/cjs/icons/legal.js +4 -9
- package/dist/cjs/icons/media.js +26 -11
- package/dist/cjs/icons/navigation.js +4 -2
- package/dist/cjs/icons/omniverk.js +19 -6
- package/dist/cjs/icons/realestate.js +10 -4
- package/dist/cjs/icons/saas.js +15 -4
- package/dist/cjs/icons/science.js +6 -3
- package/dist/cjs/icons/shapes.js +66 -31
- package/dist/cjs/icons/sports.js +6 -2
- package/dist/cjs/icons/ui.js +62 -20
- package/dist/cjs/icons/weather.js +18 -8
- package/dist/cjs/index.js +55 -5
- package/dist/cjs/nicetodev-icons.css +1 -1
- package/dist/cjs/resolver.js +46 -1
- package/dist/cjs/rsc.js +1 -1
- package/dist/esm/NiceIconPicker.js +19 -21
- package/dist/esm/createIcon.js +10 -2
- package/dist/esm/iconParts.js +46 -0
- package/dist/esm/icons/accessibility.js +12 -4
- package/dist/esm/icons/actions.js +67 -26
- package/dist/esm/icons/business.js +58 -29
- package/dist/esm/icons/ecommerce.js +1 -19
- package/dist/esm/icons/education.js +22 -10
- package/dist/esm/icons/files.js +70 -56
- package/dist/esm/icons/fun.js +37 -25
- package/dist/esm/icons/gaming.js +29 -5
- package/dist/esm/icons/health.js +11 -4
- package/dist/esm/icons/index.js +9 -8
- package/dist/esm/icons/input.js +75 -0
- package/dist/esm/icons/legal.js +4 -9
- package/dist/esm/icons/media.js +26 -11
- package/dist/esm/icons/navigation.js +4 -2
- package/dist/esm/icons/omniverk.js +19 -6
- package/dist/esm/icons/realestate.js +10 -4
- package/dist/esm/icons/saas.js +15 -4
- package/dist/esm/icons/science.js +6 -3
- package/dist/esm/icons/shapes.js +66 -31
- package/dist/esm/icons/sports.js +6 -2
- package/dist/esm/icons/ui.js +62 -21
- package/dist/esm/icons/weather.js +18 -8
- package/dist/esm/index.js +9 -8
- package/dist/esm/nicetodev-icons.css +1 -1
- package/dist/esm/resolver.js +46 -1
- package/dist/esm/rsc.js +1 -1
- package/dist/types/iconParts.d.ts +19 -0
- package/dist/types/icons/actions.d.ts +1 -0
- package/dist/types/icons/business.d.ts +2 -0
- package/dist/types/icons/ecommerce.d.ts +0 -2
- package/dist/types/icons/education.d.ts +1 -0
- package/dist/types/icons/files.d.ts +2 -1
- package/dist/types/icons/fun.d.ts +6 -1
- package/dist/types/icons/gaming.d.ts +2 -0
- package/dist/types/icons/index.d.ts +9 -8
- package/dist/types/icons/input.d.ts +53 -0
- package/dist/types/icons/omniverk.d.ts +0 -2
- package/dist/types/icons/ui.d.ts +1 -0
- package/dist/types/types.d.ts +6 -0
- package/package.json +3 -3
package/dist/cjs/resolver.js
CHANGED
|
@@ -141,11 +141,56 @@ const NAME_MAP = {
|
|
|
141
141
|
'angle-bisector': 'NtdAngleBisector',
|
|
142
142
|
group: 'NtdGroup',
|
|
143
143
|
ungroup: 'NtdUngroup',
|
|
144
|
+
// 1.3.0: input prompt glyphs (built-ins of the same names in ui-core)
|
|
145
|
+
'pad-xbox-a': 'NtdPadXboxA',
|
|
146
|
+
'pad-xbox-b': 'NtdPadXboxB',
|
|
147
|
+
'pad-xbox-x': 'NtdPadXboxX',
|
|
148
|
+
'pad-xbox-y': 'NtdPadXboxY',
|
|
149
|
+
'pad-nintendo-a': 'NtdPadNintendoA',
|
|
150
|
+
'pad-nintendo-b': 'NtdPadNintendoB',
|
|
151
|
+
'pad-nintendo-x': 'NtdPadNintendoX',
|
|
152
|
+
'pad-nintendo-y': 'NtdPadNintendoY',
|
|
153
|
+
'pad-playstation-cross': 'NtdPadPlaystationCross',
|
|
154
|
+
'pad-playstation-circle': 'NtdPadPlaystationCircle',
|
|
155
|
+
'pad-playstation-square': 'NtdPadPlaystationSquare',
|
|
156
|
+
'pad-playstation-triangle': 'NtdPadPlaystationTriangle',
|
|
157
|
+
'pad-generic-north': 'NtdPadGenericNorth',
|
|
158
|
+
'pad-generic-east': 'NtdPadGenericEast',
|
|
159
|
+
'pad-generic-west': 'NtdPadGenericWest',
|
|
160
|
+
'pad-generic-south': 'NtdPadGenericSouth',
|
|
161
|
+
'pad-lb': 'NtdPadLb',
|
|
162
|
+
'pad-rb': 'NtdPadRb',
|
|
163
|
+
'pad-lt': 'NtdPadLt',
|
|
164
|
+
'pad-rt': 'NtdPadRt',
|
|
165
|
+
'pad-start': 'NtdPadStart',
|
|
166
|
+
'pad-select': 'NtdPadSelect',
|
|
167
|
+
'pad-home': 'NtdPadHome',
|
|
168
|
+
'pad-dpad': 'NtdPadDpad',
|
|
169
|
+
'pad-dpad-up': 'NtdPadDpadUp',
|
|
170
|
+
'pad-dpad-down': 'NtdPadDpadDown',
|
|
171
|
+
'pad-dpad-left': 'NtdPadDpadLeft',
|
|
172
|
+
'pad-dpad-right': 'NtdPadDpadRight',
|
|
173
|
+
'pad-stick-left': 'NtdPadStickLeft',
|
|
174
|
+
'pad-stick-right': 'NtdPadStickRight',
|
|
175
|
+
'pad-stick-left-press': 'NtdPadStickLeftPress',
|
|
176
|
+
'pad-stick-right-press': 'NtdPadStickRightPress',
|
|
177
|
+
'remote-ok': 'NtdRemoteOk',
|
|
178
|
+
'remote-back': 'NtdRemoteBack',
|
|
179
|
+
'remote-menu': 'NtdRemoteMenu',
|
|
180
|
+
'key-command': 'NtdKeyCommand',
|
|
181
|
+
'key-option': 'NtdKeyOption',
|
|
182
|
+
'key-shift': 'NtdKeyShift',
|
|
183
|
+
'key-control': 'NtdKeyControl',
|
|
184
|
+
'key-enter': 'NtdKeyEnter',
|
|
185
|
+
'key-tab': 'NtdKeyTab',
|
|
186
|
+
'key-backspace': 'NtdKeyBackspace',
|
|
187
|
+
'key-space': 'NtdKeySpace',
|
|
188
|
+
'key-caps': 'NtdKeyCaps',
|
|
144
189
|
list: 'NtdList',
|
|
145
190
|
table: 'NtdTable',
|
|
146
191
|
monitor: 'NtdMonitor',
|
|
147
192
|
cpu: 'NtdCpu',
|
|
148
|
-
zap: '
|
|
193
|
+
zap: 'NtdLightning',
|
|
149
194
|
key: 'NtdKey',
|
|
150
195
|
award: 'NtdAward',
|
|
151
196
|
coffee: 'NtdCoffee',
|
package/dist/cjs/rsc.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
2
|
-
import { useNiceTranslation } from '@nice2dev/ui-core';
|
|
3
|
-
import { forwardRef,
|
|
2
|
+
import { useRovingFocus, useNiceTranslation, useOverlayFocus } from '@nice2dev/ui-core';
|
|
3
|
+
import { forwardRef, useRef, useState, useMemo, useCallback, useImperativeHandle, useEffect } from 'react';
|
|
4
4
|
import { NtdSearch, NtdCheck } from './icons/actions.js';
|
|
5
5
|
import { NtdGrid } from './icons/files.js';
|
|
6
6
|
import { NtdInbox } from './icons/media.js';
|
|
@@ -72,6 +72,8 @@ function saveToStorage(key, value) {
|
|
|
72
72
|
*/
|
|
73
73
|
const NiceIconPicker = /* @__PURE__ */ forwardRef(function NiceIconPicker({ icons, value = null, values = [], onChange, onChangeMulti, multiSelect = false, maxSelections, placeholder, variant = 'solid', gridIconSize = 'md', triggerIconSize = 'sm', categories: categoriesProp, className, disabled = false, clearable = true, virtualized = false, virtualizedItemCount = 100, showHistory = false, showFavorites = false, storageKeyPrefix = 'ntd-icon-picker', enableDragAndDrop = false, onDragStart, onDragEnd, }, ref) {
|
|
74
74
|
var _a;
|
|
75
|
+
const tablistRef = useRef(null);
|
|
76
|
+
useRovingFocus(tablistRef, { orientation: 'horizontal', wrap: true, activateOnMove: true });
|
|
75
77
|
const { t } = useNiceTranslation();
|
|
76
78
|
const [isOpen, setIsOpen] = useState(false);
|
|
77
79
|
const [search, setSearch] = useState('');
|
|
@@ -223,30 +225,26 @@ const NiceIconPicker = /* @__PURE__ */ forwardRef(function NiceIconPicker({ icon
|
|
|
223
225
|
document.addEventListener('mousedown', onClickOutside);
|
|
224
226
|
return () => document.removeEventListener('mousedown', onClickOutside);
|
|
225
227
|
}, [isOpen]);
|
|
226
|
-
/* ───
|
|
228
|
+
/* ─── Reset on close ─── */
|
|
227
229
|
useEffect(() => {
|
|
228
|
-
if (isOpen) {
|
|
229
|
-
requestAnimationFrame(() => { var _a; return (_a = searchInputRef.current) === null || _a === void 0 ? void 0 : _a.focus(); });
|
|
230
|
-
}
|
|
231
|
-
else {
|
|
230
|
+
if (!isOpen) {
|
|
232
231
|
setSearch('');
|
|
233
232
|
setActiveCategory(null);
|
|
234
233
|
setVisibleRange({ start: 0, end: virtualizedItemCount });
|
|
235
234
|
}
|
|
236
235
|
}, [isOpen, virtualizedItemCount]);
|
|
237
|
-
/* ─── Keyboard ─── */
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
}, [isOpen]);
|
|
236
|
+
/* ─── Keyboard and pad (1.3.0) ─── */
|
|
237
|
+
// The panel is a dialog on the overlay stack: focus on the search field when it opens, Escape
|
|
238
|
+
// / B close only it (a document listener before) and focus returns to the trigger. The icon
|
|
239
|
+
// grid is an APG listbox moving in two dimensions — the cells were reachable by Tab only.
|
|
240
|
+
const dropdownRef = useRef(null);
|
|
241
|
+
useOverlayFocus(dropdownRef, {
|
|
242
|
+
open: isOpen,
|
|
243
|
+
modal: false,
|
|
244
|
+
initialFocus: searchInputRef,
|
|
245
|
+
onClose: () => setIsOpen(false),
|
|
246
|
+
});
|
|
247
|
+
useRovingFocus(gridWrapRef, { orientation: 'grid', itemSelector: '.ntd-picker-cell' });
|
|
250
248
|
/* ─── Virtualization scroll handler ─── */
|
|
251
249
|
useEffect(() => {
|
|
252
250
|
if (!virtualized || !isOpen || !gridWrapRef.current) {
|
|
@@ -394,7 +392,7 @@ const NiceIconPicker = /* @__PURE__ */ forwardRef(function NiceIconPicker({ icon
|
|
|
394
392
|
? readableName(selectedEntry.name)
|
|
395
393
|
: (placeholder !== null && placeholder !== void 0 ? placeholder : t('iconPicker.selectIcon', 'Select icon…'));
|
|
396
394
|
}, [multiSelect, selectedEntries, selectedEntry, placeholder, t]);
|
|
397
|
-
return (jsxs("div", { ref: rootRef, className: `ntd-picker${isOpen ? ' ntd-picker--open' : ''}${disabled ? ' ntd-picker--disabled' : ''}${multiSelect ? ' ntd-picker--multi' : ''}${className ? ` ${className}` : ''}`, children: [jsxs("button", { type: "button", className: "ntd-picker-trigger", onClick: handleToggle, disabled: disabled, "aria-haspopup": "listbox", "aria-expanded": isOpen, children: [jsx("span", { className: "ntd-picker-trigger-icon", children: selectedEntry ? (jsx(selectedEntry.Component, { size: triggerIconSize, variant: variant })) : multiSelect && selectedEntries.length > 1 ? (jsx("span", { className: "ntd-picker-multi-badge", children: selectedEntries.length })) : (jsx(NtdGrid, { size: 16, variant: "outline" })) }), jsx("span", { className: `ntd-picker-trigger-label${!selectedEntry && selectedEntries.length === 0 ? ' ntd-picker-trigger-placeholder' : ''}`, children: triggerLabel }), jsx("span", { className: "ntd-picker-trigger-chevron", children: jsx(Chevron, {}) })] }), isOpen && (jsxs("div", { className: "ntd-picker-dropdown", role: "
|
|
395
|
+
return (jsxs("div", { ref: rootRef, className: `ntd-picker${isOpen ? ' ntd-picker--open' : ''}${disabled ? ' ntd-picker--disabled' : ''}${multiSelect ? ' ntd-picker--multi' : ''}${className ? ` ${className}` : ''}`, children: [jsxs("button", { type: "button", className: "ntd-picker-trigger", onClick: handleToggle, disabled: disabled, "aria-haspopup": "listbox", "aria-expanded": isOpen, children: [jsx("span", { className: "ntd-picker-trigger-icon", children: selectedEntry ? (jsx(selectedEntry.Component, { size: triggerIconSize, variant: variant })) : multiSelect && selectedEntries.length > 1 ? (jsx("span", { className: "ntd-picker-multi-badge", children: selectedEntries.length })) : (jsx(NtdGrid, { size: 16, variant: "outline" })) }), jsx("span", { className: `ntd-picker-trigger-label${!selectedEntry && selectedEntries.length === 0 ? ' ntd-picker-trigger-placeholder' : ''}`, children: triggerLabel }), jsx("span", { className: "ntd-picker-trigger-chevron", children: jsx(Chevron, {}) })] }), isOpen && (jsxs("div", { ref: dropdownRef, className: "ntd-picker-dropdown", role: "dialog", "aria-label": t('iconPicker.selectIcon', 'Select icon…'), children: [jsxs("div", { className: "ntd-picker-search", children: [jsx("span", { className: "ntd-picker-search-icon", children: jsx(SearchIcon, {}) }), jsx("input", { ref: searchInputRef, type: "text", placeholder: t('iconPicker.searchIcons', 'Search icons…'), value: search, onChange: (e) => setSearch(e.target.value), "aria-label": t('iconPicker.searchIcons2', 'Search icons') })] }), (allCategories.length > 1 || showFavorites || showHistory) && (jsxs("div", { className: "ntd-picker-tabs", ref: tablistRef, role: "tablist", children: [jsx("button", { type: "button", className: `ntd-picker-tab${activeCategory === null ? ' ntd-picker-tab--active' : ''}`, onClick: () => setActiveCategory(null), role: "tab", "aria-selected": activeCategory === null, children: t('iconPicker.all', 'All') }), showFavorites && (jsxs("button", { type: "button", className: `ntd-picker-tab ntd-picker-tab-special${activeCategory === '__favorites__' ? ' ntd-picker-tab--active' : ''}`, onClick: () => setActiveCategory('__favorites__'), role: "tab", "aria-selected": activeCategory === '__favorites__', title: t('iconPicker.favorites', 'Favorites'), children: [jsx(StarIcon, { filled: true }), " ", t('iconPicker.favorites', 'Favorites'), favorites.length > 0 && (jsx("span", { className: "ntd-picker-tab-count", children: favorites.length }))] })), showHistory && history.length > 0 && (jsxs("button", { type: "button", className: `ntd-picker-tab ntd-picker-tab-special${activeCategory === '__history__' ? ' ntd-picker-tab--active' : ''}`, onClick: () => setActiveCategory('__history__'), role: "tab", "aria-selected": activeCategory === '__history__', title: t('iconPicker.recentlyUsed', 'Recently used'), children: [jsx(ClockIcon, {}), " ", t('iconPicker.recent', 'Recent')] })), allCategories.map((cat) => (jsx("button", { type: "button", className: `ntd-picker-tab${activeCategory === cat ? ' ntd-picker-tab--active' : ''}`, onClick: () => setActiveCategory(cat), role: "tab", "aria-selected": activeCategory === cat, children: cat }, cat)))] })), jsx("div", { className: "ntd-picker-grid-wrap", ref: gridWrapRef, role: "listbox", "aria-label": t('iconPicker.icons', 'Icons'), "aria-multiselectable": multiSelect || undefined, children: filtered.length === 0 ? (jsxs("div", { className: "ntd-picker-empty", children: [jsx("div", { className: "ntd-picker-empty-icon", children: jsx(NtdInbox, { size: 28, variant: "outline" }) }), activeCategory === '__favorites__'
|
|
398
396
|
? t('iconPicker.noFavoritesYetClickThe', 'No favorites yet. Click the star icon to add.')
|
|
399
397
|
: activeCategory === '__history__'
|
|
400
398
|
? t('iconPicker.noRecentIcons', 'No recent icons.')
|
package/dist/esm/createIcon.js
CHANGED
|
@@ -83,7 +83,11 @@ function renderGradientDef(id, preset, type, angle, animation) {
|
|
|
83
83
|
}
|
|
84
84
|
/* ── 3D filter helper ───────────────────────────────── */
|
|
85
85
|
function render3dFilterDef(filterId) {
|
|
86
|
-
return (
|
|
86
|
+
return (
|
|
87
|
+
// The region is the icon's box plus a margin for the shadow, not a share of the shape's
|
|
88
|
+
// bounding box: a lone horizontal or vertical line (NtdMinus) has a zero-height box, and a
|
|
89
|
+
// filter region of 140% of zero rendered nothing.
|
|
90
|
+
jsxs("filter", { id: filterId, filterUnits: "userSpaceOnUse", x: "-4", y: "-4", width: "32", height: "32", children: [jsx("feDropShadow", { dx: "0", dy: "1.5", stdDeviation: "1", floodOpacity: "0.35" }), jsxs("feComponentTransfer", { in: "SourceGraphic", result: "highlight", children: [jsx("feFuncR", { type: "linear", slope: "1.2", intercept: "0.1" }), jsx("feFuncG", { type: "linear", slope: "1.2", intercept: "0.1" }), jsx("feFuncB", { type: "linear", slope: "1.2", intercept: "0.1" })] }), jsx("feComposite", { operator: "in", in: "highlight", in2: "SourceGraphic", result: "highlightMask" }), jsx("feMerge", { children: jsx("feMergeNode", { in: "SourceGraphic" }) })] }));
|
|
87
91
|
}
|
|
88
92
|
/* ── Cutout shape helper ──────────────────────────── */
|
|
89
93
|
function renderCutoutShape(shape, fill, maskId) {
|
|
@@ -114,6 +118,8 @@ function createIcon(options) {
|
|
|
114
118
|
var _a, _b, _c, _d, _e, _f, _g;
|
|
115
119
|
const resolvedSize = typeof size === 'number' ? size : ((_a = SIZE_MAP[size]) !== null && _a !== void 0 ? _a : 24);
|
|
116
120
|
const gradId = useId();
|
|
121
|
+
// the prefix of the ids of the clip paths the renderers draw (IconRenderProps.uid)
|
|
122
|
+
const uid = useId();
|
|
117
123
|
const center = { x: 12, y: 12 }; // Default center for 24x24 viewBox
|
|
118
124
|
// Use dark/light mode detection when both colors are specified
|
|
119
125
|
const colorScheme = useColorScheme();
|
|
@@ -142,6 +148,7 @@ function createIcon(options) {
|
|
|
142
148
|
strokeWidth: effectiveStrokeWidth,
|
|
143
149
|
strokeLinecap,
|
|
144
150
|
strokeLinejoin,
|
|
151
|
+
uid,
|
|
145
152
|
};
|
|
146
153
|
// Resolve renderer with fallback chain. `wireframe` has no authored layer
|
|
147
154
|
// at all — it is a mechanical re-draw of the full `solid` construction, so
|
|
@@ -219,10 +226,11 @@ function createIcon(options) {
|
|
|
219
226
|
variant: 'solid',
|
|
220
227
|
primaryColor: 'black',
|
|
221
228
|
secondaryColor: 'black',
|
|
222
|
-
accentColor: '
|
|
229
|
+
accentColor: 'white',
|
|
223
230
|
primaryOpacity: 1,
|
|
224
231
|
secondaryOpacity: 1,
|
|
225
232
|
accentOpacity: 1,
|
|
233
|
+
uid: `${uid}m`,
|
|
226
234
|
}) })] }) })), smilAnimation ? (needsSmilScaleWrapper ? (jsxs("g", { transform: `translate(${center.x}, ${center.y})`, filter: is3d ? `url(#${filterId})` : undefined, children: [jsx("g", { transform: `translate(-${center.x}, -${center.y})`, children: iconContent }), smilAnimationElements] })) : (jsxs("g", { filter: is3d ? `url(#${filterId})` : undefined, children: [iconContent, smilAnimationElements] }))) : is3d ? (jsx("g", { filter: `url(#${filterId})`, children: iconContent })) : (iconContent)] }));
|
|
227
235
|
});
|
|
228
236
|
Icon.displayName = displayName;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { createIcon } from './createIcon.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* `content` drawn only inside `shape` — for accent lines that read as a cut through a shape (a
|
|
6
|
+
* pencil's band, a calendar's header line, an envelope's flap): clipped, they meet the shape's
|
|
7
|
+
* edges flush in every variant, where their round caps used to stick out of it (and `sharp` /
|
|
8
|
+
* `rounded` re-cap every stroke, so caps alone cannot do it).
|
|
9
|
+
*
|
|
10
|
+
* `uid` is the icon's `IconRenderProps.uid`; `name` tells the clips of one icon apart. Without a
|
|
11
|
+
* `uid` — a renderer called outside createIcon — the content is drawn as it is.
|
|
12
|
+
*/
|
|
13
|
+
function within(uid, name, shape, content) {
|
|
14
|
+
if (!uid) {
|
|
15
|
+
return content;
|
|
16
|
+
}
|
|
17
|
+
const id = `${uid}${name}`;
|
|
18
|
+
return (jsxs(Fragment, { children: [jsx("clipPath", { id: id, children: shape }), jsx("g", { clipPath: `url(#${id})`, children: content })] }));
|
|
19
|
+
}
|
|
20
|
+
/** The page of every paper icon: 16 × 20, its top-right corner folded over 8. */
|
|
21
|
+
const PAPER = 'M12 2H6a2 2 0 00-2 2v16a2 2 0 002 2h12a2 2 0 002-2V10z';
|
|
22
|
+
const PAPER_FOLD = 'M12 2v6a2 2 0 002 2h6z';
|
|
23
|
+
const PAPER_FOLD_LINE = 'M12 2v8h8';
|
|
24
|
+
const PAPER_SHARP = 'M12 2H4v20h16V10z';
|
|
25
|
+
const PAPER_FOLD_SHARP = 'M12 2v8h8z';
|
|
26
|
+
/**
|
|
27
|
+
* A paper icon — NtdFile, and every document drawn on the same page (NtdFileText, NtdInvoice,
|
|
28
|
+
* NtdContract, …), so their pages and folds match. The fold is secondary when the page is filled;
|
|
29
|
+
* `text` is the document's writing, a path of strokes kept below the fold (y ≥ 11, x 7.5–16.5),
|
|
30
|
+
* drawn in the accent colour on a filled page and in primary on a stroked one.
|
|
31
|
+
*/
|
|
32
|
+
function paperIcon(displayName, text = '') {
|
|
33
|
+
return createIcon({
|
|
34
|
+
displayName,
|
|
35
|
+
paths: {
|
|
36
|
+
solid: ({ primaryColor, secondaryColor, accentColor, accentOpacity }) => (jsxs(Fragment, { children: [jsx("path", { d: PAPER, fill: primaryColor }), jsx("path", { d: PAPER_FOLD, fill: secondaryColor }), text && (jsx("path", { d: text, stroke: accentColor, strokeOpacity: accentOpacity, strokeWidth: "1.5", strokeLinecap: "round", fill: "none" }))] })),
|
|
37
|
+
// square at every corner, the fold included — the derived `sharp` keeps a path's arcs round
|
|
38
|
+
sharp: ({ primaryColor, secondaryColor, accentColor, accentOpacity }) => (jsxs(Fragment, { children: [jsx("path", { d: PAPER_SHARP, fill: primaryColor }), jsx("path", { d: PAPER_FOLD_SHARP, fill: secondaryColor }), text && (jsx("path", { d: text, stroke: accentColor, strokeOpacity: accentOpacity, strokeWidth: "1.5", fill: "none" }))] })),
|
|
39
|
+
outline: ({ primaryColor, strokeWidth }) => (jsx("path", { d: `${PAPER}${PAPER_FOLD_LINE}${text}`, stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" })),
|
|
40
|
+
duotone: ({ primaryColor, secondaryColor, secondaryOpacity, strokeWidth }) => (jsxs(Fragment, { children: [jsx("path", { d: PAPER, fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: PAPER_FOLD_SHARP, fill: primaryColor, opacity: secondaryOpacity + 0.1 }), jsx("path", { d: `${PAPER}${PAPER_FOLD_LINE}${text}`, stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" })] })),
|
|
41
|
+
vivid: ({ primaryColor, secondaryColor }) => (jsxs(Fragment, { children: [jsx("path", { d: PAPER, fill: primaryColor }), jsx("path", { d: PAPER, fill: "white", opacity: "0.1" }), jsx("path", { d: PAPER_FOLD, fill: secondaryColor }), text && (jsx("path", { d: text, stroke: "white", strokeOpacity: "0.9", strokeWidth: "1.5", strokeLinecap: "round", fill: "none" }))] })),
|
|
42
|
+
},
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export { paperIcon, within };
|
|
@@ -13,13 +13,21 @@ const NtdAccessibility = /* @__PURE__ */ createIcon({
|
|
|
13
13
|
vivid: ({ primaryColor, secondaryColor }) => (jsxs(Fragment, { children: [jsx("circle", { cx: "12", cy: "4", r: "2", fill: primaryColor }), jsx("circle", { cx: "12", cy: "4", r: "2", fill: "white", opacity: "0.08" }), jsx("path", { d: "M12 8c-4 0-6 1-6 2v2h3v8h2v-5h2v5h2v-8h3v-2c0-1-2-2-6-2z", fill: secondaryColor })] })),
|
|
14
14
|
},
|
|
15
15
|
});
|
|
16
|
+
// NtdWheelchair: the rider faces right, leaning back a little (it faced left and sat bolt
|
|
17
|
+
// upright), the arm forward on the rest, the leg out to the footrest, in a wheel that is a full
|
|
18
|
+
// 210° arc around the seat (it was a small ring under it).
|
|
19
|
+
const WC_TORSO = 'M8.2 7.4l2.2 6';
|
|
20
|
+
const WC_ARM = 'M9 9.4h5.6';
|
|
21
|
+
const WC_LEG = 'M10.4 13.4h5l2.5 6.4H21';
|
|
22
|
+
const WC_WHEEL = 'M5.6 10.95A5.6 5.6 0 1 0 13.25 18.6';
|
|
16
23
|
const NtdWheelchair = /* @__PURE__ */ createIcon({
|
|
17
24
|
displayName: 'NtdWheelchair',
|
|
18
25
|
paths: {
|
|
19
|
-
solid: ({ primaryColor }) => (jsxs(Fragment, { children: [jsx("circle", { cx: "
|
|
20
|
-
outline: ({ primaryColor, strokeWidth }) => (jsxs(Fragment, { children: [jsx("circle", { cx: "
|
|
21
|
-
|
|
22
|
-
|
|
26
|
+
solid: ({ primaryColor, strokeWidth }) => (jsxs(Fragment, { children: [jsx("circle", { cx: "8.6", cy: "3.4", r: "2.2", fill: primaryColor }), jsxs("g", { stroke: primaryColor, fill: "none", children: [jsx("path", { d: WC_TORSO, strokeWidth: strokeWidth * 1.4 }), jsx("path", { d: WC_ARM, strokeWidth: strokeWidth * 1.1 }), jsx("path", { d: WC_LEG, strokeWidth: strokeWidth * 1.3 }), jsx("path", { d: WC_WHEEL, strokeWidth: strokeWidth * 1.1 })] })] })),
|
|
27
|
+
outline: ({ primaryColor, strokeWidth }) => (jsxs(Fragment, { children: [jsx("circle", { cx: "8.6", cy: "3.4", r: "1.8", stroke: primaryColor, strokeWidth: strokeWidth }), jsx("path", { d: `${WC_TORSO}${WC_ARM}${WC_LEG}${WC_WHEEL}`, stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" })] })),
|
|
28
|
+
// fills only: the rider primary, the wheel secondary
|
|
29
|
+
duotone: ({ primaryColor, secondaryColor, strokeWidth }) => (jsxs(Fragment, { children: [jsx("path", { d: WC_WHEEL, stroke: secondaryColor, strokeWidth: strokeWidth * 1.1, fill: "none" }), jsx("circle", { cx: "8.6", cy: "3.4", r: "2.2", fill: primaryColor }), jsxs("g", { stroke: primaryColor, fill: "none", children: [jsx("path", { d: WC_TORSO, strokeWidth: strokeWidth * 1.4 }), jsx("path", { d: WC_ARM, strokeWidth: strokeWidth * 1.1 }), jsx("path", { d: WC_LEG, strokeWidth: strokeWidth * 1.3 })] })] })),
|
|
30
|
+
vivid: ({ primaryColor, secondaryColor, strokeWidth }) => (jsxs(Fragment, { children: [jsx("path", { d: WC_WHEEL, stroke: secondaryColor, strokeWidth: strokeWidth * 1.1, fill: "none" }), jsx("circle", { cx: "8.6", cy: "3.4", r: "2.2", fill: primaryColor }), jsxs("g", { stroke: primaryColor, fill: "none", children: [jsx("path", { d: WC_TORSO, strokeWidth: strokeWidth * 1.4 }), jsx("path", { d: WC_ARM, strokeWidth: strokeWidth * 1.1 }), jsx("path", { d: WC_LEG, strokeWidth: strokeWidth * 1.3 })] })] })),
|
|
23
31
|
},
|
|
24
32
|
});
|
|
25
33
|
const NtdBlind = /* @__PURE__ */ createIcon({
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
|
|
2
2
|
import { createIcon } from '../createIcon.js';
|
|
3
|
+
import { within } from '../iconParts.js';
|
|
3
4
|
|
|
4
5
|
const NtdSearch = /* @__PURE__ */ createIcon({
|
|
5
6
|
displayName: 'NtdSearch',
|
|
@@ -10,13 +11,31 @@ const NtdSearch = /* @__PURE__ */ createIcon({
|
|
|
10
11
|
vivid: ({ primaryColor, secondaryColor: _secondaryColor }) => (jsx(Fragment, { children: jsx("path", { d: "M21 21l-4.35-4.35M11 19a8 8 0 100-16 8 8 0 000 16z", stroke: primaryColor, strokeWidth: "2.2", fill: "none" }) })),
|
|
11
12
|
},
|
|
12
13
|
});
|
|
14
|
+
const EDIT_PENCIL = 'M17 3a2.828 2.828 0 114 4L7.5 20.5 2 22l1.5-5.5L17 3z';
|
|
13
15
|
const NtdEdit = /* @__PURE__ */ createIcon({
|
|
14
16
|
displayName: 'NtdEdit',
|
|
15
17
|
paths: {
|
|
16
|
-
|
|
18
|
+
// The band is a cut across the pencil: kept inside it, its ends meet the edges flush (its
|
|
19
|
+
// round caps stuck out of both sides).
|
|
20
|
+
solid: ({ primaryColor, accentColor, accentOpacity, uid }) => (jsxs(Fragment, { children: [jsx("path", { d: EDIT_PENCIL, fill: primaryColor }), within(uid, 'band', jsx("path", { d: EDIT_PENCIL }), jsx("path", { d: "M15 5l4 4", stroke: accentColor, strokeWidth: "1.5", opacity: accentOpacity }))] })),
|
|
17
21
|
outline: ({ primaryColor, strokeWidth }) => (jsxs(Fragment, { children: [jsx("path", { d: "M17 3a2.828 2.828 0 114 4L7.5 20.5 2 22l1.5-5.5L17 3z", stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" }), jsx("path", { d: "M15 5l4 4", stroke: primaryColor, strokeWidth: strokeWidth })] })),
|
|
18
22
|
duotone: ({ primaryColor, secondaryColor, secondaryOpacity, strokeWidth }) => (jsxs(Fragment, { children: [jsx("path", { d: "M17 3a2.828 2.828 0 114 4L7.5 20.5 2 22l1.5-5.5L17 3z", fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: "M17 3a2.828 2.828 0 114 4L7.5 20.5 2 22l1.5-5.5L17 3z", stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" }), jsx("path", { d: "M15 5l4 4", stroke: primaryColor, strokeWidth: strokeWidth })] })),
|
|
19
|
-
vivid: ({ primaryColor, secondaryColor }) => (jsxs(Fragment, { children: [jsx("path", { d:
|
|
23
|
+
vivid: ({ primaryColor, secondaryColor, uid }) => (jsxs(Fragment, { children: [jsx("path", { d: EDIT_PENCIL, fill: primaryColor }), jsx("path", { d: EDIT_PENCIL, fill: "white", opacity: "0.1" }), within(uid, 'band', jsx("path", { d: EDIT_PENCIL }), jsx("path", { d: "M15 5l4 4", stroke: secondaryColor, strokeWidth: "1.8" }))] })),
|
|
24
|
+
},
|
|
25
|
+
});
|
|
26
|
+
// NtdEditDetail: NtdEdit's pencil (scaled 0.62, coordinates baked in so strokes keep their
|
|
27
|
+
// weight) over a square frame left open where the pencil comes out of it — the pen-to-square
|
|
28
|
+
// "edit details" glyph.
|
|
29
|
+
const EDIT_DETAIL_PENCIL = 'M18.54 2.86a1.753 1.753 0 112.48 2.48L12.65 13.71 9.24 14.64l.93-3.41L18.54 2.86z';
|
|
30
|
+
const EDIT_DETAIL_BAND = 'M17.3 4.1l2.48 2.48';
|
|
31
|
+
const EDIT_DETAIL_FRAME = 'M12 4H6a2 2 0 00-2 2v12a2 2 0 002 2h12a2 2 0 002-2v-6';
|
|
32
|
+
const NtdEditDetail = /* @__PURE__ */ createIcon({
|
|
33
|
+
displayName: 'NtdEditDetail',
|
|
34
|
+
paths: {
|
|
35
|
+
solid: ({ primaryColor, accentColor, accentOpacity, strokeWidth, uid }) => (jsxs(Fragment, { children: [jsx("path", { d: EDIT_DETAIL_FRAME, stroke: primaryColor, strokeWidth: strokeWidth * 2, fill: "none" }), jsx("path", { d: EDIT_DETAIL_PENCIL, fill: primaryColor }), within(uid, 'band', jsx("path", { d: EDIT_DETAIL_PENCIL }), jsx("path", { d: EDIT_DETAIL_BAND, stroke: accentColor, strokeWidth: "1.1", opacity: accentOpacity }))] })),
|
|
36
|
+
outline: ({ primaryColor, strokeWidth }) => (jsxs(Fragment, { children: [jsx("path", { d: EDIT_DETAIL_FRAME, stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" }), jsx("path", { d: EDIT_DETAIL_PENCIL, stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" })] })),
|
|
37
|
+
duotone: ({ primaryColor, secondaryColor, secondaryOpacity, strokeWidth }) => (jsxs(Fragment, { children: [jsx("rect", { x: "4", y: "4", width: "16", height: "16", rx: "2", fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: EDIT_DETAIL_FRAME, stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" }), jsx("path", { d: EDIT_DETAIL_PENCIL, fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: EDIT_DETAIL_PENCIL, stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" })] })),
|
|
38
|
+
vivid: ({ primaryColor, secondaryColor, strokeWidth, uid }) => (jsxs(Fragment, { children: [jsx("path", { d: EDIT_DETAIL_FRAME, stroke: secondaryColor, strokeWidth: strokeWidth * 2, fill: "none" }), jsx("path", { d: EDIT_DETAIL_PENCIL, fill: primaryColor }), within(uid, 'band', jsx("path", { d: EDIT_DETAIL_PENCIL }), jsx("path", { d: EDIT_DETAIL_BAND, stroke: secondaryColor, strokeWidth: "1.3" }))] })),
|
|
20
39
|
},
|
|
21
40
|
});
|
|
22
41
|
const NtdTrash = /* @__PURE__ */ createIcon({
|
|
@@ -28,31 +47,40 @@ const NtdTrash = /* @__PURE__ */ createIcon({
|
|
|
28
47
|
vivid: ({ primaryColor, secondaryColor }) => (jsxs(Fragment, { children: [jsx("path", { d: "M5 6l1 14a2 2 0 002 2h8a2 2 0 002-2l1-14H5z", fill: primaryColor }), jsx("path", { d: "M5 6l1 14a2 2 0 002 2h8a2 2 0 002-2l1-14H5z", fill: "white", opacity: "0.1" }), jsx("path", { d: "M3 6h18", stroke: secondaryColor, strokeWidth: "1.8" }), jsx("path", { d: "M8 6V4a2 2 0 012-2h4a2 2 0 012 2v2", stroke: "#3B82F6", strokeWidth: "1.5" }), jsx("line", { x1: "10", y1: "10.5", x2: "10", y2: "17.5", stroke: "#3B82F6", strokeWidth: "1.5" }), jsx("line", { x1: "14", y1: "10.5", x2: "14", y2: "17.5", stroke: "#3B82F6", strokeWidth: "1.5" })] })),
|
|
29
48
|
},
|
|
30
49
|
});
|
|
50
|
+
// NtdSave: a 3.5" floppy — the clipped corner, a wide metal shutter at the top edge with its
|
|
51
|
+
// window, a large label at the bottom. Every part sits inside the body, so no variant pokes out.
|
|
52
|
+
const FLOPPY_BODY = 'M5 3h11.6L21 7.4V19a2 2 0 01-2 2H5a2 2 0 01-2-2V5a2 2 0 012-2z';
|
|
53
|
+
/** The shutter with its window cut out (even-odd). */
|
|
54
|
+
const FLOPPY_SHUTTER = 'M7 3h9.2v4.8a.8.8 0 01-.8.8H7.8a.8.8 0 01-.8-.8zM12.6 4.4v2.8h2V4.4z';
|
|
55
|
+
const FLOPPY_LABEL = 'M6.8 10.6h10.4a1 1 0 011 1v7a1 1 0 01-1 1H6.8a1 1 0 01-1-1v-7a1 1 0 011-1z';
|
|
31
56
|
const NtdSave = /* @__PURE__ */ createIcon({
|
|
32
57
|
displayName: 'NtdSave',
|
|
33
58
|
paths: {
|
|
34
|
-
solid: ({ primaryColor, accentColor, accentOpacity }) => (jsxs(Fragment, { children: [jsx("path", { d:
|
|
35
|
-
outline: ({ primaryColor, strokeWidth }) => (
|
|
36
|
-
|
|
37
|
-
|
|
59
|
+
solid: ({ primaryColor, accentColor, accentOpacity }) => (jsxs(Fragment, { children: [jsx("path", { d: FLOPPY_BODY, fill: primaryColor }), jsxs("g", { fill: accentColor, opacity: accentOpacity, children: [jsx("path", { d: FLOPPY_SHUTTER, fillRule: "evenodd" }), jsx("path", { d: FLOPPY_LABEL })] })] })),
|
|
60
|
+
outline: ({ primaryColor, strokeWidth }) => (jsx("path", { d: `${FLOPPY_BODY}M7.5 3v4h8V3M12.6 4.8v1${FLOPPY_LABEL}`, stroke: primaryColor, strokeWidth: strokeWidth, strokeLinejoin: "round", fill: "none" })),
|
|
61
|
+
// fills only: the body secondary, the shutter and the label primary
|
|
62
|
+
duotone: ({ primaryColor, secondaryColor, secondaryOpacity }) => (jsxs(Fragment, { children: [jsx("path", { d: FLOPPY_BODY, fill: secondaryColor, opacity: secondaryOpacity }), jsxs("g", { fill: primaryColor, children: [jsx("path", { d: FLOPPY_SHUTTER, fillRule: "evenodd" }), jsx("path", { d: FLOPPY_LABEL })] })] })),
|
|
63
|
+
vivid: ({ primaryColor, secondaryColor }) => (jsxs(Fragment, { children: [jsx("path", { d: FLOPPY_BODY, fill: primaryColor }), jsx("path", { d: FLOPPY_SHUTTER, fillRule: "evenodd", fill: "#CBD5E1" }), jsx("path", { d: FLOPPY_LABEL, fill: "white" }), jsx("path", { d: "M5.8 13.2h12.4v-1.6a1 1 0 00-1-1H6.8a1 1 0 00-1 1z", fill: secondaryColor })] })),
|
|
38
64
|
},
|
|
39
65
|
});
|
|
66
|
+
// The shaft stops 2 short of the arrowhead's point: with the square caps of `sharp`, a shaft that
|
|
67
|
+
// ran to the point stuck out of it.
|
|
40
68
|
const NtdDownload = /* @__PURE__ */ createIcon({
|
|
41
69
|
displayName: 'NtdDownload',
|
|
42
70
|
paths: {
|
|
43
|
-
solid: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M7 10l5 5 5-5M12
|
|
44
|
-
outline: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M7 10l5 5 5-5M12
|
|
45
|
-
duotone: ({ primaryColor, secondaryColor, secondaryOpacity, strokeWidth }) => (jsxs(Fragment, { children: [jsx("rect", { x: "3", y: "15", width: "18", height: "6", rx: "2", fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M7 10l5 5 5-5M12
|
|
46
|
-
vivid: ({ primaryColor,
|
|
71
|
+
solid: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M7 10l5 5 5-5M12 13V3", stroke: primaryColor, strokeWidth: strokeWidth * 2 })),
|
|
72
|
+
outline: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M7 10l5 5 5-5M12 13V3", stroke: primaryColor, strokeWidth: strokeWidth })),
|
|
73
|
+
duotone: ({ primaryColor, secondaryColor, secondaryOpacity, strokeWidth }) => (jsxs(Fragment, { children: [jsx("rect", { x: "3", y: "15", width: "18", height: "6", rx: "2", fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M7 10l5 5 5-5M12 13V3", stroke: primaryColor, strokeWidth: strokeWidth })] })),
|
|
74
|
+
vivid: ({ primaryColor, strokeWidth }) => (jsx(Fragment, { children: jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M7 10l5 5 5-5M12 13V3", stroke: primaryColor, strokeWidth: strokeWidth * 2 }) })),
|
|
47
75
|
},
|
|
48
76
|
});
|
|
49
77
|
const NtdUpload = /* @__PURE__ */ createIcon({
|
|
50
78
|
displayName: 'NtdUpload',
|
|
51
79
|
paths: {
|
|
52
|
-
solid: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M17 8l-5-5-5 5M12
|
|
53
|
-
outline: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M17 8l-5-5-5 5M12
|
|
54
|
-
duotone: ({ primaryColor, secondaryColor, secondaryOpacity, strokeWidth }) => (jsxs(Fragment, { children: [jsx("rect", { x: "3", y: "15", width: "18", height: "6", rx: "2", fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M17 8l-5-5-5 5M12
|
|
55
|
-
vivid: ({ primaryColor,
|
|
80
|
+
solid: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M17 8l-5-5-5 5M12 5v10", stroke: primaryColor, strokeWidth: strokeWidth * 2 })),
|
|
81
|
+
outline: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M17 8l-5-5-5 5M12 5v10", stroke: primaryColor, strokeWidth: strokeWidth })),
|
|
82
|
+
duotone: ({ primaryColor, secondaryColor, secondaryOpacity, strokeWidth }) => (jsxs(Fragment, { children: [jsx("rect", { x: "3", y: "15", width: "18", height: "6", rx: "2", fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M17 8l-5-5-5 5M12 5v10", stroke: primaryColor, strokeWidth: strokeWidth })] })),
|
|
83
|
+
vivid: ({ primaryColor, strokeWidth }) => (jsx(Fragment, { children: jsx("path", { d: "M21 15v4a2 2 0 01-2 2H5a2 2 0 01-2-2v-4M17 8l-5-5-5 5M12 5v10", stroke: primaryColor, strokeWidth: strokeWidth * 2 }) })),
|
|
56
84
|
},
|
|
57
85
|
});
|
|
58
86
|
const NtdShare = /* @__PURE__ */ createIcon({
|
|
@@ -82,31 +110,33 @@ const NtdClipboard = /* @__PURE__ */ createIcon({
|
|
|
82
110
|
vivid: ({ primaryColor, secondaryColor }) => (jsxs(Fragment, { children: [jsx("path", { d: "M16 4h2a2 2 0 012 2v14a2 2 0 01-2 2H6a2 2 0 01-2-2V6a2 2 0 012-2h2", fill: primaryColor }), jsx("path", { d: "M16 4h2a2 2 0 012 2v14a2 2 0 01-2 2H6a2 2 0 01-2-2V6a2 2 0 012-2h2", fill: "white", opacity: "0.08" }), jsx("rect", { x: "8", y: "2", width: "8", height: "3.5", rx: "1.5", fill: secondaryColor, stroke: secondaryColor, strokeWidth: "1.5" }), jsx("line", { x1: "8", y1: "12", x2: "16", y2: "12", stroke: "white", strokeWidth: "1", opacity: "0.4" }), jsx("line", { x1: "8", y1: "15.5", x2: "13", y2: "15.5", stroke: "white", strokeWidth: "1", opacity: "0.4" })] })),
|
|
83
111
|
},
|
|
84
112
|
});
|
|
113
|
+
// The stroke glyphs (plus, minus, check, the arrows) are twice the stroke width when filled, so
|
|
114
|
+
// `solid` reads bold next to `outline` and still follows `strokeWidth`.
|
|
85
115
|
const NtdPlus = /* @__PURE__ */ createIcon({
|
|
86
116
|
displayName: 'NtdPlus',
|
|
87
117
|
paths: {
|
|
88
|
-
solid: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M12 5v14M5 12h14", stroke: primaryColor, strokeWidth: strokeWidth *
|
|
118
|
+
solid: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M12 5v14M5 12h14", stroke: primaryColor, strokeWidth: strokeWidth * 2 })),
|
|
89
119
|
outline: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M12 5v14M5 12h14", stroke: primaryColor, strokeWidth: strokeWidth })),
|
|
90
120
|
duotone: ({ primaryColor, secondaryColor, secondaryOpacity, strokeWidth }) => (jsxs(Fragment, { children: [jsx("circle", { cx: "12", cy: "12", r: "9", fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: "M12 8v8M8 12h8", stroke: primaryColor, strokeWidth: strokeWidth })] })),
|
|
91
|
-
vivid: ({ primaryColor,
|
|
121
|
+
vivid: ({ primaryColor, strokeWidth }) => (jsx(Fragment, { children: jsx("path", { d: "M12 5v14M5 12h14", stroke: primaryColor, strokeWidth: strokeWidth * 2 }) })),
|
|
92
122
|
},
|
|
93
123
|
});
|
|
94
124
|
const NtdMinus = /* @__PURE__ */ createIcon({
|
|
95
125
|
displayName: 'NtdMinus',
|
|
96
126
|
paths: {
|
|
97
|
-
solid: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M5 12h14", stroke: primaryColor, strokeWidth: strokeWidth *
|
|
127
|
+
solid: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M5 12h14", stroke: primaryColor, strokeWidth: strokeWidth * 2 })),
|
|
98
128
|
outline: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M5 12h14", stroke: primaryColor, strokeWidth: strokeWidth })),
|
|
99
129
|
duotone: ({ primaryColor, secondaryColor, secondaryOpacity, strokeWidth }) => (jsxs(Fragment, { children: [jsx("circle", { cx: "12", cy: "12", r: "9", fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: "M8 12h8", stroke: primaryColor, strokeWidth: strokeWidth })] })),
|
|
100
|
-
vivid: ({ primaryColor,
|
|
130
|
+
vivid: ({ primaryColor, strokeWidth }) => (jsx(Fragment, { children: jsx("path", { d: "M5 12h14", stroke: primaryColor, strokeWidth: strokeWidth * 2 }) })),
|
|
101
131
|
},
|
|
102
132
|
});
|
|
103
133
|
const NtdCheck = /* @__PURE__ */ createIcon({
|
|
104
134
|
displayName: 'NtdCheck',
|
|
105
135
|
paths: {
|
|
106
|
-
solid: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M20 6L9 17l-5-5", stroke: primaryColor, strokeWidth: strokeWidth *
|
|
136
|
+
solid: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M20 6L9 17l-5-5", stroke: primaryColor, strokeWidth: strokeWidth * 2 })),
|
|
107
137
|
outline: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M20 6L9 17l-5-5", stroke: primaryColor, strokeWidth: strokeWidth })),
|
|
108
138
|
duotone: ({ primaryColor, secondaryColor, secondaryOpacity, strokeWidth }) => (jsxs(Fragment, { children: [jsx("circle", { cx: "12", cy: "12", r: "9", fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: "M17 8l-6.5 6.5L7 11", stroke: primaryColor, strokeWidth: strokeWidth })] })),
|
|
109
|
-
vivid: ({ primaryColor,
|
|
139
|
+
vivid: ({ primaryColor, strokeWidth }) => (jsx(Fragment, { children: jsx("path", { d: "M20 6L9 17l-5-5", stroke: primaryColor, strokeWidth: strokeWidth * 2 }) })),
|
|
110
140
|
},
|
|
111
141
|
});
|
|
112
142
|
const NtdFilter = /* @__PURE__ */ createIcon({
|
|
@@ -200,17 +230,28 @@ const NtdLink = /* @__PURE__ */ createIcon({
|
|
|
200
230
|
paths: {
|
|
201
231
|
solid: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M10 13a5 5 0 007.54.54l3-3a5 5 0 00-7.07-7.07l-1.72 1.71M14 11a5 5 0 00-7.54-.54l-3 3a5 5 0 007.07 7.07l1.71-1.71", stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" })),
|
|
202
232
|
outline: ({ primaryColor, strokeWidth }) => (jsx("path", { d: "M10 13a5 5 0 007.54.54l3-3a5 5 0 00-7.07-7.07l-1.72 1.71M14 11a5 5 0 00-7.54-.54l-3 3a5 5 0 007.07 7.07l1.71-1.71", stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" })),
|
|
203
|
-
|
|
233
|
+
// one ring per colour: the right link primary, the left one secondary
|
|
234
|
+
duotone: ({ primaryColor, secondaryColor, strokeWidth }) => (jsxs(Fragment, { children: [jsx("path", { d: "M14 11a5 5 0 00-7.54-.54l-3 3a5 5 0 007.07 7.07l1.71-1.71", stroke: secondaryColor, strokeWidth: strokeWidth, fill: "none" }), jsx("path", { d: "M10 13a5 5 0 007.54.54l3-3a5 5 0 00-7.07-7.07l-1.72 1.71", stroke: primaryColor, strokeWidth: strokeWidth, fill: "none" })] })),
|
|
204
235
|
vivid: ({ primaryColor, secondaryColor: _secondaryColor }) => (jsx(Fragment, { children: jsx("path", { d: "M10 13a5 5 0 007.54.54l3-3a5 5 0 00-7.07-7.07l-1.72 1.71M14 11a5 5 0 00-7.54-.54l-3 3a5 5 0 007.07 7.07l1.71-1.71", stroke: primaryColor, strokeWidth: "2.2", fill: "none" }) })),
|
|
205
236
|
},
|
|
206
237
|
});
|
|
238
|
+
// NtdSettings: a gear whose eight teeth have flat tops, in every variant but `rounded`, which
|
|
239
|
+
// keeps the round-toothed gear it used to draw everywhere.
|
|
240
|
+
const GEAR = 'M9.95 4.58L10.55 1.7L13.45 1.7L14.05 4.58A7.7 7.7 0 0 1 15.8 5.3L18.26 3.69L20.31 5.74L18.7 8.2A7.7 7.7 0 0 1 19.42 9.95L22.3 10.55L22.3 13.45L19.42 14.05A7.7 7.7 0 0 1 18.7 15.8L20.31 18.26L18.26 20.31L15.8 18.7A7.7 7.7 0 0 1 14.05 19.42L13.45 22.3L10.55 22.3L9.95 19.42A7.7 7.7 0 0 1 8.2 18.7L5.74 20.31L3.69 18.26L5.3 15.8A7.7 7.7 0 0 1 4.58 14.05L1.7 13.45L1.7 10.55L4.58 9.95A7.7 7.7 0 0 1 5.3 8.2L3.69 5.74L5.74 3.69L8.2 5.3A7.7 7.7 0 0 1 9.95 4.58Z';
|
|
241
|
+
const GEAR_ROUND = 'M19.4 15a1.65 1.65 0 00.33 1.82l.06.06a2 2 0 01-2.83 2.83l-.06-.06a1.65 1.65 0 00-1.82-.33 1.65 1.65 0 00-1 1.51V21a2 2 0 01-4 0v-.09A1.65 1.65 0 009 19.4a1.65 1.65 0 00-1.82.33l-.06.06a2 2 0 01-2.83-2.83l.06-.06A1.65 1.65 0 004.68 15a1.65 1.65 0 00-1.51-1H3a2 2 0 010-4h.09A1.65 1.65 0 004.6 8.68a1.65 1.65 0 00-.33-1.82l-.06-.06a2 2 0 012.83-2.83l.06.06A1.65 1.65 0 009 4.6a1.65 1.65 0 001-1.51V3a2 2 0 014 0v.09a1.65 1.65 0 001 1.51 1.65 1.65 0 001.82-.33l.06-.06a2 2 0 012.83 2.83l-.06.06a1.65 1.65 0 00-.33 1.82V9a1.65 1.65 0 001.51 1H21a2 2 0 010 4h-.09a1.65 1.65 0 00-1.51 1z';
|
|
242
|
+
/** The axle hole, r 3.2. */
|
|
243
|
+
const GEAR_HOLE = 'M12 8.8a3.2 3.2 0 100 6.4 3.2 3.2 0 100-6.4z';
|
|
244
|
+
/** The hub around the hole, r 5 — duotone and vivid only. */
|
|
245
|
+
const GEAR_HUB = 'M12 7a5 5 0 100 10 5 5 0 100-10z';
|
|
207
246
|
const NtdSettings = /* @__PURE__ */ createIcon({
|
|
208
247
|
displayName: 'NtdSettings',
|
|
209
248
|
paths: {
|
|
210
|
-
solid: ({ primaryColor
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
249
|
+
solid: ({ primaryColor }) => (jsx("path", { d: `${GEAR}${GEAR_HOLE}`, fillRule: "evenodd", fill: primaryColor })),
|
|
250
|
+
rounded: ({ primaryColor }) => (jsx("path", { d: `${GEAR_ROUND}${GEAR_HOLE}`, fillRule: "evenodd", fill: primaryColor })),
|
|
251
|
+
outline: ({ primaryColor, strokeWidth }) => (jsx("path", { d: `${GEAR}M12 9a3 3 0 100 6 3 3 0 100-6z`, stroke: primaryColor, strokeWidth: strokeWidth, strokeLinejoin: "round", fill: "none" })),
|
|
252
|
+
// fills only: the gear secondary, its hub primary
|
|
253
|
+
duotone: ({ primaryColor, secondaryColor, secondaryOpacity }) => (jsxs(Fragment, { children: [jsx("path", { d: `${GEAR}${GEAR_HOLE}`, fillRule: "evenodd", fill: secondaryColor, opacity: secondaryOpacity }), jsx("path", { d: `${GEAR_HUB}${GEAR_HOLE}`, fillRule: "evenodd", fill: primaryColor })] })),
|
|
254
|
+
vivid: ({ primaryColor, secondaryColor }) => (jsxs(Fragment, { children: [jsx("path", { d: `${GEAR}${GEAR_HOLE}`, fillRule: "evenodd", fill: primaryColor }), jsx("path", { d: `${GEAR_HUB}${GEAR_HOLE}`, fillRule: "evenodd", fill: secondaryColor })] })),
|
|
214
255
|
},
|
|
215
256
|
});
|
|
216
257
|
const NtdLogIn = /* @__PURE__ */ createIcon({
|
|
@@ -270,4 +311,4 @@ const NtdUngroup = /* @__PURE__ */ createIcon({
|
|
|
270
311
|
},
|
|
271
312
|
});
|
|
272
313
|
|
|
273
|
-
export { NtdCheck, NtdClipboard, NtdCopy, NtdDownload, NtdEdit, NtdFilter, NtdGroup, NtdLink, NtdLock, NtdLogIn, NtdLogOut, NtdMinus, NtdPlus, NtdPrint, NtdRedo, NtdReply, NtdSave, NtdSearch, NtdSettings, NtdShare, NtdSort, NtdTrash, NtdUndo, NtdUngroup, NtdUnlock, NtdUpload, NtdZoomIn, NtdZoomOut };
|
|
314
|
+
export { NtdCheck, NtdClipboard, NtdCopy, NtdDownload, NtdEdit, NtdEditDetail, NtdFilter, NtdGroup, NtdLink, NtdLock, NtdLogIn, NtdLogOut, NtdMinus, NtdPlus, NtdPrint, NtdRedo, NtdReply, NtdSave, NtdSearch, NtdSettings, NtdShare, NtdSort, NtdTrash, NtdUndo, NtdUngroup, NtdUnlock, NtdUpload, NtdZoomIn, NtdZoomOut };
|