@omnitend/dashboard-for-laravel 0.19.2 → 0.21.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/dist/components/extended/DXDashboard.vue.d.ts +8 -2
- package/dist/components/extended/DXFieldLabel.vue.d.ts +11 -1
- package/dist/components/extended/DXFormField.vue.d.ts +41 -0
- package/dist/components/extended/DXSwitch.vue.d.ts +30 -0
- package/dist/components/extended/dxFieldContext.d.ts +11 -0
- package/dist/dashboard-for-laravel.js +10930 -10862
- package/dist/dashboard-for-laravel.js.map +1 -1
- package/dist/dashboard-for-laravel.umd.cjs +8 -8
- package/dist/dashboard-for-laravel.umd.cjs.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/style.css +1 -1
- package/dist/types/index.d.ts +4 -1
- package/dist/utils/api.d.ts +1 -1
- package/docs/public/api-reference.json +211 -93
- package/docs/public/docs-map.md +3 -2
- package/docs/public/llms.txt +3 -2
- package/package.json +6 -5
- package/resources/css/theme.scss +5 -1
- package/resources/js/components/extended/DXDashboard.vue +13 -3
- package/resources/js/components/extended/DXField.vue +66 -77
- package/resources/js/components/extended/DXFieldLabel.vue +18 -3
- package/resources/js/components/extended/DXForm.vue +31 -109
- package/resources/js/components/extended/DXFormField.vue +98 -0
- package/resources/js/components/extended/DXSwitch.vue +153 -0
- package/resources/js/components/extended/dxFieldContext.ts +14 -0
- package/resources/js/composables/useForm.ts +10 -3
- package/resources/js/index.ts +1 -0
- package/resources/js/types/index.ts +4 -1
- package/resources/js/utils/api.ts +19 -2
|
@@ -10,10 +10,15 @@ interface Props {
|
|
|
10
10
|
pageTitle?: string;
|
|
11
11
|
/**
|
|
12
12
|
* Render the page content full-width and left-aligned instead of the default
|
|
13
|
-
* centred, reading-width
|
|
14
|
-
* (wide tables).
|
|
13
|
+
* centred, reading-width column. Use for data-heavy admin pages (wide tables).
|
|
15
14
|
*/
|
|
16
15
|
fluid?: boolean;
|
|
16
|
+
/**
|
|
17
|
+
* Max width of the centred content column (any CSS length). A genuine cap, so
|
|
18
|
+
* forms and text-heavy pages don't stretch to ~2000px on a wide display.
|
|
19
|
+
* Ignored when `fluid`. Set a large value (or use `fluid`) for full width.
|
|
20
|
+
*/
|
|
21
|
+
contentMaxWidth?: string;
|
|
17
22
|
/** Extra class(es) applied to the content container/column. */
|
|
18
23
|
contentClass?: string;
|
|
19
24
|
/** User object for navbar dropdown */
|
|
@@ -62,6 +67,7 @@ declare const __VLS_component: import("vue").DefineComponent<Props, {}, {}, {},
|
|
|
62
67
|
email: string;
|
|
63
68
|
} | null;
|
|
64
69
|
pageTitle: string;
|
|
70
|
+
contentMaxWidth: string;
|
|
65
71
|
logoutUrl: string;
|
|
66
72
|
storageKey: string;
|
|
67
73
|
dashboardId: string;
|
|
@@ -4,5 +4,15 @@ interface Props {
|
|
|
4
4
|
/** Optional help text revealed in a popover from an info affordance. */
|
|
5
5
|
info?: string;
|
|
6
6
|
}
|
|
7
|
-
declare
|
|
7
|
+
declare var __VLS_8: {};
|
|
8
|
+
type __VLS_Slots = {} & {
|
|
9
|
+
popover?: (props: typeof __VLS_8) => any;
|
|
10
|
+
};
|
|
11
|
+
declare const __VLS_component: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
12
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
8
13
|
export default _default;
|
|
14
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
15
|
+
new (): {
|
|
16
|
+
$slots: S;
|
|
17
|
+
};
|
|
18
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import type { UseFormReturn } from "../../composables/useForm";
|
|
2
|
+
import type { FieldDefinition, LabelCols } from "../../types";
|
|
3
|
+
interface Props {
|
|
4
|
+
/** The field to render. */
|
|
5
|
+
field: FieldDefinition;
|
|
6
|
+
/** The resolved form instance (state, errors, submit helpers). */
|
|
7
|
+
form: UseFormReturn<any>;
|
|
8
|
+
/** Live form data merged with context, for slot bindings/predicates. */
|
|
9
|
+
model: Record<string, any>;
|
|
10
|
+
/** Form-level layout; overridden per-field by `field.layout`. */
|
|
11
|
+
layout?: "vertical" | "horizontal";
|
|
12
|
+
/** Form-level label column width; overridden per-field by `field.labelCols`. */
|
|
13
|
+
labelCols?: LabelCols;
|
|
14
|
+
}
|
|
15
|
+
declare var __VLS_2: `field(${string})`, __VLS_3: {
|
|
16
|
+
field: FieldDefinition;
|
|
17
|
+
model: Record<string, any>;
|
|
18
|
+
}, __VLS_6: `field-before(${string})`, __VLS_7: {
|
|
19
|
+
field: FieldDefinition;
|
|
20
|
+
model: Record<string, any>;
|
|
21
|
+
}, __VLS_13: string, __VLS_14: any, __VLS_17: `field-after(${string})`, __VLS_18: {
|
|
22
|
+
field: FieldDefinition;
|
|
23
|
+
model: Record<string, any>;
|
|
24
|
+
};
|
|
25
|
+
type __VLS_Slots = {} & {
|
|
26
|
+
[K in NonNullable<typeof __VLS_2>]?: (props: typeof __VLS_3) => any;
|
|
27
|
+
} & {
|
|
28
|
+
[K in NonNullable<typeof __VLS_6>]?: (props: typeof __VLS_7) => any;
|
|
29
|
+
} & {
|
|
30
|
+
[K in NonNullable<typeof __VLS_13>]?: (props: typeof __VLS_14) => any;
|
|
31
|
+
} & {
|
|
32
|
+
[K in NonNullable<typeof __VLS_17>]?: (props: typeof __VLS_18) => any;
|
|
33
|
+
};
|
|
34
|
+
declare const __VLS_component: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
35
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
36
|
+
export default _default;
|
|
37
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
38
|
+
new (): {
|
|
39
|
+
$slots: S;
|
|
40
|
+
};
|
|
41
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
interface Props {
|
|
2
|
+
/** Whether the switch is on. */
|
|
3
|
+
modelValue?: boolean;
|
|
4
|
+
/** Static text beside the toggle; the fallback when no contextual text applies. */
|
|
5
|
+
label?: string;
|
|
6
|
+
/** Text shown when on — overrides `label` in the on state (e.g. "Product is current"). */
|
|
7
|
+
textWhenTrue?: string;
|
|
8
|
+
/** Text shown when off — overrides `label` in the off state (e.g. "Product is not current"). */
|
|
9
|
+
textWhenFalse?: string;
|
|
10
|
+
}
|
|
11
|
+
declare var __VLS_4: {
|
|
12
|
+
on: boolean;
|
|
13
|
+
};
|
|
14
|
+
type __VLS_Slots = {} & {
|
|
15
|
+
default?: (props: typeof __VLS_4) => any;
|
|
16
|
+
};
|
|
17
|
+
declare const __VLS_component: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
18
|
+
"update:modelValue": (value: boolean) => any;
|
|
19
|
+
}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{
|
|
20
|
+
"onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
|
|
21
|
+
}>, {
|
|
22
|
+
modelValue: boolean;
|
|
23
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
24
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
25
|
+
export default _default;
|
|
26
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
27
|
+
new (): {
|
|
28
|
+
$slots: S;
|
|
29
|
+
};
|
|
30
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { ComputedRef, InjectionKey } from "vue";
|
|
2
|
+
/**
|
|
3
|
+
* Lets `DXField` forward its `info-popover` slot to the `DXFieldLabel` it
|
|
4
|
+
* renders — at any of its several label sites — without repeating the forward
|
|
5
|
+
* at each one. The provided value is a render function for the popover body, or
|
|
6
|
+
* `null` when the field has no `info-popover` slot.
|
|
7
|
+
*
|
|
8
|
+
* Optional: a `DXFieldLabel` used standalone (no `DXField` ancestor) injects the
|
|
9
|
+
* default `null` and falls back to its own `popover` slot / `info` text.
|
|
10
|
+
*/
|
|
11
|
+
export declare const dxFieldInfoPopoverKey: InjectionKey<ComputedRef<(() => unknown) | null>>;
|