@humandialog/forms.svelte 1.3.11 → 1.3.12
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/README.md +0 -0
- package/components/Fab.svelte +103 -31
- package/components/Fab.svelte.d.ts +17 -17
- package/components/Floating_container.svelte.d.ts +21 -21
- package/components/Grid.menu.svelte.d.ts +25 -25
- package/components/button.svelte.d.ts +26 -26
- package/components/checkbox.svelte.d.ts +26 -26
- package/components/combo/combo.d.ts +19 -19
- package/components/combo/combo.item.svelte.d.ts +20 -20
- package/components/combo/combo.js +19 -19
- package/components/combo/combo.source.svelte.d.ts +23 -23
- package/components/combo/combo.svelte +25 -22
- package/components/combo/combo.svelte.d.ts +44 -44
- package/components/contextmenu.svelte.d.ts +26 -26
- package/components/date.svelte +40 -30
- package/components/date.svelte.d.ts +33 -33
- package/components/delayed.spinner.svelte.d.ts +19 -19
- package/components/document/editor.svelte +10 -4
- package/components/document/editor.svelte.d.ts +35 -35
- package/components/document/internal/Document_command.d.ts +12 -11
- package/components/document/internal/Document_command.js +12 -11
- package/components/document/internal/Selection_helper.d.ts +7 -7
- package/components/document/internal/Selection_helper.js +133 -133
- package/components/document/internal/Selection_range.d.ts +26 -26
- package/components/document/internal/Selection_range.js +58 -58
- package/components/document/internal/findSuggestionMatch.d.ts +16 -16
- package/components/document/internal/findSuggestionMatch.js +51 -51
- package/components/document/internal/h1.icon.svelte.d.ts +23 -23
- package/components/document/internal/h2.icon.svelte.d.ts +23 -23
- package/components/document/internal/h3.icon.svelte.d.ts +23 -23
- package/components/document/internal/h4.icon.svelte.d.ts +23 -23
- package/components/document/internal/palette.row.big.svelte.d.ts +46 -46
- package/components/document/internal/palette.row.svelte.d.ts +46 -46
- package/components/document/internal/palette.svelte +16 -10
- package/components/document/internal/palette.svelte.d.ts +82 -82
- package/components/document/internal/suggestion.d.ts +158 -158
- package/components/document/internal/suggestion.js +194 -194
- package/components/document/rich.edit.svelte.d.ts +34 -34
- package/components/edit.field.svelte.d.ts +31 -31
- package/components/file.loader.svelte.d.ts +25 -25
- package/components/icon.ex.svelte.d.ts +62 -62
- package/components/icon.svelte.d.ts +62 -62
- package/components/input.text.svelte.d.ts +29 -29
- package/components/inputbox.ltop.svelte.d.ts +59 -59
- package/components/kanban/Kanban.d.ts +47 -47
- package/components/kanban/Kanban.js +105 -105
- package/components/kanban/internal/kanban.card.svelte +5 -3
- package/components/kanban/internal/kanban.card.svelte.d.ts +32 -32
- package/components/kanban/internal/kanban.column.svelte.d.ts +53 -53
- package/components/kanban/internal/kanban.inserter.svelte.d.ts +18 -18
- package/components/kanban/internal/kanban.move.menu.svelte +135 -135
- package/components/kanban/internal/kanban.move.menu.svelte.d.ts +22 -22
- package/components/kanban/internal/kanban.props.svelte.d.ts +19 -19
- package/components/kanban/kanban.callbacks.svelte +1 -1
- package/components/kanban/kanban.callbacks.svelte.d.ts +18 -18
- package/components/kanban/kanban.column.svelte.d.ts +21 -21
- package/components/kanban/kanban.combo.svelte.d.ts +25 -25
- package/components/kanban/kanban.date.svelte +1 -1
- package/components/kanban/kanban.date.svelte.d.ts +21 -21
- package/components/kanban/kanban.source.svelte.d.ts +23 -23
- package/components/kanban/kanban.static.svelte.d.ts +20 -20
- package/components/kanban/kanban.summary.svelte.d.ts +18 -18
- package/components/kanban/kanban.svelte.d.ts +65 -65
- package/components/kanban/kanban.tags.svelte.d.ts +24 -24
- package/components/kanban/kanban.title.svelte.d.ts +21 -21
- package/components/list/List.d.ts +46 -46
- package/components/list/List.js +54 -54
- package/components/list/internal/list.element.props.svelte +2 -2
- package/components/list/internal/list.element.props.svelte.d.ts +21 -21
- package/components/list/internal/list.element.summary.svelte +46 -46
- package/components/list/internal/list.element.summary.svelte.d.ts +24 -24
- package/components/list/internal/list.element.svelte +8 -6
- package/components/list/internal/list.element.svelte.d.ts +31 -31
- package/components/list/internal/list.inserter.svelte.d.ts +19 -19
- package/components/list/list.combo.svelte.d.ts +22 -22
- package/components/list/list.date.svelte.d.ts +18 -18
- package/components/list/list.inserter.svelte.d.ts +17 -17
- package/components/list/list.static.svelte.d.ts +17 -17
- package/components/list/list.summary.svelte.d.ts +19 -19
- package/components/list/list.svelte.d.ts +59 -59
- package/components/list/list.title.svelte.d.ts +22 -22
- package/components/menu.d.ts +5 -5
- package/components/menu.js +57 -57
- package/components/radio.svelte.d.ts +26 -26
- package/components/sidebar/sidebar.brand.svelte.d.ts +33 -33
- package/components/sidebar/sidebar.group.svelte +2 -2
- package/components/sidebar/sidebar.group.svelte.d.ts +33 -33
- package/components/sidebar/sidebar.item.svelte +52 -29
- package/components/sidebar/sidebar.item.svelte.d.ts +32 -32
- package/components/sidebar/sidebar.list.svelte +4 -2
- package/components/sidebar/sidebar.list.svelte.d.ts +38 -38
- package/components/sidebar/sidebar.svelte.d.ts +27 -27
- package/components/simple.table.svelte.d.ts +41 -41
- package/components/table/_template.table.svelte.d.ts +57 -57
- package/components/table/column.svelte.d.ts +19 -19
- package/components/table/item.svelte.d.ts +17 -17
- package/components/table/table.d.ts +11 -11
- package/components/table/table.js +11 -11
- package/components/table/table.svelte +6 -3
- package/components/table/table.svelte.d.ts +75 -75
- package/components/tag.colors.svelte.d.ts +17 -17
- package/components/tag.svelte +12 -9
- package/components/tag.svelte.d.ts +20 -20
- package/components/tags.svelte +13 -11
- package/components/tags.svelte.d.ts +32 -32
- package/components/textarea.ltop.svelte.d.ts +35 -35
- package/components/tile.title.svelte.d.ts +29 -29
- package/console.svelte.d.ts +23 -23
- package/desk.svelte +58 -26
- package/desk.svelte.d.ts +23 -23
- package/form.box.svelte.d.ts +35 -35
- package/horizontal.toolbar.svelte +3 -3
- package/horizontal.toolbar.svelte.d.ts +25 -25
- package/index.d.ts +63 -63
- package/index.js +69 -69
- package/internal/configurable.content.svelte.d.ts +29 -29
- package/internal/loading.svelte.d.ts +23 -23
- package/modal.svelte.d.ts +39 -39
- package/operations.svelte +37 -8
- package/operations.svelte.d.ts +16 -16
- package/package.json +8 -8
- package/page.row.svelte.d.ts +31 -31
- package/page.svelte +7 -2
- package/page.svelte.d.ts +47 -47
- package/stores.d.ts +44 -44
- package/tenant.members.svelte +69 -39
- package/tenant.members.svelte.d.ts +33 -33
- package/tile.svelte.d.ts +33 -33
- package/tiles.row.svelte.d.ts +31 -31
- package/tiles.vertical.row.svelte.d.ts +29 -29
- package/updates.d.ts +4 -4
- package/utils.d.ts +50 -50
- package/utils.js +36 -7
- package/vertical.toolbar.svelte +1 -1
- package/vertical.toolbar.svelte.d.ts +27 -27
|
@@ -54,8 +54,8 @@ switch (s) {
|
|
|
54
54
|
label_mb = "mb-2";
|
|
55
55
|
input_pt = "pt-2.5";
|
|
56
56
|
input_pb = "pb-2.5";
|
|
57
|
-
font_size = "text-
|
|
58
|
-
line_h = "h-
|
|
57
|
+
font_size = "text-base";
|
|
58
|
+
line_h = "h-5 sm:h-5";
|
|
59
59
|
chevron_mt = "mt-2 sm:mt-1";
|
|
60
60
|
break;
|
|
61
61
|
case "xs":
|
|
@@ -75,11 +75,11 @@ switch (s) {
|
|
|
75
75
|
chevron_mt = "";
|
|
76
76
|
break;
|
|
77
77
|
default:
|
|
78
|
-
label_mb = "
|
|
79
|
-
input_pt = "
|
|
80
|
-
input_pb = "
|
|
81
|
-
font_size = "
|
|
82
|
-
line_h = "
|
|
78
|
+
label_mb = "";
|
|
79
|
+
input_pt = "";
|
|
80
|
+
input_pb = "";
|
|
81
|
+
font_size = "";
|
|
82
|
+
line_h = "";
|
|
83
83
|
chevron_mt = "";
|
|
84
84
|
}
|
|
85
85
|
let background_class = is_compact && !icon ? "" : "";
|
|
@@ -153,7 +153,7 @@ let on_hide_callback = void 0;
|
|
|
153
153
|
export function show(event, hide_callback) {
|
|
154
154
|
if (!can_be_activated)
|
|
155
155
|
return;
|
|
156
|
-
if (!
|
|
156
|
+
if (!textbox)
|
|
157
157
|
return;
|
|
158
158
|
if (is_dropdown_open)
|
|
159
159
|
return;
|
|
@@ -171,7 +171,7 @@ export function show(event, hide_callback) {
|
|
|
171
171
|
client_rect.y = 0;
|
|
172
172
|
client_rect.width = window.innerWidth;
|
|
173
173
|
client_rect.height = window.innerHeight;
|
|
174
|
-
let rect =
|
|
174
|
+
let rect = textbox.getBoundingClientRect();
|
|
175
175
|
let top_space = rect.y;
|
|
176
176
|
let bottom_space = client_rect.height - (rect.y + rect.height);
|
|
177
177
|
let palette_max_height_px = 500;
|
|
@@ -579,13 +579,14 @@ function on_focus_out(e) {
|
|
|
579
579
|
{/if}
|
|
580
580
|
<!-- svelte-ignore a11y-click-events-have-key-events -->
|
|
581
581
|
<div bind:this={combo}
|
|
582
|
-
on:click={(e) => { show(e, undefined) }}
|
|
583
|
-
class:cursor-pointer={can_be_activated && is_compact}
|
|
584
582
|
class="max-w-full {appearance_class} flex flex-row content-between items-center"
|
|
585
583
|
>
|
|
586
584
|
|
|
587
|
-
<
|
|
588
|
-
{
|
|
585
|
+
<p class="max-w-full flex-1 flex flex-row items-center"
|
|
586
|
+
on:click={(e) => { show(e, undefined) }}
|
|
587
|
+
class:cursor-pointer={can_be_activated && is_compact}>
|
|
588
|
+
|
|
589
|
+
{#if true || !is_dropdown_open}
|
|
589
590
|
{#if icon && sel_item}
|
|
590
591
|
{#if sel_item.Color}
|
|
591
592
|
<Icon size={5} circle={true} color={sel_item.Color}/>
|
|
@@ -600,7 +601,7 @@ function on_focus_out(e) {
|
|
|
600
601
|
{/if}
|
|
601
602
|
|
|
602
603
|
|
|
603
|
-
<
|
|
604
|
+
<span bind:this={textbox}
|
|
604
605
|
class="dark:text-stone-300 {line_h} truncate pl-0 pr-2.5 {background_class} min-w-[2.5rem]"
|
|
605
606
|
class:ml-2={icon}
|
|
606
607
|
class:text-stone-400={ (!is_dropdown_open) && (!sel_item)}
|
|
@@ -609,18 +610,20 @@ function on_focus_out(e) {
|
|
|
609
610
|
contenteditable={is_dropdown_open && filtered}
|
|
610
611
|
on:keydown={on_keydown}
|
|
611
612
|
tabindex="0">
|
|
612
|
-
{combo_text}</
|
|
613
|
-
|
|
613
|
+
{combo_text}</span>
|
|
614
|
+
|
|
615
|
+
{#if can_be_activated }
|
|
616
|
+
<div class="w-3 h-3 no-print flex-none text-stone-700 dark:text-stone-300 {chevron_mt}">
|
|
617
|
+
<FaChevronDown/>
|
|
618
|
+
</div>
|
|
619
|
+
{/if}
|
|
620
|
+
</p>
|
|
621
|
+
|
|
614
622
|
|
|
615
|
-
{#if can_be_activated }
|
|
616
|
-
<div class="w-3 h-3 no-print flex-none text-stone-700 dark:text-stone-300 {chevron_mt}">
|
|
617
|
-
<FaChevronDown/>
|
|
618
|
-
</div>
|
|
619
|
-
{/if}
|
|
620
623
|
</div>
|
|
621
624
|
|
|
622
625
|
<div hidden={!is_dropdown_open}
|
|
623
|
-
class="{cs} bg-white dark:bg-stone-800 text-stone-500 dark:text-stone-400 rounded-lg border border-stone-200 dark:border-stone-700 shadow-md overflow-y-auto cursor-pointer z-30"
|
|
626
|
+
class="not-prose {cs} bg-white dark:bg-stone-800 text-stone-500 dark:text-stone-400 rounded-lg border border-stone-200 dark:border-stone-700 shadow-md overflow-y-auto cursor-pointer z-30"
|
|
624
627
|
style={dropdown_position}
|
|
625
628
|
use:dropdown_action>
|
|
626
629
|
<ul class="py-1">
|
|
@@ -1,44 +1,44 @@
|
|
|
1
|
-
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
import { rCombo_definition } from './combo';
|
|
3
|
-
declare const __propDef: {
|
|
4
|
-
props: {
|
|
5
|
-
[x: string]: any;
|
|
6
|
-
label?: string | undefined;
|
|
7
|
-
self?: null | undefined;
|
|
8
|
-
a?: string | undefined;
|
|
9
|
-
isAssociation?: boolean | undefined;
|
|
10
|
-
context?: string | undefined;
|
|
11
|
-
typename?: string | undefined;
|
|
12
|
-
choiceCallback?: string | undefined;
|
|
13
|
-
onSelect?: undefined;
|
|
14
|
-
definition?: rCombo_definition | null | undefined;
|
|
15
|
-
changed?: undefined;
|
|
16
|
-
onNewItemCreated?: undefined;
|
|
17
|
-
icon?: boolean | undefined;
|
|
18
|
-
placeholder?: string | undefined;
|
|
19
|
-
s?: string | undefined;
|
|
20
|
-
c?: string | undefined;
|
|
21
|
-
compact?: boolean | undefined;
|
|
22
|
-
inContext?: string | undefined;
|
|
23
|
-
cached?: boolean | undefined;
|
|
24
|
-
filtered?: boolean | undefined;
|
|
25
|
-
pushChangesImmediately?: boolean | undefined;
|
|
26
|
-
hasNone?: boolean | undefined;
|
|
27
|
-
show?: ((event: any, hide_callback: any) => void) | undefined;
|
|
28
|
-
hide?: (() => void) | undefined;
|
|
29
|
-
};
|
|
30
|
-
events: {
|
|
31
|
-
[evt: string]: CustomEvent<any>;
|
|
32
|
-
};
|
|
33
|
-
slots: {
|
|
34
|
-
default: {};
|
|
35
|
-
};
|
|
36
|
-
};
|
|
37
|
-
export type ComboProps = typeof __propDef.props;
|
|
38
|
-
export type ComboEvents = typeof __propDef.events;
|
|
39
|
-
export type ComboSlots = typeof __propDef.slots;
|
|
40
|
-
export default class Combo extends SvelteComponentTyped<ComboProps, ComboEvents, ComboSlots> {
|
|
41
|
-
get show(): (event: any, hide_callback: any) => void;
|
|
42
|
-
get hide(): () => void;
|
|
43
|
-
}
|
|
44
|
-
export {};
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
import { rCombo_definition } from './combo';
|
|
3
|
+
declare const __propDef: {
|
|
4
|
+
props: {
|
|
5
|
+
[x: string]: any;
|
|
6
|
+
label?: string | undefined;
|
|
7
|
+
self?: null | undefined;
|
|
8
|
+
a?: string | undefined;
|
|
9
|
+
isAssociation?: boolean | undefined;
|
|
10
|
+
context?: string | undefined;
|
|
11
|
+
typename?: string | undefined;
|
|
12
|
+
choiceCallback?: string | undefined;
|
|
13
|
+
onSelect?: undefined;
|
|
14
|
+
definition?: rCombo_definition | null | undefined;
|
|
15
|
+
changed?: undefined;
|
|
16
|
+
onNewItemCreated?: undefined;
|
|
17
|
+
icon?: boolean | undefined;
|
|
18
|
+
placeholder?: string | undefined;
|
|
19
|
+
s?: string | undefined;
|
|
20
|
+
c?: string | undefined;
|
|
21
|
+
compact?: boolean | undefined;
|
|
22
|
+
inContext?: string | undefined;
|
|
23
|
+
cached?: boolean | undefined;
|
|
24
|
+
filtered?: boolean | undefined;
|
|
25
|
+
pushChangesImmediately?: boolean | undefined;
|
|
26
|
+
hasNone?: boolean | undefined;
|
|
27
|
+
show?: ((event: any, hide_callback: any) => void) | undefined;
|
|
28
|
+
hide?: (() => void) | undefined;
|
|
29
|
+
};
|
|
30
|
+
events: {
|
|
31
|
+
[evt: string]: CustomEvent<any>;
|
|
32
|
+
};
|
|
33
|
+
slots: {
|
|
34
|
+
default: {};
|
|
35
|
+
};
|
|
36
|
+
};
|
|
37
|
+
export type ComboProps = typeof __propDef.props;
|
|
38
|
+
export type ComboEvents = typeof __propDef.events;
|
|
39
|
+
export type ComboSlots = typeof __propDef.slots;
|
|
40
|
+
export default class Combo extends SvelteComponentTyped<ComboProps, ComboEvents, ComboSlots> {
|
|
41
|
+
get show(): (event: any, hide_callback: any) => void;
|
|
42
|
+
get hide(): () => void;
|
|
43
|
+
}
|
|
44
|
+
export {};
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
declare const __propDef: {
|
|
3
|
-
props: {
|
|
4
|
-
widthPx?: number | undefined;
|
|
5
|
-
menu_items_id_prefix?: string | undefined;
|
|
6
|
-
owner_menu_item?: HTMLElement | undefined;
|
|
7
|
-
show?: ((around: DOMRect | DOMPoint, _operations: any) => Promise<void>) | undefined;
|
|
8
|
-
isVisible?: (() => boolean) | undefined;
|
|
9
|
-
hide?: (() => void) | undefined;
|
|
10
|
-
getRenderedRect?: (() => DOMRect | undefined) | undefined;
|
|
11
|
-
};
|
|
12
|
-
events: {
|
|
13
|
-
[evt: string]: CustomEvent<any>;
|
|
14
|
-
};
|
|
15
|
-
slots: {};
|
|
16
|
-
};
|
|
17
|
-
export type ContextmenuProps = typeof __propDef.props;
|
|
18
|
-
export type ContextmenuEvents = typeof __propDef.events;
|
|
19
|
-
export type ContextmenuSlots = typeof __propDef.slots;
|
|
20
|
-
export default class Contextmenu extends SvelteComponentTyped<ContextmenuProps, ContextmenuEvents, ContextmenuSlots> {
|
|
21
|
-
get show(): (around: DOMRect | DOMPoint, _operations: any) => Promise<void>;
|
|
22
|
-
get isVisible(): () => boolean;
|
|
23
|
-
get hide(): () => void;
|
|
24
|
-
get getRenderedRect(): () => DOMRect | undefined;
|
|
25
|
-
}
|
|
26
|
-
export {};
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {
|
|
4
|
+
widthPx?: number | undefined;
|
|
5
|
+
menu_items_id_prefix?: string | undefined;
|
|
6
|
+
owner_menu_item?: HTMLElement | undefined;
|
|
7
|
+
show?: ((around: DOMRect | DOMPoint, _operations: any) => Promise<void>) | undefined;
|
|
8
|
+
isVisible?: (() => boolean) | undefined;
|
|
9
|
+
hide?: (() => void) | undefined;
|
|
10
|
+
getRenderedRect?: (() => DOMRect | undefined) | undefined;
|
|
11
|
+
};
|
|
12
|
+
events: {
|
|
13
|
+
[evt: string]: CustomEvent<any>;
|
|
14
|
+
};
|
|
15
|
+
slots: {};
|
|
16
|
+
};
|
|
17
|
+
export type ContextmenuProps = typeof __propDef.props;
|
|
18
|
+
export type ContextmenuEvents = typeof __propDef.events;
|
|
19
|
+
export type ContextmenuSlots = typeof __propDef.slots;
|
|
20
|
+
export default class Contextmenu extends SvelteComponentTyped<ContextmenuProps, ContextmenuEvents, ContextmenuSlots> {
|
|
21
|
+
get show(): (around: DOMRect | DOMPoint, _operations: any) => Promise<void>;
|
|
22
|
+
get isVisible(): () => boolean;
|
|
23
|
+
get hide(): () => void;
|
|
24
|
+
get getRenderedRect(): () => DOMRect | undefined;
|
|
25
|
+
}
|
|
26
|
+
export {};
|
package/components/date.svelte
CHANGED
|
@@ -73,6 +73,12 @@ switch (s) {
|
|
|
73
73
|
line_h = "h-6 sm:h-6";
|
|
74
74
|
chevron_mt = "mt-1.5 sm:mt-0.5";
|
|
75
75
|
break;
|
|
76
|
+
default:
|
|
77
|
+
input_pt = "";
|
|
78
|
+
input_pb = "";
|
|
79
|
+
font_size = "";
|
|
80
|
+
line_h = "";
|
|
81
|
+
chevron_mt = "";
|
|
76
82
|
}
|
|
77
83
|
let item = null;
|
|
78
84
|
let user_class = $$restProps.class ?? "";
|
|
@@ -291,40 +297,44 @@ function blur(e) {
|
|
|
291
297
|
</script>
|
|
292
298
|
|
|
293
299
|
{#if is_compact}
|
|
294
|
-
<div class="inline-block
|
|
300
|
+
<div class="inline-block {line_h}">
|
|
295
301
|
<div class="dark:text-stone-300 {font_size} truncate
|
|
296
302
|
pl-0 pr-0
|
|
297
|
-
h-full
|
|
298
|
-
<
|
|
299
|
-
|
|
300
|
-
|
|
303
|
+
h-full " >
|
|
304
|
+
<p >
|
|
305
|
+
<span class="inline-block relative flex flex-row items-center">
|
|
306
|
+
<span class="grow-1 pr-2.5 ">
|
|
307
|
+
{pretty_value}
|
|
308
|
+
</span>
|
|
301
309
|
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
310
|
+
{#if can_be_activated}
|
|
311
|
+
<div class="no-print ml-auto w-3 h-3 {chevron_mt} text-stone-700 dark:text-stone-300">
|
|
312
|
+
<FaChevronDown/>
|
|
313
|
+
</div>
|
|
314
|
+
{/if}
|
|
315
|
+
|
|
316
|
+
{#if can_be_activated}
|
|
317
|
+
{#if type == "datetime-local"}
|
|
318
|
+
<input type="datetime-local"
|
|
319
|
+
class="datepicker-input"
|
|
320
|
+
tabindex="-1"
|
|
321
|
+
on:change={on_changed}
|
|
322
|
+
bind:value={rValue}
|
|
323
|
+
bind:this={input_element}>
|
|
324
|
+
{:else}
|
|
325
|
+
<input type="date"
|
|
326
|
+
class="datepicker-input"
|
|
327
|
+
tabindex="-1"
|
|
328
|
+
on:change={on_changed}
|
|
329
|
+
bind:value={rValue}
|
|
330
|
+
bind:this={input_element}
|
|
331
|
+
on:blur={blur}>
|
|
332
|
+
{/if}
|
|
333
|
+
{/if}
|
|
334
|
+
|
|
335
|
+
</span>
|
|
336
|
+
</p>
|
|
325
337
|
|
|
326
|
-
|
|
327
|
-
{/if}
|
|
328
338
|
</div>
|
|
329
339
|
|
|
330
340
|
|
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
declare const __propDef: {
|
|
3
|
-
props: {
|
|
4
|
-
[x: string]: any;
|
|
5
|
-
self?: null | undefined;
|
|
6
|
-
a?: string | undefined;
|
|
7
|
-
context?: string | undefined;
|
|
8
|
-
typename?: string | undefined;
|
|
9
|
-
date?: Date | undefined;
|
|
10
|
-
onSelect?: undefined;
|
|
11
|
-
type?: string | undefined;
|
|
12
|
-
changed?: undefined;
|
|
13
|
-
s?: string | undefined;
|
|
14
|
-
c?: string | undefined;
|
|
15
|
-
compact?: boolean | undefined;
|
|
16
|
-
inContext?: string | undefined;
|
|
17
|
-
pushChangesImmediately?: boolean | undefined;
|
|
18
|
-
show?: ((event: any, hide_callback: any) => void) | undefined;
|
|
19
|
-
refresh?: (() => void) | undefined;
|
|
20
|
-
};
|
|
21
|
-
events: {
|
|
22
|
-
[evt: string]: CustomEvent<any>;
|
|
23
|
-
};
|
|
24
|
-
slots: {};
|
|
25
|
-
};
|
|
26
|
-
export type DateProps = typeof __propDef.props;
|
|
27
|
-
export type DateEvents = typeof __propDef.events;
|
|
28
|
-
export type DateSlots = typeof __propDef.slots;
|
|
29
|
-
export default class Date extends SvelteComponentTyped<DateProps, DateEvents, DateSlots> {
|
|
30
|
-
get show(): (event: any, hide_callback: any) => void;
|
|
31
|
-
get refresh(): () => void;
|
|
32
|
-
}
|
|
33
|
-
export {};
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {
|
|
4
|
+
[x: string]: any;
|
|
5
|
+
self?: null | undefined;
|
|
6
|
+
a?: string | undefined;
|
|
7
|
+
context?: string | undefined;
|
|
8
|
+
typename?: string | undefined;
|
|
9
|
+
date?: Date | undefined;
|
|
10
|
+
onSelect?: undefined;
|
|
11
|
+
type?: string | undefined;
|
|
12
|
+
changed?: undefined;
|
|
13
|
+
s?: string | undefined;
|
|
14
|
+
c?: string | undefined;
|
|
15
|
+
compact?: boolean | undefined;
|
|
16
|
+
inContext?: string | undefined;
|
|
17
|
+
pushChangesImmediately?: boolean | undefined;
|
|
18
|
+
show?: ((event: any, hide_callback: any) => void) | undefined;
|
|
19
|
+
refresh?: (() => void) | undefined;
|
|
20
|
+
};
|
|
21
|
+
events: {
|
|
22
|
+
[evt: string]: CustomEvent<any>;
|
|
23
|
+
};
|
|
24
|
+
slots: {};
|
|
25
|
+
};
|
|
26
|
+
export type DateProps = typeof __propDef.props;
|
|
27
|
+
export type DateEvents = typeof __propDef.events;
|
|
28
|
+
export type DateSlots = typeof __propDef.slots;
|
|
29
|
+
export default class Date extends SvelteComponentTyped<DateProps, DateEvents, DateSlots> {
|
|
30
|
+
get show(): (event: any, hide_callback: any) => void;
|
|
31
|
+
get refresh(): () => void;
|
|
32
|
+
}
|
|
33
|
+
export {};
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
declare const __propDef: {
|
|
3
|
-
props: {
|
|
4
|
-
[x: string]: any;
|
|
5
|
-
color?: string | undefined;
|
|
6
|
-
size?: number | undefined;
|
|
7
|
-
delay?: number | undefined;
|
|
8
|
-
};
|
|
9
|
-
events: {
|
|
10
|
-
[evt: string]: CustomEvent<any>;
|
|
11
|
-
};
|
|
12
|
-
slots: {};
|
|
13
|
-
};
|
|
14
|
-
export type DelayedProps = typeof __propDef.props;
|
|
15
|
-
export type DelayedEvents = typeof __propDef.events;
|
|
16
|
-
export type DelayedSlots = typeof __propDef.slots;
|
|
17
|
-
export default class Delayed extends SvelteComponentTyped<DelayedProps, DelayedEvents, DelayedSlots> {
|
|
18
|
-
}
|
|
19
|
-
export {};
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {
|
|
4
|
+
[x: string]: any;
|
|
5
|
+
color?: string | undefined;
|
|
6
|
+
size?: number | undefined;
|
|
7
|
+
delay?: number | undefined;
|
|
8
|
+
};
|
|
9
|
+
events: {
|
|
10
|
+
[evt: string]: CustomEvent<any>;
|
|
11
|
+
};
|
|
12
|
+
slots: {};
|
|
13
|
+
};
|
|
14
|
+
export type DelayedProps = typeof __propDef.props;
|
|
15
|
+
export type DelayedEvents = typeof __propDef.events;
|
|
16
|
+
export type DelayedSlots = typeof __propDef.slots;
|
|
17
|
+
export default class Delayed extends SvelteComponentTyped<DelayedProps, DelayedEvents, DelayedSlots> {
|
|
18
|
+
}
|
|
19
|
+
export {};
|
|
@@ -186,6 +186,7 @@ const suggestion = {
|
|
|
186
186
|
editor.commands.blur();
|
|
187
187
|
palette.set_current_editor_range(props.range);
|
|
188
188
|
const cursorRect = props.clientRect();
|
|
189
|
+
palette.filter("");
|
|
189
190
|
setTimeout(() => show_command_palette(cursorRect), 100);
|
|
190
191
|
} else {
|
|
191
192
|
const cursorRect = props.clientRect();
|
|
@@ -585,10 +586,12 @@ function show_command_palette(cursor_rect) {
|
|
|
585
586
|
show_big_command_palette(cursor_rect, client_rect);
|
|
586
587
|
}
|
|
587
588
|
function show_small_command_palette(client_rect) {
|
|
588
|
-
|
|
589
|
-
palette.
|
|
590
|
-
|
|
591
|
-
let
|
|
589
|
+
const margin = 5;
|
|
590
|
+
palette.max_height_px = client_rect.height / 2 - margin;
|
|
591
|
+
palette.width_px = client_rect.width - 2 * margin;
|
|
592
|
+
let x = margin;
|
|
593
|
+
let y = client_rect.bottom - margin;
|
|
594
|
+
let show_above = true;
|
|
592
595
|
palette.show(x, y, show_above);
|
|
593
596
|
}
|
|
594
597
|
function show_big_command_palette(cursor_rect, client_rect) {
|
|
@@ -661,6 +664,9 @@ function handleImagesChanges(transaction) {
|
|
|
661
664
|
}
|
|
662
665
|
let commands = [
|
|
663
666
|
//{ caption: 'Styles', separator: true },
|
|
667
|
+
{ caption: "Back to edit", description: "Escape", icon: FaArrowLeft, on_choice: () => {
|
|
668
|
+
editor?.commands.focus();
|
|
669
|
+
}, is_visible: () => isDeviceSmallerThan("sm") },
|
|
664
670
|
{ caption: "Normal", description: "This is normal text style", tags: "text", icon: FaRemoveFormat, on_choice: (range) => {
|
|
665
671
|
if (range)
|
|
666
672
|
editor.chain().focus().deleteRange(range).setParagraph().run();
|
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
declare const __propDef: {
|
|
3
|
-
props: {
|
|
4
|
-
[x: string]: any;
|
|
5
|
-
value?: string | undefined;
|
|
6
|
-
placeholder?: string | undefined;
|
|
7
|
-
self?: null | undefined;
|
|
8
|
-
a?: string | undefined;
|
|
9
|
-
context?: string | undefined;
|
|
10
|
-
typename?: string | undefined;
|
|
11
|
-
compact?: boolean | undefined;
|
|
12
|
-
onFocusCb?: undefined;
|
|
13
|
-
onBlurCb?: undefined;
|
|
14
|
-
onAddImage?: undefined;
|
|
15
|
-
onRemoveImage?: undefined;
|
|
16
|
-
c?: string | undefined;
|
|
17
|
-
pushChangesImmediately?: boolean | undefined;
|
|
18
|
-
run?: ((onStop?: undefined) => void) | undefined;
|
|
19
|
-
getFormattingOperations?: ((withCaptions?: boolean) => any[]) | undefined;
|
|
20
|
-
save?: (() => void) | undefined;
|
|
21
|
-
};
|
|
22
|
-
events: {
|
|
23
|
-
[evt: string]: CustomEvent<any>;
|
|
24
|
-
};
|
|
25
|
-
slots: {};
|
|
26
|
-
};
|
|
27
|
-
export type EditorProps = typeof __propDef.props;
|
|
28
|
-
export type EditorEvents = typeof __propDef.events;
|
|
29
|
-
export type EditorSlots = typeof __propDef.slots;
|
|
30
|
-
export default class Editor extends SvelteComponentTyped<EditorProps, EditorEvents, EditorSlots> {
|
|
31
|
-
get run(): (onStop?: undefined) => void;
|
|
32
|
-
get getFormattingOperations(): (withCaptions?: boolean) => any[];
|
|
33
|
-
get save(): () => void;
|
|
34
|
-
}
|
|
35
|
-
export {};
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {
|
|
4
|
+
[x: string]: any;
|
|
5
|
+
value?: string | undefined;
|
|
6
|
+
placeholder?: string | undefined;
|
|
7
|
+
self?: null | undefined;
|
|
8
|
+
a?: string | undefined;
|
|
9
|
+
context?: string | undefined;
|
|
10
|
+
typename?: string | undefined;
|
|
11
|
+
compact?: boolean | undefined;
|
|
12
|
+
onFocusCb?: undefined;
|
|
13
|
+
onBlurCb?: undefined;
|
|
14
|
+
onAddImage?: undefined;
|
|
15
|
+
onRemoveImage?: undefined;
|
|
16
|
+
c?: string | undefined;
|
|
17
|
+
pushChangesImmediately?: boolean | undefined;
|
|
18
|
+
run?: ((onStop?: undefined) => void) | undefined;
|
|
19
|
+
getFormattingOperations?: ((withCaptions?: boolean) => any[]) | undefined;
|
|
20
|
+
save?: (() => void) | undefined;
|
|
21
|
+
};
|
|
22
|
+
events: {
|
|
23
|
+
[evt: string]: CustomEvent<any>;
|
|
24
|
+
};
|
|
25
|
+
slots: {};
|
|
26
|
+
};
|
|
27
|
+
export type EditorProps = typeof __propDef.props;
|
|
28
|
+
export type EditorEvents = typeof __propDef.events;
|
|
29
|
+
export type EditorSlots = typeof __propDef.slots;
|
|
30
|
+
export default class Editor extends SvelteComponentTyped<EditorProps, EditorEvents, EditorSlots> {
|
|
31
|
+
get run(): (onStop?: undefined) => void;
|
|
32
|
+
get getFormattingOperations(): (withCaptions?: boolean) => any[];
|
|
33
|
+
get save(): () => void;
|
|
34
|
+
}
|
|
35
|
+
export {};
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
export declare class Document_command {
|
|
2
|
-
caption: string;
|
|
3
|
-
description: string;
|
|
4
|
-
tags?: string;
|
|
5
|
-
shortcut?: string;
|
|
6
|
-
icon: any;
|
|
7
|
-
icon_size?: number;
|
|
8
|
-
on_choice: any;
|
|
9
|
-
is_active: any;
|
|
10
|
-
|
|
11
|
-
|
|
1
|
+
export declare class Document_command {
|
|
2
|
+
caption: string;
|
|
3
|
+
description: string;
|
|
4
|
+
tags?: string;
|
|
5
|
+
shortcut?: string;
|
|
6
|
+
icon: any;
|
|
7
|
+
icon_size?: number;
|
|
8
|
+
on_choice: any;
|
|
9
|
+
is_active: any;
|
|
10
|
+
is_visible: any;
|
|
11
|
+
separator?: boolean;
|
|
12
|
+
}
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
export class Document_command {
|
|
2
|
-
caption;
|
|
3
|
-
description;
|
|
4
|
-
tags;
|
|
5
|
-
shortcut;
|
|
6
|
-
icon;
|
|
7
|
-
icon_size = 6;
|
|
8
|
-
on_choice;
|
|
9
|
-
is_active;
|
|
10
|
-
|
|
11
|
-
|
|
1
|
+
export class Document_command {
|
|
2
|
+
caption;
|
|
3
|
+
description;
|
|
4
|
+
tags;
|
|
5
|
+
shortcut;
|
|
6
|
+
icon;
|
|
7
|
+
icon_size = 6;
|
|
8
|
+
on_choice;
|
|
9
|
+
is_active;
|
|
10
|
+
is_visible;
|
|
11
|
+
separator = false;
|
|
12
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Selection_range } from "./Selection_range";
|
|
2
|
-
export declare class Selection_helper {
|
|
3
|
-
private static nodewalk;
|
|
4
|
-
static create_cursor_range(elem: HTMLElement, nrOfChars: number): [Range, Node];
|
|
5
|
-
static create_range(elem: HTMLElement, start: number, end: number): Range;
|
|
6
|
-
static get_selection(elem: HTMLElement): Selection_range;
|
|
7
|
-
}
|
|
1
|
+
import { Selection_range } from "./Selection_range";
|
|
2
|
+
export declare class Selection_helper {
|
|
3
|
+
private static nodewalk;
|
|
4
|
+
static create_cursor_range(elem: HTMLElement, nrOfChars: number): [Range, Node];
|
|
5
|
+
static create_range(elem: HTMLElement, start: number, end: number): Range;
|
|
6
|
+
static get_selection(elem: HTMLElement): Selection_range;
|
|
7
|
+
}
|