@rolder-kit/ui 0.1.0-alpha.1 → 0.1.0-alpha.10
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/RouterLink.d.ts +1 -1
- package/dist/RouterLink.js +1 -1
- package/dist/editor/Toolbar.js +1 -1
- package/dist/error/DefaultError.js +1 -1
- package/dist/error/DefaultNotFound.js +1 -1
- package/dist/error/Forbidden.js +1 -1
- package/dist/error/defaultErrorNotification.js +1 -1
- package/dist/form/buttons/CancelButton.d.ts +1 -1
- package/dist/form/buttons/CancelButton.js +1 -1
- package/dist/form/buttons/SubmitButton.d.ts +1 -1
- package/dist/form/buttons/SubmitButton.js +1 -1
- package/dist/form/buttons/SubscribeActionIcon.d.ts +1 -1
- package/dist/form/buttons/SubscribeActionIcon.js +1 -1
- package/dist/form/buttons/SubscribeButton.d.ts +1 -1
- package/dist/form/buttons/SubscribeButton.js +1 -1
- package/dist/form/fields/MultiSelectField.d.ts +1 -1
- package/dist/form/fields/MultiSelectField.js +1 -1
- package/dist/form/fields/NumberField.d.ts +1 -1
- package/dist/form/fields/NumberField.js +1 -1
- package/dist/form/fields/PasswordField.d.ts +1 -1
- package/dist/form/fields/PasswordField.js +1 -1
- package/dist/form/fields/SelectField.d.ts +1 -1
- package/dist/form/fields/SelectField.js +1 -1
- package/dist/form/fields/SwitchField.d.ts +1 -1
- package/dist/form/fields/SwitchField.js +1 -1
- package/dist/form/fields/TextField.d.ts +1 -1
- package/dist/form/fields/TextField.js +1 -1
- package/dist/form/fields/TextPasswordField.d.ts +1 -1
- package/dist/form/fields/TextPasswordField.js +1 -1
- package/dist/form/fields/TextareaField.d.ts +1 -1
- package/dist/form/fields/TextareaField.js +1 -1
- package/dist/hoverPaper/HoverPaper.d.ts +1 -1
- package/dist/hoverPaper/HoverPaper.js +1 -1
- package/dist/hoverPaper/usePaperHover.js +1 -1
- package/dist/index.d.ts +0 -1
- package/dist/index.js +0 -1
- package/dist/saveInput/JsonInput.js +2 -1
- package/dist/saveInput/NumberInput.d.ts +1 -1
- package/dist/saveInput/NumberInput.js +2 -1
- package/dist/saveInput/Select.d.ts +1 -1
- package/dist/saveInput/Select.js +2 -1
- package/dist/saveInput/Switch.d.ts +1 -1
- package/dist/saveInput/Switch.js +2 -1
- package/dist/saveInput/TextInput.d.ts +1 -1
- package/dist/saveInput/TextInput.js +2 -1
- package/dist/saveInput/Textarea.d.ts +1 -1
- package/dist/saveInput/Textarea.js +2 -1
- package/dist/scrollArea/Root.d.ts +1 -1
- package/dist/scrollArea/Root.js +3 -2
- package/dist/scrollArea/ScrollButton.d.ts +1 -1
- package/dist/scrollArea/ScrollButton.js +1 -1
- package/dist/styles.css +69 -0
- package/package.json +31 -15
package/dist/RouterLink.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type ActionIconProps, type AnchorProps, type ButtonProps, type UnstyledButtonProps } from '@
|
|
1
|
+
import { type ActionIconProps, type AnchorProps, type ButtonProps, type UnstyledButtonProps } from '@mantine/core';
|
|
2
2
|
import { type LinkComponent } from '@tanstack/react-router';
|
|
3
3
|
interface MantineAnchorProps extends Omit<AnchorProps, 'href'> {
|
|
4
4
|
}
|
package/dist/RouterLink.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { ActionIcon, Anchor, Button, UnstyledButton } from "@
|
|
2
|
+
import { ActionIcon, Anchor, Button, UnstyledButton } from "@mantine/core";
|
|
3
3
|
import { createLink } from "@tanstack/react-router";
|
|
4
4
|
import { forwardRef } from "react";
|
|
5
5
|
const MantineLinkComponent = /*#__PURE__*/ forwardRef(({ classNames, ...props }, ref)=>/*#__PURE__*/ jsx(Anchor, {
|
package/dist/editor/Toolbar.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Loader } from "@mantine/core";
|
|
2
3
|
import { RichTextEditor } from "@mantine/tiptap";
|
|
3
|
-
import { Loader } from "@rolder-kit/mantine";
|
|
4
4
|
import { IconCheck } from "@tabler/icons-react";
|
|
5
5
|
import { getDisabledToolbar, useEditor } from "./store.js";
|
|
6
6
|
const Toolbar = ({ saving, children })=>{
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Button, Group, Stack, Title } from "@
|
|
2
|
+
import { Button, Group, Stack, Title } from "@mantine/core";
|
|
3
3
|
import { rootRouteId, useMatch, useRouter } from "@tanstack/react-router";
|
|
4
4
|
import { RouterLink } from "../RouterLink.js";
|
|
5
5
|
const DefaultError = ({ error })=>{
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Stack, Text, Title } from "@
|
|
2
|
+
import { Stack, Text, Title } from "@mantine/core";
|
|
3
3
|
import { RouterLink } from "../RouterLink.js";
|
|
4
4
|
const DefaultNotFound = ()=>/*#__PURE__*/ jsxs(Stack, {
|
|
5
5
|
align: "center",
|
package/dist/error/Forbidden.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { Button } from "@
|
|
2
|
+
import { Button } from "@mantine/core";
|
|
3
3
|
import { IconDeviceFloppy } from "@tabler/icons-react";
|
|
4
4
|
import { useFormContext } from "../context.js";
|
|
5
5
|
const SubmitButton = (props)=>{
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { type MultiSelectProps } from '@
|
|
1
|
+
import { type MultiSelectProps } from '@mantine/core';
|
|
2
2
|
export declare const MultiSelectField: React.FC<MultiSelectProps>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { type NumberInputProps } from '@
|
|
1
|
+
import { type NumberInputProps } from '@mantine/core';
|
|
2
2
|
export declare const NumberField: React.FC<NumberInputProps>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { type PasswordInputProps } from '@
|
|
1
|
+
import { type PasswordInputProps } from '@mantine/core';
|
|
2
2
|
export declare const PasswordField: React.FC<PasswordInputProps>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { type SelectProps } from '@
|
|
1
|
+
import { type SelectProps } from '@mantine/core';
|
|
2
2
|
export declare const SelectField: React.FC<SelectProps>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { type SwitchProps } from '@
|
|
1
|
+
import { type SwitchProps } from '@mantine/core';
|
|
2
2
|
export declare const SwitchField: React.FC<SwitchProps>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { type TextInputProps } from '@
|
|
1
|
+
import { type TextInputProps } from '@mantine/core';
|
|
2
2
|
export declare const TextField: React.FC<TextInputProps>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { type TextInputProps } from '@
|
|
1
|
+
import { type TextInputProps } from '@mantine/core';
|
|
2
2
|
export declare const TextPasswordField: React.FC<TextInputProps>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { ActionIcon, TextInput } from "@
|
|
2
|
+
import { ActionIcon, TextInput } from "@mantine/core";
|
|
3
3
|
import { IconRefresh } from "@tabler/icons-react";
|
|
4
4
|
import omgopass from "omgopass";
|
|
5
5
|
import { useFieldContext } from "../context.js";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { type TextareaProps } from '@
|
|
1
|
+
import { type TextareaProps } from '@mantine/core';
|
|
2
2
|
export declare const TextareaField: React.FC<TextareaProps>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { Paper } from "@
|
|
2
|
+
import { Paper } from "@mantine/core";
|
|
3
3
|
import { forwardRef } from "react";
|
|
4
4
|
const HoverPaper = /*#__PURE__*/ forwardRef(({ disabled, classNames, ...props }, ref)=>/*#__PURE__*/ jsx(Paper, {
|
|
5
5
|
ref: ref,
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Box, Loader
|
|
2
|
+
import { Box, Loader } from "@mantine/core";
|
|
3
|
+
import { useDebouncedCallback } from "@mantine/hooks";
|
|
3
4
|
import { useState } from "react";
|
|
4
5
|
import { JsonInput } from "../JsonInput.js";
|
|
5
6
|
const JsonInput_JsonInput = ({ initialValue, onChange, debounce = 300, ...props })=>{
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { Loader, NumberInput
|
|
2
|
+
import { Loader, NumberInput } from "@mantine/core";
|
|
3
|
+
import { useDebouncedCallback } from "@mantine/hooks";
|
|
3
4
|
import { useState } from "react";
|
|
4
5
|
const NumberInput_NumberInput = ({ initialValue, onChange, debounce = 300, ...props })=>{
|
|
5
6
|
const [value, setValue] = useState(initialValue);
|
package/dist/saveInput/Select.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { Loader, Select
|
|
2
|
+
import { Loader, Select } from "@mantine/core";
|
|
3
|
+
import { useDebouncedCallback } from "@mantine/hooks";
|
|
3
4
|
import { useState } from "react";
|
|
4
5
|
const Select_Select = ({ initialValue, onChange, debounce = 300, ...props })=>{
|
|
5
6
|
const [value, setValue] = useState(initialValue);
|
package/dist/saveInput/Switch.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { Box, Loader, Switch
|
|
2
|
+
import { Box, Loader, Switch } from "@mantine/core";
|
|
3
|
+
import { useDebouncedCallback } from "@mantine/hooks";
|
|
3
4
|
import { useState } from "react";
|
|
4
5
|
const Switch_Switch = ({ initialValue, onChange, debounce = 300, w, ...props })=>{
|
|
5
6
|
const [value, setValue] = useState(initialValue);
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { Loader, TextInput
|
|
2
|
+
import { Loader, TextInput } from "@mantine/core";
|
|
3
|
+
import { useDebouncedCallback } from "@mantine/hooks";
|
|
3
4
|
import { useState } from "react";
|
|
4
5
|
const TextInput_TextInput = ({ initialValue, onChange, debounce = 300, ...props })=>{
|
|
5
6
|
const [value, setValue] = useState(initialValue || '');
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { Loader, Textarea
|
|
2
|
+
import { Loader, Textarea } from "@mantine/core";
|
|
3
|
+
import { useDebouncedCallback } from "@mantine/hooks";
|
|
3
4
|
import { useState } from "react";
|
|
4
5
|
const Textarea_Textarea = ({ initialValue, onChange, debounce = 300, ...props })=>{
|
|
5
6
|
const [value, setValue] = useState(initialValue);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type MantineRadius, type ScrollAreaProps as MantineScrollAreaProps } from '@
|
|
1
|
+
import { type MantineRadius, type ScrollAreaProps as MantineScrollAreaProps } from '@mantine/core';
|
|
2
2
|
export interface ScrollAreaProps extends Omit<MantineScrollAreaProps, 'h'> {
|
|
3
3
|
height: MantineScrollAreaProps['h'];
|
|
4
4
|
radius?: MantineRadius;
|
package/dist/scrollArea/Root.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { Box, ScrollArea, getRadius
|
|
2
|
+
import { Box, ScrollArea, getRadius } from "@mantine/core";
|
|
3
|
+
import { useElementSize } from "@mantine/hooks";
|
|
3
4
|
import { useEffect, useRef } from "react";
|
|
4
5
|
import { isAboveCenter } from "./methods.js";
|
|
5
6
|
import { getHasScrollableContent, getHeight, getIsAboveCenter, getScrollAreaRef, setAutoScroll, setHeight, setIsAboveCenter, setScrollAreaRef } from "./store.js";
|
|
@@ -11,7 +12,7 @@ const Root = ({ children, height, radius, autoScroll = false, ...props })=>{
|
|
|
11
12
|
});
|
|
12
13
|
useEffect(()=>{
|
|
13
14
|
if (getHeight() !== contentHeight) setHeight(contentHeight);
|
|
14
|
-
if (scrollAreaRef.current &&
|
|
15
|
+
if (scrollAreaRef.current && getScrollAreaRef() !== scrollAreaRef.current) setScrollAreaRef(scrollAreaRef.current);
|
|
15
16
|
}, [
|
|
16
17
|
contentHeight
|
|
17
18
|
]);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { ActionIcon } from "@
|
|
2
|
+
import { ActionIcon } from "@mantine/core";
|
|
3
3
|
import { IconChevronDown, IconChevronUp } from "@tabler/icons-react";
|
|
4
4
|
import { scrollToBottom, scrollToTop } from "./methods.js";
|
|
5
5
|
import { useHasScrollableContent, useIsAboveCenter } from "./store.js";
|
package/dist/styles.css
ADDED
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
.rolder-chat-input-root {
|
|
2
|
+
background-color: light-dark(var(--mantine-color-white), var(--mantine-color-dark-6));
|
|
3
|
+
|
|
4
|
+
&:focus-within {
|
|
5
|
+
border-color: var(--mantine-primary-color-filled);
|
|
6
|
+
border-color: var(--mantine-primary-color-filled);
|
|
7
|
+
outline: none;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.rolder-chat-input-textarea {
|
|
12
|
+
border: 0;
|
|
13
|
+
border-radius: 8px;
|
|
14
|
+
overflow: hidden;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.rolder-chat-input-file-action-action {
|
|
18
|
+
color: light-dark(var(--mantine-color-gray-7), var(--mantine-color-dark-1));
|
|
19
|
+
|
|
20
|
+
&[data-disabled] {
|
|
21
|
+
color: light-dark(var(--mantine-color-gray-5), var(--mantine-color-dark-3));
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.rolder-editor-root {
|
|
26
|
+
--editor-border-color: light-dark(var(--mantine-color-gray-3), var(--mantine-color-dark-4));
|
|
27
|
+
border: rem(1px) solid var(--editor-border-color);
|
|
28
|
+
border-radius: var(--mantine-radius-md);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.rolder-editor-content {
|
|
32
|
+
border-radius: var(--mantine-radius-md);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.rolder-editor-toolbar {
|
|
36
|
+
border-color: var(--editor-border-color);
|
|
37
|
+
border-top-left-radius: var(--mantine-radius-md);
|
|
38
|
+
border-top-right-radius: var(--mantine-radius-md);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.rolder-hover-paper-root {
|
|
42
|
+
transition: background-color .2s ease-in-out;
|
|
43
|
+
|
|
44
|
+
&:hover {
|
|
45
|
+
background-color: light-dark(var(--mantine-color-gray-0), var(--mantine-color-dark-6));
|
|
46
|
+
cursor: pointer;
|
|
47
|
+
transition: background-color .2s ease-in-out;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
&[data-disabled] {
|
|
51
|
+
background-color: unset;
|
|
52
|
+
cursor: default;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.rolder-router-link-root {
|
|
57
|
+
color: inherit;
|
|
58
|
+
text-decoration: none;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.rolder-scroll-area-viewport {
|
|
62
|
+
border-radius: var(--radius);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.rolder-scroll-area-scrollbar {
|
|
66
|
+
border-top-right-radius: var(--radius);
|
|
67
|
+
border-bottom-right-radius: var(--radius);
|
|
68
|
+
}
|
|
69
|
+
|
package/package.json
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rolder-kit/ui",
|
|
3
|
-
"version": "0.1.0-alpha.
|
|
3
|
+
"version": "0.1.0-alpha.10",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
7
7
|
"types": "./dist/index.d.ts",
|
|
8
8
|
"import": "./dist/index.js"
|
|
9
9
|
},
|
|
10
|
+
"./styles.css": "./dist/styles.css",
|
|
10
11
|
"./editor": {
|
|
11
12
|
"types": "./dist/editor/index.d.ts",
|
|
12
13
|
"import": "./dist/editor/index.js"
|
|
@@ -21,7 +22,7 @@
|
|
|
21
22
|
},
|
|
22
23
|
"./hoverPaper": {
|
|
23
24
|
"types": "./dist/hoverPaper/index.d.ts",
|
|
24
|
-
"
|
|
25
|
+
"default": "./dist/hoverPaper/index.js"
|
|
25
26
|
},
|
|
26
27
|
"./saveInput": {
|
|
27
28
|
"types": "./dist/saveInput/index.d.ts",
|
|
@@ -42,24 +43,39 @@
|
|
|
42
43
|
"prepublishOnly": "bun run build",
|
|
43
44
|
"check": "biome check --write && tsc --noEmit"
|
|
44
45
|
},
|
|
46
|
+
"dependencies": {
|
|
47
|
+
"@rolder-kit/mantine": "0.1.0-alpha.18",
|
|
48
|
+
"@rolder-kit/tanstack": "0.1.0-alpha.11"
|
|
49
|
+
},
|
|
50
|
+
"devDependencies": {
|
|
51
|
+
"@types/omgopass": "^3.2.3"
|
|
52
|
+
},
|
|
45
53
|
"peerDependencies": {
|
|
46
|
-
"@
|
|
47
|
-
"@
|
|
48
|
-
"@mantine/
|
|
49
|
-
"@tiptap
|
|
50
|
-
"@tiptap/extension-
|
|
51
|
-
"@tiptap/extension-
|
|
52
|
-
"@tiptap/extension-
|
|
53
|
-
"@tiptap/extension-task-
|
|
54
|
-
"@tiptap/extension-
|
|
55
|
-
"@tiptap/
|
|
56
|
-
"@tiptap/
|
|
54
|
+
"@mantine/core": "^8.3.15",
|
|
55
|
+
"@mantine/hooks": "^8.3.15",
|
|
56
|
+
"@mantine/notifications": "^8.3.15",
|
|
57
|
+
"@mantine/tiptap": "^8.3.15",
|
|
58
|
+
"@tiptap/extension-highlight": "^3.20.0",
|
|
59
|
+
"@tiptap/extension-placeholder": "^3.20.0",
|
|
60
|
+
"@tiptap/extension-table": "^3.20.0",
|
|
61
|
+
"@tiptap/extension-task-item": "^3.20.0",
|
|
62
|
+
"@tiptap/extension-task-list": "^3.20.0",
|
|
63
|
+
"@tiptap/extension-text-align": "^3.20.0",
|
|
64
|
+
"@tiptap/react": "^3.20.0",
|
|
65
|
+
"@tiptap/starter-kit": "^3.20.0",
|
|
57
66
|
"nanostores": "^1.1.0",
|
|
58
67
|
"@nanostores/react": "^1.0.0",
|
|
59
|
-
"@tanstack/react-router": "^1.
|
|
68
|
+
"@tanstack/react-router": "^1.161.3",
|
|
60
69
|
"@tanstack/react-form": "^1.28.3",
|
|
61
70
|
"@uiw/react-codemirror": "^4.25.4",
|
|
71
|
+
"@uiw/codemirror-theme-vscode": "^4.25.4",
|
|
62
72
|
"@codemirror/lang-json": "^6.0.2",
|
|
63
|
-
"@codemirror/lint": "^6.9.4"
|
|
73
|
+
"@codemirror/lint": "^6.9.4",
|
|
74
|
+
"@codemirror/commands": "^6.10.2",
|
|
75
|
+
"@codemirror/view": "^6.39.14",
|
|
76
|
+
"react": "^19.2.4",
|
|
77
|
+
"react-dom": "^19.2.4",
|
|
78
|
+
"@tabler/icons-react": "^3.37.1",
|
|
79
|
+
"omgopass": "^3.2.1"
|
|
64
80
|
}
|
|
65
81
|
}
|