@papernote/ui 1.14.1 → 2.0.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/index.esm.js +57 -49
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +57 -49
- package/dist/index.js.map +1 -1
- package/dist/styles.css +6228 -6717
- package/package.json +6 -4
- package/src/components/AdminModal.tsx +1 -1
- package/src/components/Autocomplete.tsx +1 -1
- package/src/components/CommandPalette.tsx +2 -2
- package/src/components/DataTable.tsx +1 -1
- package/src/components/Drawer.tsx +1 -1
- package/src/components/MarkdownEditor.tsx +1 -1
- package/src/components/MaskedInput.tsx +1 -1
- package/src/components/Modal.tsx +1 -1
- package/src/components/NotificationBar.tsx +2 -2
- package/src/components/PasswordInput.tsx +1 -1
- package/src/components/SearchBar.tsx +1 -1
- package/src/components/Textarea.tsx +1 -1
- package/src/styles/index.css +50 -160
- package/src/styles/theme.css +302 -0
package/dist/index.esm.js
CHANGED
|
@@ -1293,7 +1293,7 @@ const Textarea = forwardRef(({ label, helperText, validationState, validationMes
|
|
|
1293
1293
|
}
|
|
1294
1294
|
};
|
|
1295
1295
|
return (jsxs("div", { className: "w-full", children: [label && (jsxs("label", { htmlFor: textareaId, className: "label", children: [label, props.required && jsx("span", { className: "text-error-500 ml-1", children: "*" })] })), jsxs("div", { className: "relative", children: [jsx("textarea", { ref: textareaRef, id: textareaId, value: value, maxLength: maxLength, rows: autoExpand ? minRows : rows, enterKeyHint: enterKeyHint, className: `
|
|
1296
|
-
block w-full border rounded-lg text-ink-800 placeholder-ink-400
|
|
1296
|
+
block w-full border rounded-lg text-ink-800 placeholder:text-ink-400
|
|
1297
1297
|
bg-white bg-subtle-grain transition-all duration-200
|
|
1298
1298
|
focus:outline-none focus:ring-2 ${getResizeClass()}
|
|
1299
1299
|
disabled:bg-paper-100 disabled:text-ink-400 disabled:cursor-not-allowed disabled:opacity-60
|
|
@@ -5089,7 +5089,7 @@ function Modal({ isOpen, onClose, title, children, size = 'md', showCloseButton
|
|
|
5089
5089
|
return createPortal(jsx(BottomSheet, { isOpen: isOpen, onClose: onClose, title: title, height: mobileHeight, showHandle: mobileShowHandle, showCloseButton: showCloseButton, children: children }), document.body);
|
|
5090
5090
|
}
|
|
5091
5091
|
// Render as standard modal on desktop
|
|
5092
|
-
const modalContent = (jsx("div", { className: "fixed inset-0 z-50 flex items-center justify-center p-4 bg-ink-900
|
|
5092
|
+
const modalContent = (jsx("div", { className: "fixed inset-0 z-50 flex items-center justify-center p-4 bg-ink-900/50 backdrop-blur-sm animate-fade-in", onMouseDown: handleBackdropMouseDown, onClick: handleBackdropClick, children: jsxs("div", { ref: modalRef, className: `${sizeClasses$a[size]} w-full bg-white bg-subtle-grain rounded-xl shadow-2xl border border-paper-200 ${getAnimationClass()}`, role: "dialog", "aria-modal": "true", "aria-labelledby": titleId, tabIndex: -1, children: [jsxs("div", { className: "flex items-center justify-between px-6 py-4 border-b border-paper-200", children: [jsx("h3", { id: titleId, className: "text-lg font-medium text-ink-900", children: title }), showCloseButton && (jsx("button", { onClick: onClose, className: "text-ink-400 hover:text-ink-600 transition-colors", "aria-label": "Close modal", children: jsx(X, { className: "h-5 w-5" }) }))] }), jsx("div", { className: `px-6 py-4 ${scrollable || maxHeight ? 'overflow-y-auto' : ''}`, style: {
|
|
5093
5093
|
maxHeight: maxHeight || (scrollable ? 'calc(100vh - 200px)' : undefined),
|
|
5094
5094
|
}, children: children })] }) }));
|
|
5095
5095
|
return createPortal(modalContent, document.body);
|
|
@@ -6237,7 +6237,7 @@ function Drawer({ isOpen, onClose, title, children, placement = 'right', size =
|
|
|
6237
6237
|
if (!isOpen)
|
|
6238
6238
|
return null;
|
|
6239
6239
|
const isHorizontal = placement === 'left' || placement === 'right';
|
|
6240
|
-
return (jsxs("div", { className: "fixed inset-0 z-50 flex", children: [showOverlay && (jsx("div", { className: "fixed inset-0 bg-ink-900
|
|
6240
|
+
return (jsxs("div", { className: "fixed inset-0 z-50 flex", children: [showOverlay && (jsx("div", { className: "fixed inset-0 bg-ink-900/50 backdrop-blur-sm animate-fade-in", onClick: handleOverlayClick, "aria-hidden": "true" })), jsxs("div", { className: `
|
|
6241
6241
|
fixed ${placementClasses[placement]}
|
|
6242
6242
|
${sizeClasses$9[placement][size]}
|
|
6243
6243
|
bg-white border-paper-200 shadow-2xl
|
|
@@ -6790,10 +6790,10 @@ function CommandPalette({ commands, open, onOpenChange, placeholder = 'Type a co
|
|
|
6790
6790
|
};
|
|
6791
6791
|
if (!open)
|
|
6792
6792
|
return null;
|
|
6793
|
-
return createPortal(jsxs("div", { className: "fixed inset-0 z-50 flex items-start justify-center pt-[20vh] animate-fade-in", children: [jsx("div", { className: "absolute inset-0 bg-ink-900
|
|
6793
|
+
return createPortal(jsxs("div", { className: "fixed inset-0 z-50 flex items-start justify-center pt-[20vh] animate-fade-in", children: [jsx("div", { className: "absolute inset-0 bg-ink-900/50 backdrop-blur-sm", onClick: () => onOpenChange(false) }), jsxs("div", { className: "relative w-full max-w-2xl mx-4 bg-white rounded-xl shadow-2xl border border-paper-200 overflow-hidden animate-scale-in", children: [jsxs("div", { className: "flex items-center gap-3 px-4 py-3 border-b border-paper-200", children: [jsx(Search, { className: "h-5 w-5 text-ink-400" }), jsx("input", { ref: inputRef, type: "text", value: searchQuery, onChange: (e) => {
|
|
6794
6794
|
setSearchQuery(e.target.value);
|
|
6795
6795
|
setSelectedIndex(0);
|
|
6796
|
-
}, placeholder: placeholder, className: "flex-1 text-base text-ink-900 placeholder-ink-400 bg-transparent border-none outline-none" }), trigger && (jsx("kbd", { className: "hidden sm:inline-block px-2 py-1 text-xs font-mono text-ink-500 bg-paper-100 border border-paper-300 rounded", children: trigger }))] }), jsx("div", { ref: listRef, className: "max-h-[400px] overflow-y-auto py-2", children: flatCommands.length === 0 ? (jsx("div", { className: "px-4 py-8 text-center text-sm text-ink-500", children: "No commands found" })) : (jsxs(Fragment, { children: [Object.entries(grouped).map(([groupName, groupCommands]) => (jsxs("div", { children: [jsx("div", { className: "px-4 py-1.5 text-xs font-semibold text-ink-500 uppercase tracking-wider", children: groupName }), groupCommands.map((command) => {
|
|
6796
|
+
}, placeholder: placeholder, className: "flex-1 text-base text-ink-900 placeholder:text-ink-400 bg-transparent border-none outline-none" }), trigger && (jsx("kbd", { className: "hidden sm:inline-block px-2 py-1 text-xs font-mono text-ink-500 bg-paper-100 border border-paper-300 rounded", children: trigger }))] }), jsx("div", { ref: listRef, className: "max-h-[400px] overflow-y-auto py-2", children: flatCommands.length === 0 ? (jsx("div", { className: "px-4 py-8 text-center text-sm text-ink-500", children: "No commands found" })) : (jsxs(Fragment, { children: [Object.entries(grouped).map(([groupName, groupCommands]) => (jsxs("div", { children: [jsx("div", { className: "px-4 py-1.5 text-xs font-semibold text-ink-500 uppercase tracking-wider", children: groupName }), groupCommands.map((command) => {
|
|
6797
6797
|
const globalIndex = flatCommands.indexOf(command);
|
|
6798
6798
|
const isSelected = globalIndex === selectedIndex;
|
|
6799
6799
|
return (jsxs("button", { "data-index": globalIndex, onClick: () => executeCommand(command), onMouseEnter: () => setSelectedIndex(globalIndex), className: `
|
|
@@ -7735,7 +7735,7 @@ const PasswordInput = forwardRef(({ value, onChange, label, placeholder = 'Enter
|
|
|
7735
7735
|
}, [value, requirements]);
|
|
7736
7736
|
return (jsxs("div", { className: className, children: [label && (jsxs("label", { className: "block text-sm font-medium text-ink-900 mb-1.5", children: [label, required && jsx("span", { className: "text-error-500 ml-1", children: "*" })] })), jsxs("div", { className: "relative", children: [jsx("input", { ref: inputRef, type: showPassword ? 'text' : 'password', value: value, onChange: (e) => onChange(e.target.value), placeholder: placeholder, disabled: disabled, className: `
|
|
7737
7737
|
w-full px-3 py-2 pr-10
|
|
7738
|
-
text-sm text-ink-900 placeholder-ink-400
|
|
7738
|
+
text-sm text-ink-900 placeholder:text-ink-400
|
|
7739
7739
|
bg-white border rounded-lg
|
|
7740
7740
|
focus:outline-none focus:ring-2 focus:ring-accent-400 focus:border-accent-400
|
|
7741
7741
|
disabled:bg-paper-100 disabled:cursor-not-allowed
|
|
@@ -7844,7 +7844,7 @@ const MaskedInput = forwardRef(({ value, onChange, maskType = 'phone', customMas
|
|
|
7844
7844
|
};
|
|
7845
7845
|
return (jsxs("div", { className: className, children: [label && (jsxs("label", { className: "block text-sm font-medium text-ink-900 mb-1.5", children: [label, required && jsx("span", { className: "text-error-500 ml-1", children: "*" })] })), jsx("input", { ref: inputRef, type: "text", value: displayValue, onChange: handleChange, onPaste: handlePaste, placeholder: getPlaceholder(), disabled: disabled, className: `
|
|
7846
7846
|
w-full px-3 py-2
|
|
7847
|
-
text-sm text-ink-900 placeholder-ink-400
|
|
7847
|
+
text-sm text-ink-900 placeholder:text-ink-400
|
|
7848
7848
|
bg-white border rounded-lg
|
|
7849
7849
|
focus:outline-none focus:ring-2 focus:ring-accent-400 focus:border-accent-400
|
|
7850
7850
|
disabled:bg-paper-100 disabled:cursor-not-allowed
|
|
@@ -8059,7 +8059,7 @@ const Autocomplete = forwardRef(({ value, onChange, options = [], onSearch, labe
|
|
|
8059
8059
|
}
|
|
8060
8060
|
}, placeholder: placeholder, disabled: disabled, className: `
|
|
8061
8061
|
w-full pl-9 pr-9 py-2
|
|
8062
|
-
text-sm text-ink-900 placeholder-ink-400
|
|
8062
|
+
text-sm text-ink-900 placeholder:text-ink-400
|
|
8063
8063
|
bg-white border rounded-lg
|
|
8064
8064
|
focus:outline-none focus:ring-2 focus:ring-accent-400 focus:border-accent-400
|
|
8065
8065
|
disabled:bg-paper-100 disabled:cursor-not-allowed
|
|
@@ -8619,7 +8619,7 @@ function MarkdownEditor({ value, onChange, label, placeholder = '# Start writing
|
|
|
8619
8619
|
: 'text-ink-600 hover:bg-white/50'}
|
|
8620
8620
|
`, children: "Split" })] }))] }), showHelp && (jsxs("button", { type: "button", onClick: () => setShowHelpPanel(!showHelpPanel), className: "flex items-center gap-1 px-2 py-1 text-xs text-ink-600 hover:text-ink-900 transition-colors", children: [jsx(Info, { className: "h-3.5 w-3.5" }), "Markdown Help"] }))] }), showHelpPanel && (jsx("div", { className: "p-3 border border-b-0 border-paper-300 bg-accent-50 text-xs", children: jsx("div", { className: "grid grid-cols-2 gap-2", children: helpContent.map((item, index) => (jsxs("div", { className: "flex items-center gap-2", children: [jsx("code", { className: "px-2 py-0.5 bg-white rounded text-ink-900 font-mono", children: item.syntax }), jsx("span", { className: "text-ink-600", children: item.description })] }, index))) }) })), jsxs("div", { className: `flex border border-paper-300 rounded-b-lg overflow-hidden ${mode === 'split' ? '' : ''}`, children: [(mode === 'edit' || mode === 'split') && (jsx("div", { className: `${mode === 'split' ? 'w-1/2 border-r border-paper-300' : 'w-full'}`, children: jsx("textarea", { value: value, onChange: (e) => onChange(e.target.value), placeholder: placeholder, disabled: disabled, className: `
|
|
8621
8621
|
w-full p-3 outline-none resize-none
|
|
8622
|
-
text-sm text-ink-900 font-mono placeholder-ink-400
|
|
8622
|
+
text-sm text-ink-900 font-mono placeholder:text-ink-400
|
|
8623
8623
|
${disabled ? 'bg-paper-100 cursor-not-allowed' : 'bg-white'}
|
|
8624
8624
|
`, style: { minHeight, maxHeight } }) })), (mode === 'preview' || mode === 'split') && (jsx("div", { className: `${mode === 'split' ? 'w-1/2' : 'w-full'} overflow-y-auto bg-white`, children: jsx("div", { className: "p-3 prose prose-sm max-w-none", style: { minHeight, maxHeight }, dangerouslySetInnerHTML: { __html: markdownToHtml(value) } }) }))] }), jsx("style", { children: `
|
|
8625
8625
|
.prose h1 { font-size: 1.875rem; font-weight: 700; margin-bottom: 1rem; }
|
|
@@ -14329,7 +14329,7 @@ function SearchBar({ value, onChange, placeholder = 'Search...', className = '',
|
|
|
14329
14329
|
onSearch(value);
|
|
14330
14330
|
}
|
|
14331
14331
|
};
|
|
14332
|
-
return (jsxs("div", { className: `flex-1 max-w-2xl relative ${className}`, children: [jsx("div", { className: "absolute inset-y-0 left-0 pl-4 flex items-center pointer-events-none", children: jsx(Search, { className: "h-5 w-5 text-ink-400" }) }), jsx("input", { type: "text", value: value, onChange: (e) => onChange(e.target.value), onKeyDown: handleKeyDown, disabled: disabled, className: "block w-full pl-11 pr-4 py-3 border border-paper-300 rounded-lg leading-5 bg-white placeholder-ink-400 text-ink-800 focus:outline-none focus:placeholder-ink-300 focus:ring-2 focus:ring-accent-400 focus:border-accent-400 hover:border-paper-400 transition-all sm:text-sm disabled:bg-paper-100 disabled:cursor-not-allowed", placeholder: placeholder })] }));
|
|
14332
|
+
return (jsxs("div", { className: `flex-1 max-w-2xl relative ${className}`, children: [jsx("div", { className: "absolute inset-y-0 left-0 pl-4 flex items-center pointer-events-none", children: jsx(Search, { className: "h-5 w-5 text-ink-400" }) }), jsx("input", { type: "text", value: value, onChange: (e) => onChange(e.target.value), onKeyDown: handleKeyDown, disabled: disabled, className: "block w-full pl-11 pr-4 py-3 border border-paper-300 rounded-lg leading-5 bg-white placeholder:text-ink-400 text-ink-800 focus:outline-none focus:placeholder:text-ink-300 focus:ring-2 focus:ring-accent-400 focus:border-accent-400 hover:border-paper-400 transition-all sm:text-sm disabled:bg-paper-100 disabled:cursor-not-allowed", placeholder: placeholder })] }));
|
|
14333
14333
|
}
|
|
14334
14334
|
|
|
14335
14335
|
function NotificationIndicator({ count = 0, onClick, className = '', maxCount = 99, variant = 'default', }) {
|
|
@@ -15701,7 +15701,7 @@ mobileView = 'auto', cardConfig, cardGap = 'md', cardClassName, }) {
|
|
|
15701
15701
|
})()] }, rowKey));
|
|
15702
15702
|
});
|
|
15703
15703
|
};
|
|
15704
|
-
const tableContent = (jsxs("div", { className: `bg-white rounded-lg shadow border-2 ${borderColor} ${virtualized ? 'overflow-hidden' : 'overflow-x-auto overflow-y-visible'} ${className}`, style: { position: 'relative' }, children: [loading && data.length > 0 && (jsx("div", { className: "absolute inset-0 bg-white
|
|
15704
|
+
const tableContent = (jsxs("div", { className: `bg-white rounded-lg shadow border-2 ${borderColor} ${virtualized ? 'overflow-hidden' : 'overflow-x-auto overflow-y-visible'} ${className}`, style: { position: 'relative' }, children: [loading && data.length > 0 && (jsx("div", { className: "absolute inset-0 bg-white/75 flex items-center justify-center z-20", style: { backdropFilter: 'blur(2px)' }, children: jsxs("div", { className: "flex flex-col items-center gap-3", children: [jsx("div", { className: "loading-spinner", style: { width: '32px', height: '32px', borderWidth: '3px' } }), jsx("span", { className: "text-sm font-medium text-ink-600", children: "Loading..." })] }) })), jsxs("table", { className: `table-stable w-full ${bordered ? 'border-collapse' : ''}`, role: "grid", "aria-label": "Data table", "aria-rowcount": data.length, "aria-colcount": visibleColumns.length, children: [jsxs("colgroup", { children: [selectable && jsx("col", { className: "w-12" }), ((expandable || expandedRowConfig) && showExpandChevron) && jsx("col", { className: "w-10" }), allActions.length > 0 && jsx("col", { style: { width: '28px' } }), visibleColumns.map((column, index) => {
|
|
15705
15705
|
const columnKey = String(column.key);
|
|
15706
15706
|
const dynamicWidth = columnWidths[columnKey];
|
|
15707
15707
|
return (jsx("col", { style: getColumnStyle(column, dynamicWidth) }, index));
|
|
@@ -15796,44 +15796,52 @@ function getAugmentedNamespace(n) {
|
|
|
15796
15796
|
* (A1, A1:C5, ...)
|
|
15797
15797
|
*/
|
|
15798
15798
|
|
|
15799
|
-
|
|
15799
|
+
var collection;
|
|
15800
|
+
var hasRequiredCollection;
|
|
15801
|
+
|
|
15802
|
+
function requireCollection () {
|
|
15803
|
+
if (hasRequiredCollection) return collection;
|
|
15804
|
+
hasRequiredCollection = 1;
|
|
15805
|
+
class Collection {
|
|
15800
15806
|
|
|
15801
|
-
|
|
15802
|
-
|
|
15803
|
-
|
|
15804
|
-
|
|
15805
|
-
|
|
15806
|
-
|
|
15807
|
-
|
|
15808
|
-
|
|
15809
|
-
|
|
15810
|
-
|
|
15811
|
-
|
|
15807
|
+
constructor(data, refs) {
|
|
15808
|
+
if (data == null && refs == null) {
|
|
15809
|
+
this._data = [];
|
|
15810
|
+
this._refs = [];
|
|
15811
|
+
} else {
|
|
15812
|
+
if (data.length !== refs.length)
|
|
15813
|
+
throw Error('Collection: data length should match references length.');
|
|
15814
|
+
this._data = data;
|
|
15815
|
+
this._refs = refs;
|
|
15816
|
+
}
|
|
15817
|
+
}
|
|
15812
15818
|
|
|
15813
|
-
|
|
15814
|
-
|
|
15815
|
-
|
|
15819
|
+
get data() {
|
|
15820
|
+
return this._data;
|
|
15821
|
+
}
|
|
15816
15822
|
|
|
15817
|
-
|
|
15818
|
-
|
|
15819
|
-
|
|
15823
|
+
get refs() {
|
|
15824
|
+
return this._refs;
|
|
15825
|
+
}
|
|
15820
15826
|
|
|
15821
|
-
|
|
15822
|
-
|
|
15823
|
-
|
|
15827
|
+
get length() {
|
|
15828
|
+
return this._data.length;
|
|
15829
|
+
}
|
|
15824
15830
|
|
|
15825
|
-
|
|
15826
|
-
|
|
15827
|
-
|
|
15828
|
-
|
|
15829
|
-
|
|
15830
|
-
|
|
15831
|
-
|
|
15832
|
-
|
|
15833
|
-
|
|
15834
|
-
}
|
|
15831
|
+
/**
|
|
15832
|
+
* Add data and references to this collection.
|
|
15833
|
+
* @param {{}} obj - data
|
|
15834
|
+
* @param {{}} ref - reference
|
|
15835
|
+
*/
|
|
15836
|
+
add(obj, ref) {
|
|
15837
|
+
this._data.push(obj);
|
|
15838
|
+
this._refs.push(ref);
|
|
15839
|
+
}
|
|
15840
|
+
}
|
|
15835
15841
|
|
|
15836
|
-
|
|
15842
|
+
collection = Collection;
|
|
15843
|
+
return collection;
|
|
15844
|
+
}
|
|
15837
15845
|
|
|
15838
15846
|
var helpers;
|
|
15839
15847
|
var hasRequiredHelpers;
|
|
@@ -15842,7 +15850,7 @@ function requireHelpers () {
|
|
|
15842
15850
|
if (hasRequiredHelpers) return helpers;
|
|
15843
15851
|
hasRequiredHelpers = 1;
|
|
15844
15852
|
const FormulaError = requireError();
|
|
15845
|
-
const Collection =
|
|
15853
|
+
const Collection = requireCollection();
|
|
15846
15854
|
|
|
15847
15855
|
const Types = {
|
|
15848
15856
|
NUMBER: 0,
|
|
@@ -25496,7 +25504,7 @@ var engineering = EngineeringFunctions;
|
|
|
25496
25504
|
|
|
25497
25505
|
const FormulaError$b = requireError();
|
|
25498
25506
|
const {FormulaHelpers: FormulaHelpers$8, Types: Types$6, WildCard, Address: Address$3} = requireHelpers();
|
|
25499
|
-
const Collection$2 =
|
|
25507
|
+
const Collection$2 = requireCollection();
|
|
25500
25508
|
const H$5 = FormulaHelpers$8;
|
|
25501
25509
|
|
|
25502
25510
|
const ReferenceFunctions$1 = {
|
|
@@ -37124,7 +37132,7 @@ var parsing = {
|
|
|
37124
37132
|
const FormulaError$4 = requireError();
|
|
37125
37133
|
const {Address: Address$1} = requireHelpers();
|
|
37126
37134
|
const {Prefix: Prefix$1, Postfix: Postfix$1, Infix: Infix$1, Operators: Operators$1} = operators;
|
|
37127
|
-
const Collection$1 =
|
|
37135
|
+
const Collection$1 = requireCollection();
|
|
37128
37136
|
const MAX_ROW$1 = 1048576, MAX_COLUMN$1 = 16384;
|
|
37129
37137
|
const {NotAllInputParsedException} = require$$4;
|
|
37130
37138
|
|
|
@@ -37886,7 +37894,7 @@ var hooks$1 = {
|
|
|
37886
37894
|
const FormulaError$2 = requireError();
|
|
37887
37895
|
const {FormulaHelpers: FormulaHelpers$1, Types, Address} = requireHelpers();
|
|
37888
37896
|
const {Prefix, Postfix, Infix, Operators} = operators;
|
|
37889
|
-
const Collection =
|
|
37897
|
+
const Collection = requireCollection();
|
|
37890
37898
|
const MAX_ROW = 1048576, MAX_COLUMN = 16384;
|
|
37891
37899
|
|
|
37892
37900
|
let Utils$1 = class Utils {
|
|
@@ -61931,7 +61939,7 @@ function AdminModal({ isOpen, onClose, title, subtitle, onSubmit, isSaving = fal
|
|
|
61931
61939
|
onSubmit(formData);
|
|
61932
61940
|
}
|
|
61933
61941
|
};
|
|
61934
|
-
return (jsx("div", { className: "fixed inset-0 bg-black
|
|
61942
|
+
return (jsx("div", { className: "fixed inset-0 bg-black/50 flex items-center justify-center z-50 p-4 admin-modal-overlay", children: jsxs("div", { className: `bg-white rounded-lg w-full ${sizeClasses[size]} flex flex-col overflow-hidden shadow-2xl admin-modal-content`, style: { height: height }, children: [jsx("div", { className: "fixed inset-0 pointer-events-none admin-modal-sidebar-placeholder" }), jsxs("div", { className: "px-6 py-4 border-b", children: [jsx("h3", { className: "text-lg font-semibold", children: title }), subtitle && jsx("p", { className: "text-sm text-gray-500 mt-1", children: subtitle })] }), tabs.length > 1 && (jsx("div", { className: "border-b border-gray-200 bg-white", children: jsx("nav", { className: "-mb-px flex items-center px-6 admin-modal-tabs", "aria-label": "Tabs", children: tabs.map((tab, index) => (jsxs(React__default.Fragment, { children: [jsx("button", { type: "button", onClick: () => onTabChange(tab.id), className: `whitespace-nowrap border-b-2 py-3 px-4 text-sm font-medium transition-colors ${activeTabId === tab.id
|
|
61935
61943
|
? 'border-blue-500 text-blue-600'
|
|
61936
61944
|
: 'border-transparent text-gray-500 hover:border-gray-300 hover:text-gray-700'}`, "aria-current": activeTabId === tab.id ? 'page' : undefined, children: tab.label }), index < tabs.length - 1 && (jsx("div", { className: "admin-modal-tab-separator" }))] }, tab.id))) }) })), onSubmit ? (jsx("form", { className: "flex-1 overflow-y-auto min-h-0 h-0 px-6 py-6 admin-modal-form", onSubmit: handleFormSubmit, id: formId, noValidate: true, children: activeTab?.content || children })) : (jsx("div", { className: "flex-1 overflow-y-auto min-h-0 h-0 px-6 py-6 admin-modal-content-area", children: activeTab?.content || children })), jsxs("div", { className: "px-6 py-4 border-t bg-gray-50 flex justify-between gap-3", children: [jsx("button", { type: "button", onClick: onClose, className: "px-4 py-2 text-sm text-gray-600 hover:text-gray-800", disabled: isSaving, children: "Cancel" }), jsxs("div", { className: "flex gap-3", children: [customFooterActions, onSubmit && (jsx("button", { type: "submit", form: formId, disabled: isSaving, className: "px-4 py-2 text-sm bg-primary-600 text-white rounded hover:bg-primary-700 disabled:opacity-50 disabled:cursor-not-allowed", children: isSaving ? 'Saving...' : 'Save Changes' }))] })] })] }) }));
|
|
61937
61945
|
}
|
|
@@ -62152,7 +62160,7 @@ function NotificationBar({ notifications, onDismiss }) {
|
|
|
62152
62160
|
}
|
|
62153
62161
|
return (jsx("div", { className: "fixed top-4 right-4 z-50 space-y-3 max-w-md", children: notifications.map((notification) => {
|
|
62154
62162
|
const IconComponent = getNotificationIcon(notification.type);
|
|
62155
|
-
return (jsx("div", { className: `border-2 rounded-xl p-4 backdrop-blur-sm transform transition-all duration-300 ease-in-out animate-slide-in ${notificationStyles[notification.type]}`, children: jsxs("div", { className: "flex items-start space-x-3", children: [jsx("div", { className: `flex-shrink-0 p-1 rounded-full bg-white
|
|
62163
|
+
return (jsx("div", { className: `border-2 rounded-xl p-4 backdrop-blur-sm transform transition-all duration-300 ease-in-out animate-slide-in ${notificationStyles[notification.type]}`, children: jsxs("div", { className: "flex items-start space-x-3", children: [jsx("div", { className: `flex-shrink-0 p-1 rounded-full bg-white/50 ${iconStyles[notification.type]}`, children: jsx(IconComponent, { className: "h-5 w-5" }) }), jsxs("div", { className: "flex-1 min-w-0", children: [jsx("p", { className: "text-sm font-semibold mb-1 leading-tight", children: notification.title }), jsx("p", { className: "text-sm leading-relaxed opacity-90", children: notification.message })] }), notification.dismissible && onDismiss && (jsx("button", { onClick: () => onDismiss(notification.id), className: `flex-shrink-0 p-1.5 hover:bg-white/60 rounded-full transition-all duration-200 ${iconStyles[notification.type]} hover:scale-110`, title: "Dismiss notification", children: jsx(X, { className: "h-4 w-4" }) }))] }) }, notification.id));
|
|
62156
62164
|
}) }));
|
|
62157
62165
|
}
|
|
62158
62166
|
|