@7shifts/sous-chef 3.10.3 → 3.11.1
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/dist/empty_states/EmptyStateContainer/EmptyStateContainerCTA/EmptyStateContainerCTA.d.ts +2 -1
- package/dist/forms/TimeField/TimeField.d.ts +7 -1
- package/dist/forms/TimeField/TimeFieldDropdown/TimeFieldDropdown.d.ts +12 -0
- package/dist/forms/TimeField/TimeFieldDropdown/index.d.ts +1 -0
- package/dist/forms/TimeField/TimeFieldDropdownTrigger/TimeFieldDropdownTrigger.d.ts +9 -0
- package/dist/forms/TimeField/TimeFieldDropdownTrigger/index.d.ts +1 -0
- package/dist/forms/TimeField/TimeFieldInput/TimeFieldInput.d.ts +7 -0
- package/dist/forms/TimeField/TimeFieldInput/index.d.ts +1 -0
- package/dist/forms/TimeField/domain.d.ts +1 -0
- package/dist/forms/hooks/useRangeFieldControllers.d.ts +7 -8
- package/dist/index.css +223 -208
- package/dist/index.js +1443 -1163
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +1443 -1163
- package/dist/index.modern.js.map +1 -1
- package/dist/lists/DataTableRow/DataTableRow.d.ts +1 -1
- package/dist/overlay/Dropdown/Dropdown.d.ts +5 -3
- package/dist/overlay/Dropdown/DropdownContext.d.ts +1 -1
- package/dist/overlay/DropdownList/DropdownList.d.ts +1 -0
- package/dist/overlay/DropdownList/domain.d.ts +1 -0
- package/dist/overlay/DropdownPane/DropdownPane.d.ts +1 -0
- package/dist/overlay/Modal/ModalContext.d.ts +7 -0
- package/dist/overlay/Modal/ModalHeader/ModalHeader.d.ts +1 -1
- package/dist/overlay/hooks/useListKeyboardNavigation/useListKeyboardNavigation.d.ts +1 -0
- package/dist/utils/date.d.ts +5 -0
- package/package.json +1 -1
|
@@ -12,5 +12,5 @@ declare type Props = {
|
|
|
12
12
|
hasDefaultCell?: boolean;
|
|
13
13
|
testId?: string;
|
|
14
14
|
} & Omit<React.HTMLProps<HTMLDivElement>, 'css'>;
|
|
15
|
-
declare const DataTableRow: React.ForwardRefExoticComponent<Pick<Props, "children" | "type" | "default" | "disabled" | "onClick" | "onMouseEnter" | "onMouseLeave" | "onBlur" | "onFocus" | "onKeyDown" | "id" | "title" | "href" | "target" | "testId" | "size" | "cite" | "data" | "form" | "label" | "slot" | "span" | "style" | "summary" | "pattern" | "key" | "color" | "className" | "height" | "lang" | "max" | "media" | "method" | "min" | "name" | "width" | "role" | "tabIndex" | "crossOrigin" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "list" | "contextMenu" | "start" | "wrap" | "dir" | "checked" | "placeholder" | "prefix" | "value" | "defaultValue" | "content" | "translate" | "hidden" | "open" | "multiple" | "actions" | "src" | "as" | "draggable" | "autoComplete" | "autoFocus" | "maxLength" | "step" | "isSelected" | "readOnly" | "required" | "sizes" | "htmlFor" | "accept" | "acceptCharset" | "action" | "allowFullScreen" | "allowTransparency" | "alt" | "async" | "autoPlay" | "capture" | "cellPadding" | "cellSpacing" | "charSet" | "challenge" | "classID" | "cols" | "colSpan" | "controls" | "coords" | "dateTime" | "defer" | "download" | "encType" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "frameBorder" | "headers" | "high" | "hrefLang" | "httpEquiv" | "integrity" | "keyParams" | "keyType" | "kind" | "loop" | "low" | "manifest" | "marginHeight" | "marginWidth" | "mediaGroup" | "minLength" | "muted" | "nonce" | "noValidate" | "optimum" | "playsInline" | "poster" | "preload" | "rel" | "reversed" | "rows" | "rowSpan" | "sandbox" | "scope" | "scoped" | "scrolling" | "seamless" | "
|
|
15
|
+
declare const DataTableRow: React.ForwardRefExoticComponent<Pick<Props, "children" | "type" | "default" | "disabled" | "onClick" | "onMouseEnter" | "onMouseLeave" | "onBlur" | "onFocus" | "onKeyDown" | "id" | "title" | "href" | "target" | "testId" | "size" | "cite" | "data" | "form" | "label" | "slot" | "span" | "style" | "summary" | "pattern" | "key" | "color" | "className" | "height" | "lang" | "max" | "media" | "method" | "min" | "name" | "width" | "role" | "tabIndex" | "crossOrigin" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "list" | "contextMenu" | "start" | "wrap" | "dir" | "checked" | "placeholder" | "prefix" | "value" | "defaultValue" | "content" | "translate" | "hidden" | "open" | "multiple" | "actions" | "src" | "as" | "draggable" | "autoComplete" | "autoFocus" | "maxLength" | "step" | "isSelected" | "readOnly" | "required" | "sizes" | "htmlFor" | "selected" | "accept" | "acceptCharset" | "action" | "allowFullScreen" | "allowTransparency" | "alt" | "async" | "autoPlay" | "capture" | "cellPadding" | "cellSpacing" | "charSet" | "challenge" | "classID" | "cols" | "colSpan" | "controls" | "coords" | "dateTime" | "defer" | "download" | "encType" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "frameBorder" | "headers" | "high" | "hrefLang" | "httpEquiv" | "integrity" | "keyParams" | "keyType" | "kind" | "loop" | "low" | "manifest" | "marginHeight" | "marginWidth" | "mediaGroup" | "minLength" | "muted" | "nonce" | "noValidate" | "optimum" | "playsInline" | "poster" | "preload" | "rel" | "reversed" | "rows" | "rowSpan" | "sandbox" | "scope" | "scoped" | "scrolling" | "seamless" | "shape" | "srcDoc" | "srcLang" | "srcSet" | "useMap" | "wmode" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "spellCheck" | "radioGroup" | "about" | "datatype" | "inlist" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "hasDefaultPadding" | "hasDefaultCell"> & React.RefAttributes<HTMLTableRowElement>>;
|
|
16
16
|
export default DataTableRow;
|
|
@@ -1,12 +1,14 @@
|
|
|
1
|
-
import React from 'react';
|
|
1
|
+
import React, { RefAttributes } from 'react';
|
|
2
2
|
import { DropdownAlignment, DropdownTrigger } from './types';
|
|
3
3
|
declare type Props = {
|
|
4
|
-
trigger: React.ReactElement
|
|
4
|
+
trigger: React.ReactElement & RefAttributes<unknown>;
|
|
5
5
|
width?: number;
|
|
6
|
+
maxHeight?: number;
|
|
6
7
|
triggersOn?: DropdownTrigger;
|
|
7
8
|
alignment?: DropdownAlignment;
|
|
8
9
|
testId?: string;
|
|
9
10
|
children: React.ReactNode;
|
|
11
|
+
triggerWidth?: 'full' | 'restricted';
|
|
10
12
|
};
|
|
11
|
-
declare const Dropdown: ({ trigger, triggersOn, alignment, width, testId, children }: Props) => JSX.Element;
|
|
13
|
+
declare const Dropdown: ({ trigger, triggersOn, alignment, width, maxHeight, testId, children, triggerWidth }: Props) => JSX.Element;
|
|
12
14
|
export default Dropdown;
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
export declare type DropdownContextType = {
|
|
3
3
|
onToggleDropdown: () => void;
|
|
4
4
|
isOpen: boolean;
|
|
5
|
-
triggerRef: React.
|
|
5
|
+
triggerRef: React.Ref<HTMLElement>;
|
|
6
6
|
paneRef: React.RefObject<HTMLElement>;
|
|
7
7
|
};
|
|
8
8
|
declare const DropdownContext: React.Context<DropdownContextType>;
|
|
@@ -5,5 +5,5 @@ declare type Props = {
|
|
|
5
5
|
onClose?: () => void;
|
|
6
6
|
loading?: boolean;
|
|
7
7
|
};
|
|
8
|
-
declare const ModalHeader: ({ header, subHeader, onClose, loading }: Props) => JSX.Element;
|
|
8
|
+
declare const ModalHeader: ({ header, subHeader, onClose, loading }: Props) => JSX.Element | null;
|
|
9
9
|
export default ModalHeader;
|
|
@@ -5,5 +5,6 @@ declare type UseListKeyboardNavigation = {
|
|
|
5
5
|
};
|
|
6
6
|
export declare const useListKeyboardNavigation: (listItems: ListItem[], actions?: {
|
|
7
7
|
onPressEnter?: (() => void) | undefined;
|
|
8
|
+
onNavigate?: ((focusItem: number | null) => void) | undefined;
|
|
8
9
|
} | undefined) => UseListKeyboardNavigation;
|
|
9
10
|
export {};
|
package/dist/utils/date.d.ts
CHANGED
|
@@ -9,6 +9,7 @@ export declare function createWeekRange(date: Date, weekStart: WeekStart): FullD
|
|
|
9
9
|
export declare const DAYS: string[];
|
|
10
10
|
export declare const MONTH_NAMES: string[];
|
|
11
11
|
export declare type WeekStart = 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
12
|
+
export declare type TimeInterval = 15 | 30;
|
|
12
13
|
export declare type FullDateRange = {
|
|
13
14
|
start: Date;
|
|
14
15
|
end: Date;
|
|
@@ -17,6 +18,10 @@ export declare type DateRange = {
|
|
|
17
18
|
start?: Date;
|
|
18
19
|
end?: Date;
|
|
19
20
|
};
|
|
21
|
+
export declare type TimeRange = {
|
|
22
|
+
start?: string;
|
|
23
|
+
end?: string;
|
|
24
|
+
};
|
|
20
25
|
export declare type BlockedDays = Modifier | Modifier[];
|
|
21
26
|
export declare type DateRangeError = string | {
|
|
22
27
|
[K in keyof DateRange]: string;
|