@nice2dev/ui 1.4.2 → 1.4.4
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 +39 -0
- package/dist/{NiceDataGrid-CrKDzMM1.cjs → NiceDataGrid-mrnaLHQk.cjs} +1 -1
- package/dist/{NiceForm-CT9hEXpc.cjs → NiceForm-O3sv-DNX.cjs} +1 -1
- package/dist/NiceMention-tgJKS8PH.cjs +432 -0
- package/dist/{NiceSavedQueryPanel-C5Ab_NWx.cjs → NiceSavedQueryPanel-BPGpKWN2.cjs} +1 -1
- package/dist/{NiceScheduler-BZQAKEVF.cjs → NiceScheduler-Boo-D1S-.cjs} +1 -1
- package/dist/{core-lazy-VTd5zfoZ.cjs → core-lazy-C_qnVGxE.cjs} +1 -1
- package/dist/data.cjs +1 -1
- package/dist/editors/pickers/NiceDateRangeBox.mjs +258 -227
- package/dist/editors/pickers/NiceDateTimePicker.mjs +403 -388
- package/dist/editors/rich/NiceMarkdownEditor.mjs +2 -1
- package/dist/editors/rich/NiceWiki.mjs +225 -158
- package/dist/editors.cjs +1 -1
- package/dist/editors.d.ts +29 -7
- package/dist/index.cjs +112 -112
- package/dist/index.d.ts +90 -7
- package/dist/index.mjs +716 -713
- package/dist/style.css +2 -2
- package/dist/tools/NiceThemeGalleryPicker.mjs +362 -0
- package/package.json +4 -4
- package/dist/NiceMention-BZEHqPrf.cjs +0 -432
package/dist/index.d.ts
CHANGED
|
@@ -11989,9 +11989,13 @@ export declare interface NiceDateRangeBoxProps extends NiceFormFieldProps {
|
|
|
11989
11989
|
max?: string;
|
|
11990
11990
|
/** Show a clear button. */
|
|
11991
11991
|
clearable?: boolean;
|
|
11992
|
-
/**
|
|
11992
|
+
/**
|
|
11993
|
+
* Placeholder for the start input. Default: the field's date mask in the locale's order
|
|
11994
|
+
* (`DD.MM.YYYY`), so the format to type in shows (1.4.4 — it was "Start date"); with
|
|
11995
|
+
* `singleField`, both ends' masks (`DD.MM.YYYY – DD.MM.YYYY`).
|
|
11996
|
+
*/
|
|
11993
11997
|
startPlaceholder?: string;
|
|
11994
|
-
/** Placeholder for the end input. */
|
|
11998
|
+
/** Placeholder for the end input. Default: the field's date mask, as the start's. */
|
|
11995
11999
|
endPlaceholder?: string;
|
|
11996
12000
|
/** Label shown above (or before) the start picker. */
|
|
11997
12001
|
startLabel?: string;
|
|
@@ -12000,7 +12004,9 @@ export declare interface NiceDateRangeBoxProps extends NiceFormFieldProps {
|
|
|
12000
12004
|
/**
|
|
12001
12005
|
* Collapse the pair into ONE field with ONE popup: the field shows
|
|
12002
12006
|
* `start – end` and the popup holds a single calendar on which the span is
|
|
12003
|
-
* painted in two clicks. Default `false` (two fields, two popups).
|
|
12007
|
+
* painted in two clicks. Default `false` (two fields, two popups). Both ends can also be typed
|
|
12008
|
+
* into the field through its mask (1.4.4; days, days with a time, months — weeks and times only
|
|
12009
|
+
* pick); an end is set once its half is a real date.
|
|
12004
12010
|
*/
|
|
12005
12011
|
singleField?: boolean;
|
|
12006
12012
|
/** Layout direction for the two pickers (default `horizontal`). */
|
|
@@ -23488,6 +23494,67 @@ export { niceThemeFluent }
|
|
|
23488
23494
|
|
|
23489
23495
|
export { niceThemeFluentV2 }
|
|
23490
23496
|
|
|
23497
|
+
/** A tab of the full gallery. `label` is English; the i18n key is `theme.category.<id>`. */
|
|
23498
|
+
export declare interface NiceThemeGalleryCategory {
|
|
23499
|
+
id: string;
|
|
23500
|
+
label: string;
|
|
23501
|
+
}
|
|
23502
|
+
|
|
23503
|
+
/** One theme of a {@link NiceThemeGalleryPicker}. A {@link NiceThemeCatalogEntry} is one. */
|
|
23504
|
+
export declare interface NiceThemeGalleryItem {
|
|
23505
|
+
/** The theme's name — unique in the gallery, the value it picks. */
|
|
23506
|
+
name: string;
|
|
23507
|
+
theme: NiceTheme;
|
|
23508
|
+
/** The id of its category (the full gallery's tabs). */
|
|
23509
|
+
category?: string;
|
|
23510
|
+
}
|
|
23511
|
+
|
|
23512
|
+
/**
|
|
23513
|
+
* {@link NiceThemeGalleryPicker} — theme cards with large previews in each theme's own colours;
|
|
23514
|
+
* a picker with `value` / `onChange`, and with `limit` one row with a full-screen "Show more".
|
|
23515
|
+
*/
|
|
23516
|
+
export declare const NiceThemeGalleryPicker: default_2.FC<NiceThemeGalleryPickerProps>;
|
|
23517
|
+
|
|
23518
|
+
/** Props for the {@link NiceThemeGalleryPicker} component. */
|
|
23519
|
+
export declare interface NiceThemeGalleryPickerProps extends NiceBaseProps {
|
|
23520
|
+
/** The themes. Default: the built-in catalog (`NICE_THEME_CATALOG_ENTRIES`). */
|
|
23521
|
+
themes?: readonly NiceThemeGalleryItem[];
|
|
23522
|
+
/** The full gallery's category tabs. Default: the built-in catalog's categories. */
|
|
23523
|
+
categories?: readonly NiceThemeGalleryCategory[];
|
|
23524
|
+
/** The picked theme's name — **controlled**. Omit it to let the gallery keep its own pick. */
|
|
23525
|
+
value?: string | null;
|
|
23526
|
+
/** The theme picked first in the uncontrolled mode. Default: none. */
|
|
23527
|
+
defaultValue?: string | null;
|
|
23528
|
+
/** Called when a card is picked, with its name and item. */
|
|
23529
|
+
onChange?: (name: string, item: NiceThemeGalleryItem) => void;
|
|
23530
|
+
/**
|
|
23531
|
+
* Show only this many cards, in one row, and a "Show more" button that opens every theme
|
|
23532
|
+
* full-screen (with search and categories). The picked theme is always among the row's cards.
|
|
23533
|
+
*/
|
|
23534
|
+
limit?: number;
|
|
23535
|
+
/** The width of a card's preview in px. Default 240. */
|
|
23536
|
+
previewWidth?: number;
|
|
23537
|
+
/** A search field over the cards (the full gallery always has one). Default `false`. */
|
|
23538
|
+
searchable?: boolean;
|
|
23539
|
+
/** The gallery's name: the list's accessible name and the full gallery's title. Default "Theme gallery". */
|
|
23540
|
+
label?: string;
|
|
23541
|
+
/** Something more on a card, under its name — a badge, a rating. */
|
|
23542
|
+
renderCardExtra?: (item: NiceThemeGalleryItem) => default_2.ReactNode;
|
|
23543
|
+
/** An extra class for a card (a review status frame). */
|
|
23544
|
+
cardClassName?: (item: NiceThemeGalleryItem) => string | undefined;
|
|
23545
|
+
}
|
|
23546
|
+
|
|
23547
|
+
/**
|
|
23548
|
+
* A theme as a small app, `width` px wide: top bar with a brand mark, a title and an avatar;
|
|
23549
|
+
* sidebar with its header levels, the active row and three items; a page title, two figure cards,
|
|
23550
|
+
* a bar chart and a row of buttons — in the theme's layout colours.
|
|
23551
|
+
*/
|
|
23552
|
+
export declare const NiceThemeGalleryPreview: default_2.FC<{
|
|
23553
|
+
roles: NiceThemePreviewRoles;
|
|
23554
|
+
width?: number;
|
|
23555
|
+
label?: string;
|
|
23556
|
+
}>;
|
|
23557
|
+
|
|
23491
23558
|
export { NiceThemeGradient }
|
|
23492
23559
|
|
|
23493
23560
|
export { niceThemeHighContrast }
|
|
@@ -25940,6 +26007,10 @@ export { NiceWebSocketMessageType }
|
|
|
25940
26007
|
/**
|
|
25941
26008
|
* {@link NiceWiki} — Wiki module with page tree sidebar, rich content area,
|
|
25942
26009
|
* inline editor (edit mode), page create/delete, and version history hooks.
|
|
26010
|
+
* Works on its own since 1.4.4: each page can carry its `content`, and the selection, the edit
|
|
26011
|
+
* mode and the saved edits are kept inside unless their props are given; the tree filters as
|
|
26012
|
+
* you search, breadcrumbs lead back up, Markdown renders, and edit mode uses NiceMarkdownEditor
|
|
26013
|
+
* or NiceHtmlEditor with Save and Cancel.
|
|
25943
26014
|
*/
|
|
25944
26015
|
export declare const NiceWiki: default_2.ForwardRefExoticComponent<NiceWikiProps & default_2.RefAttributes<HTMLDivElement>> & {
|
|
25945
26016
|
displayName: string;
|
|
@@ -25948,14 +26019,21 @@ export declare const NiceWiki: default_2.ForwardRefExoticComponent<NiceWikiProps
|
|
|
25948
26019
|
export declare interface NiceWikiProps extends NiceFormFieldProps {
|
|
25949
26020
|
/** Page tree. Defaults to none. */
|
|
25950
26021
|
pages?: WikiPage[];
|
|
25951
|
-
/** Currently selected page id. */
|
|
26022
|
+
/** Currently selected page id — **controlled**. Omit it to let the wiki keep its own selection. */
|
|
25952
26023
|
selectedPageId?: string | number;
|
|
25953
|
-
/**
|
|
26024
|
+
/** The page selected first in the uncontrolled mode (1.4.4). Default: the first page. */
|
|
26025
|
+
defaultSelectedPageId?: string | number;
|
|
26026
|
+
/**
|
|
26027
|
+
* Content of the currently selected page (HTML or Markdown) — **controlled**. Omit it and the
|
|
26028
|
+
* wiki shows each page's own `content`, edits it in a draft and keeps what is saved (1.4.4).
|
|
26029
|
+
*/
|
|
25954
26030
|
content?: string;
|
|
25955
|
-
/** Content format. */
|
|
26031
|
+
/** Content format: HTML (edited in NiceHtmlEditor) or Markdown (NiceMarkdownEditor, rendered). */
|
|
25956
26032
|
contentFormat?: 'html' | 'markdown';
|
|
25957
|
-
/** Whether the editor is in edit mode. */
|
|
26033
|
+
/** Whether the editor is in edit mode — **controlled**. Omit it to let the Edit button work alone. */
|
|
25958
26034
|
editing?: boolean;
|
|
26035
|
+
/** Edit mode at first in the uncontrolled mode (1.4.4). Default `false`. */
|
|
26036
|
+
defaultEditing?: boolean;
|
|
25959
26037
|
/** Fires when a page is selected. */
|
|
25960
26038
|
onPageSelect?: (page: WikiPage) => void;
|
|
25961
26039
|
/** Fires when content changes (in edit mode). */
|
|
@@ -31825,6 +31903,11 @@ export declare interface WikiPage {
|
|
|
31825
31903
|
updatedBy?: string;
|
|
31826
31904
|
/** Whether this page is a draft. */
|
|
31827
31905
|
isDraft?: boolean;
|
|
31906
|
+
/**
|
|
31907
|
+
* The page's content (in `contentFormat`) — shown, edited and saved inside the wiki when the
|
|
31908
|
+
* `content` prop is not given (1.4.4), so a wiki works from its page data alone.
|
|
31909
|
+
*/
|
|
31910
|
+
content?: string;
|
|
31828
31911
|
}
|
|
31829
31912
|
|
|
31830
31913
|
/** A wiki page version. */
|