@humandialog/forms.svelte 0.5.4 → 0.5.6
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 +5 -3
- package/components/Fab.svelte.d.ts +14 -14
- package/components/Floating_container.svelte.d.ts +21 -21
- package/components/Grid.menu.svelte.d.ts +25 -25
- package/components/button.svelte.d.ts +24 -24
- package/components/checkbox.svelte.d.ts +26 -26
- package/components/combo/combo.d.ts +17 -17
- package/components/combo/combo.item.svelte.d.ts +19 -19
- package/components/combo/combo.js +17 -17
- package/components/combo/combo.source.svelte.d.ts +22 -22
- package/components/combo/combo.svelte +1 -1
- package/components/combo/combo.svelte.d.ts +42 -42
- package/components/contextmenu.svelte.d.ts +26 -26
- package/components/date.svelte.d.ts +31 -31
- package/components/delayed.spinner.svelte.d.ts +19 -19
- package/components/document/internal/Document_command.d.ts +9 -9
- package/components/document/internal/Document_command.js +9 -9
- 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/palette.row.svelte.d.ts +36 -36
- package/components/document/internal/palette.svelte.d.ts +67 -67
- package/components/document/rich.edit.svelte +49 -8
- package/components/document/rich.edit.svelte.d.ts +32 -32
- package/components/edit.field.svelte.d.ts +28 -28
- package/components/file.loader.svelte.d.ts +25 -25
- package/components/icon.svelte.d.ts +62 -62
- package/components/input.text.svelte.d.ts +29 -29
- package/components/inputbox.ltop.svelte +1 -1
- package/components/inputbox.ltop.svelte.d.ts +52 -52
- package/components/kanban/Kanban.d.ts +43 -23
- package/components/kanban/Kanban.js +79 -23
- package/components/kanban/internal/kanban.card.svelte +195 -117
- package/components/kanban/internal/kanban.card.svelte.d.ts +32 -35
- package/components/kanban/internal/kanban.column.svelte +152 -108
- package/components/kanban/internal/kanban.column.svelte.d.ts +51 -51
- package/components/kanban/internal/kanban.inserter.svelte +14 -14
- package/components/kanban/internal/kanban.inserter.svelte.d.ts +18 -18
- package/components/kanban/internal/kanban.move.menu.svelte +138 -135
- package/components/kanban/internal/kanban.move.menu.svelte.d.ts +22 -19
- package/components/kanban/internal/kanban.props.svelte +140 -0
- package/components/kanban/internal/kanban.props.svelte.d.ts +19 -0
- package/components/kanban/kanban.callbacks.svelte +3 -9
- package/components/kanban/kanban.callbacks.svelte.d.ts +18 -21
- package/components/kanban/kanban.column.svelte +10 -10
- package/components/kanban/kanban.column.svelte.d.ts +21 -21
- package/components/kanban/kanban.combo.svelte +36 -0
- package/components/kanban/kanban.combo.svelte.d.ts +24 -0
- package/components/kanban/kanban.date.svelte +30 -0
- package/components/kanban/kanban.date.svelte.d.ts +21 -0
- package/components/kanban/kanban.source.svelte +25 -0
- package/components/kanban/kanban.source.svelte.d.ts +23 -0
- package/components/kanban/kanban.static.svelte +28 -0
- package/components/kanban/kanban.static.svelte.d.ts +20 -0
- package/components/kanban/kanban.summary.svelte +4 -0
- package/components/kanban/kanban.summary.svelte.d.ts +18 -16
- package/components/kanban/kanban.svelte +459 -124
- package/components/kanban/kanban.svelte.d.ts +63 -43
- package/components/kanban/kanban.tags.svelte +34 -0
- package/components/kanban/kanban.tags.svelte.d.ts +23 -0
- package/components/kanban/kanban.title.svelte +4 -2
- package/components/kanban/kanban.title.svelte.d.ts +18 -17
- package/components/list/List.d.ts +44 -36
- package/components/list/List.js +52 -42
- package/components/list/internal/list.element.props.svelte +65 -65
- package/components/list/internal/list.element.props.svelte.d.ts +21 -21
- package/components/list/internal/list.element.summary.svelte +44 -30
- package/components/list/internal/list.element.summary.svelte.d.ts +25 -24
- package/components/list/internal/list.element.svelte +24 -11
- package/components/list/internal/list.element.svelte.d.ts +29 -29
- package/components/list/internal/list.inserter.svelte.d.ts +19 -19
- package/components/list/list.combo.svelte.d.ts +21 -21
- 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 +2 -2
- package/components/list/list.svelte.d.ts +59 -59
- package/components/list/list.title.svelte +2 -0
- package/components/list/list.title.svelte.d.ts +22 -21
- package/components/menu.d.ts +4 -4
- package/components/menu.js +56 -56
- package/components/radio.svelte.d.ts +26 -26
- package/components/sidebar/sidebar.brand.svelte.d.ts +31 -31
- package/components/sidebar/sidebar.group.svelte +41 -3
- package/components/sidebar/sidebar.group.svelte.d.ts +33 -27
- package/components/sidebar/sidebar.item.svelte.d.ts +28 -28
- package/components/sidebar/sidebar.list.svelte +15 -15
- package/components/sidebar/sidebar.list.svelte.d.ts +33 -33
- 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.d.ts +75 -75
- package/components/tag.svelte +40 -0
- package/components/tag.svelte.d.ts +19 -0
- package/components/tags.svelte +207 -0
- package/components/tags.svelte.d.ts +31 -0
- package/components/textarea.ltop.svelte.d.ts +35 -35
- package/components/tile.title.svelte.d.ts +29 -29
- package/desk.svelte.d.ts +23 -23
- package/form.box.svelte.d.ts +35 -35
- package/horizontal.toolbar.svelte +23 -4
- package/horizontal.toolbar.svelte.d.ts +25 -23
- package/index.d.ts +59 -52
- package/index.js +65 -58
- package/internal/configurable.content.svelte.d.ts +27 -27
- package/internal/loading.svelte.d.ts +23 -23
- package/modal.svelte +7 -7
- package/modal.svelte.d.ts +35 -35
- package/operations.svelte +52 -23
- package/operations.svelte.d.ts +16 -16
- package/package.json +16 -8
- package/page.row.svelte.d.ts +31 -31
- package/page.svelte +3 -3
- package/page.svelte.d.ts +45 -45
- package/stores.d.ts +39 -39
- package/stores.js +0 -0
- package/tenant.members.svelte +10 -11
- 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 -3
- package/updates.js +16 -0
- package/utils.d.ts +35 -35
- package/utils.js +11 -1
- package/vertical.toolbar.svelte +31 -6
- package/vertical.toolbar.svelte.d.ts +27 -25
|
@@ -1,35 +1,32 @@
|
|
|
1
|
-
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
declare const __propDef: {
|
|
3
|
-
props: {
|
|
4
|
-
item: object;
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
element: object;
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
element: object;
|
|
21
|
-
};
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
export
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
get _scrollViewToCard(): () => void;
|
|
34
|
-
}
|
|
35
|
-
export {};
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {
|
|
4
|
+
item: object;
|
|
5
|
+
activate?: ((e: any) => void) | undefined;
|
|
6
|
+
_scrollViewToCard?: (() => void) | undefined;
|
|
7
|
+
editProperty?: ((field: string) => Promise<void>) | undefined;
|
|
8
|
+
};
|
|
9
|
+
events: {
|
|
10
|
+
[evt: string]: CustomEvent<any>;
|
|
11
|
+
};
|
|
12
|
+
slots: {
|
|
13
|
+
kanbanCardTopProps: {
|
|
14
|
+
element: object;
|
|
15
|
+
};
|
|
16
|
+
kanbanCardMiddleProps: {
|
|
17
|
+
element: object;
|
|
18
|
+
};
|
|
19
|
+
kanbanCardBottomProps: {
|
|
20
|
+
element: object;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
export type KanbanProps = typeof __propDef.props;
|
|
25
|
+
export type KanbanEvents = typeof __propDef.events;
|
|
26
|
+
export type KanbanSlots = typeof __propDef.slots;
|
|
27
|
+
export default class Kanban extends SvelteComponentTyped<KanbanProps, KanbanEvents, KanbanSlots> {
|
|
28
|
+
get activate(): (e: any) => void;
|
|
29
|
+
get _scrollViewToCard(): () => void;
|
|
30
|
+
get editProperty(): (field: string) => Promise<void>;
|
|
31
|
+
}
|
|
32
|
+
export {};
|
|
@@ -1,24 +1,20 @@
|
|
|
1
1
|
<script>import { getContext, afterUpdate, tick } from "svelte";
|
|
2
2
|
import { data_tick_store, contextItemsStore, contextTypesStore } from "../../../stores";
|
|
3
|
-
import { getActive, activateItem } from "../../../utils.js";
|
|
3
|
+
import { getActive, activateItem, editable, isActive, isSelected, selectable, startEditing } from "../../../utils.js";
|
|
4
4
|
import Card from "./kanban.card.svelte";
|
|
5
5
|
import { KanbanColumnTop, KanbanColumnBottom } from "../Kanban";
|
|
6
6
|
import Inserter from "./kanban.inserter.svelte";
|
|
7
|
-
import { FaPlus } from "svelte-icons/fa";
|
|
8
|
-
export let title = "";
|
|
9
|
-
export let width = "w-[240px]";
|
|
10
|
-
export let self = void 0;
|
|
11
|
-
export let a = "";
|
|
12
|
-
export let objects = void 0;
|
|
13
|
-
export let context = "";
|
|
14
|
-
export let key = "";
|
|
7
|
+
import { FaPlus, FaCheck } from "svelte-icons/fa";
|
|
15
8
|
export let currentColumnIdx;
|
|
16
|
-
export let
|
|
17
|
-
export let scrollViewToCard = void 0;
|
|
9
|
+
export let onInsert;
|
|
18
10
|
let column_element;
|
|
19
11
|
export function getHeight() {
|
|
20
12
|
return column_element.getBoundingClientRect().height;
|
|
21
13
|
}
|
|
14
|
+
let titleElement;
|
|
15
|
+
export function editName(onFinish = void 0) {
|
|
16
|
+
startEditing(titleElement, onFinish);
|
|
17
|
+
}
|
|
22
18
|
export const SET_LEFT = 0;
|
|
23
19
|
export const SET_RIGHT = 1;
|
|
24
20
|
export const CLEAR_LEFT = 2;
|
|
@@ -40,58 +36,70 @@ export function setBorder(what_to_do) {
|
|
|
40
36
|
}
|
|
41
37
|
}
|
|
42
38
|
let definition = getContext("rKanban-definition");
|
|
43
|
-
let
|
|
44
|
-
let
|
|
45
|
-
let
|
|
46
|
-
let last_tick = -1;
|
|
47
|
-
let item_key = "";
|
|
48
|
-
let width_class = width ? `w-11/12 sm:${width}` : "w-11/12 sm:w-[240px]";
|
|
39
|
+
let columnDef = definition.columns[currentColumnIdx];
|
|
40
|
+
let column_items = void 0;
|
|
41
|
+
let width_class = columnDef.width ? `w-11/12 sm:${columnDef.width}` : "w-11/12 sm:w-[240px]";
|
|
49
42
|
$:
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
43
|
+
setup_data();
|
|
44
|
+
$:
|
|
45
|
+
is_row_active = calculate_active($contextItemsStore);
|
|
46
|
+
$:
|
|
47
|
+
is_row_selected = selected($contextItemsStore);
|
|
48
|
+
$:
|
|
49
|
+
selected_class = is_row_selected ? "!border-blue-300" : "";
|
|
50
|
+
$:
|
|
51
|
+
focused_class = is_row_active ? "bg-stone-50 dark:bg-stone-700" : "";
|
|
52
|
+
$:
|
|
53
|
+
force_rerender($data_tick_store, $contextItemsStore);
|
|
54
|
+
export function reload() {
|
|
55
|
+
let allItems = definition.getItems();
|
|
56
|
+
if (definition.stateAttrib)
|
|
57
|
+
column_items = allItems.filter((e) => e[definition.stateAttrib] == columnDef.state);
|
|
58
|
+
}
|
|
59
|
+
function setup_data(...args) {
|
|
60
|
+
reload();
|
|
61
|
+
}
|
|
62
|
+
function force_rerender(...args) {
|
|
63
|
+
column_items = [...column_items];
|
|
64
|
+
}
|
|
65
|
+
function calculate_active(...args) {
|
|
66
|
+
if (!!columnDef.operations)
|
|
67
|
+
return isActive("props", columnDef);
|
|
68
|
+
else
|
|
69
|
+
return false;
|
|
70
|
+
}
|
|
71
|
+
function selected(...args) {
|
|
72
|
+
if (!!columnDef.operations)
|
|
73
|
+
return isSelected(columnDef);
|
|
74
|
+
else
|
|
75
|
+
return false;
|
|
75
76
|
}
|
|
76
77
|
let cards = [];
|
|
77
|
-
export function findCardByItem(
|
|
78
|
+
export function findCardByItem(item) {
|
|
78
79
|
if (!cards)
|
|
79
80
|
return null;
|
|
80
|
-
const
|
|
81
|
-
if (
|
|
82
|
-
return cards[
|
|
81
|
+
const itemIdx = column_items?.findIndex((i) => i == item);
|
|
82
|
+
if (itemIdx >= 0) {
|
|
83
|
+
return cards[itemIdx];
|
|
83
84
|
} else
|
|
84
85
|
return null;
|
|
85
86
|
}
|
|
87
|
+
export function activateByItemId(id) {
|
|
88
|
+
const itemIdx = column_items?.findIndex((e) => e.Id == id);
|
|
89
|
+
if (itemIdx >= 0) {
|
|
90
|
+
const card = cards[itemIdx];
|
|
91
|
+
card.activate();
|
|
92
|
+
}
|
|
93
|
+
}
|
|
86
94
|
let inserter;
|
|
87
95
|
const None = 0;
|
|
88
|
-
let
|
|
96
|
+
let showInserterAfterId = None;
|
|
89
97
|
let activateAfterDomUpdate = null;
|
|
90
98
|
let lastActivatedElement = null;
|
|
91
99
|
export async function add(after = KanbanColumnTop) {
|
|
92
100
|
if (!definition.onAdd)
|
|
93
101
|
return;
|
|
94
|
-
|
|
102
|
+
showInserterAfterId = after.Id ?? KanbanColumnTop;
|
|
95
103
|
if (activateAfterDomUpdate)
|
|
96
104
|
activateAfterDomUpdate = null;
|
|
97
105
|
lastActivatedElement = getActive("props");
|
|
@@ -101,81 +109,117 @@ export async function add(after = KanbanColumnTop) {
|
|
|
101
109
|
if (!inserter)
|
|
102
110
|
return;
|
|
103
111
|
inserter.run(async (detail) => {
|
|
104
|
-
|
|
112
|
+
showInserterAfterId = None;
|
|
105
113
|
if (detail.cancel)
|
|
106
114
|
activateAfterDomUpdate = lastActivatedElement;
|
|
107
115
|
else {
|
|
108
116
|
if (detail.incremental) {
|
|
109
117
|
let currentActive = activateAfterDomUpdate ?? getActive("props");
|
|
110
|
-
|
|
118
|
+
if (currentActive)
|
|
119
|
+
await add(currentActive);
|
|
111
120
|
}
|
|
112
121
|
}
|
|
113
122
|
});
|
|
114
123
|
}
|
|
115
|
-
async function insert(title2, after) {
|
|
116
|
-
let newElement = await definition.onAdd(title2, currentColumnIdx, after);
|
|
117
|
-
if (!newElement)
|
|
118
|
-
return;
|
|
119
|
-
activateAfterDomUpdate = newElement;
|
|
120
|
-
}
|
|
121
124
|
afterUpdate(() => {
|
|
122
125
|
if (activateAfterDomUpdate) {
|
|
123
|
-
let activateAfterDomUpdateIdx =
|
|
126
|
+
let activateAfterDomUpdateIdx = column_items.findIndex((e) => e == activateAfterDomUpdate);
|
|
124
127
|
activateAfterDomUpdate = null;
|
|
125
128
|
if (activateAfterDomUpdateIdx >= 0) {
|
|
126
129
|
cards[activateAfterDomUpdateIdx].activate();
|
|
127
130
|
}
|
|
128
131
|
}
|
|
129
132
|
});
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
{
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
133
|
+
function getItemKey(item) {
|
|
134
|
+
if (definition.key)
|
|
135
|
+
return item[definition.key];
|
|
136
|
+
else if (item.Id)
|
|
137
|
+
return item.Id;
|
|
138
|
+
else if (item.$ref)
|
|
139
|
+
return item.$ref;
|
|
140
|
+
else
|
|
141
|
+
return 0;
|
|
142
|
+
}
|
|
143
|
+
function onTitleChanged(text) {
|
|
144
|
+
if (columnDef.onTitleChanged)
|
|
145
|
+
columnDef.onTitleChanged(text);
|
|
146
|
+
}
|
|
147
|
+
let rootElement;
|
|
148
|
+
export function activate(e) {
|
|
149
|
+
if (e)
|
|
150
|
+
e.stopPropagation();
|
|
151
|
+
if (!columnDef.operations)
|
|
152
|
+
return;
|
|
153
|
+
if (isActive("props", columnDef)) {
|
|
154
|
+
return;
|
|
155
|
+
}
|
|
156
|
+
activateItem("props", columnDef, columnDef.operations);
|
|
157
|
+
rootElement?.scrollIntoView();
|
|
158
|
+
}
|
|
159
|
+
</script>
|
|
160
|
+
|
|
161
|
+
<!-- svelte-ignore a11y-click-events-have-key-events -->
|
|
162
|
+
|
|
163
|
+
<section class="snap-center sm:snap-align-none flex-none sm:flex-1 sm:min-w-[180px] sm:max-w-[240px] rounded-md border border-transparent {width_class} {selected_class} {focused_class}"
|
|
164
|
+
bind:this={rootElement}>
|
|
165
|
+
<header class:cursor-pointer={!is_row_active && columnDef.operations}
|
|
166
|
+
use:selectable={columnDef}
|
|
167
|
+
on:click={activate}>
|
|
168
|
+
<h2 class="mt-2 mb-2 text-lg sm:text-xs uppercase w-full min-h-[1rem] text-center whitespace-nowrap relative">
|
|
169
|
+
<span
|
|
170
|
+
use:editable={{
|
|
171
|
+
action: (text) => onTitleChanged(text),
|
|
172
|
+
active: false
|
|
173
|
+
}}
|
|
174
|
+
bind:this={titleElement}>
|
|
175
|
+
{columnDef.title}
|
|
176
|
+
</span>
|
|
177
|
+
|
|
178
|
+
{#if columnDef.finishing}
|
|
179
|
+
<div class="inline-block text-green-600 h-3 w-3 ml-2">
|
|
180
|
+
<FaCheck/>
|
|
181
|
+
</div>
|
|
182
|
+
{/if}
|
|
183
|
+
<button class="absolute right-2 w-4 sm:w-2.5"
|
|
184
|
+
on:click|stopPropagation={(e) => add(KanbanColumnTop)}>
|
|
185
|
+
<FaPlus/>
|
|
186
|
+
</button>
|
|
187
|
+
</h2>
|
|
188
|
+
</header>
|
|
189
|
+
<ul class="w-full border-stone-700" bind:this={column_element}>
|
|
190
|
+
{#if showInserterAfterId === KanbanColumnTop}
|
|
191
|
+
<Inserter onInsert={async (text) => {await onInsert(currentColumnIdx, text, KanbanColumnTop)}}
|
|
192
|
+
bind:this={inserter} />
|
|
193
|
+
{/if}
|
|
194
|
+
|
|
195
|
+
{#if column_items && column_items.length > 0}
|
|
196
|
+
{#each column_items as element, item_idx (getItemKey(element))}
|
|
197
|
+
<Card item={element}
|
|
198
|
+
bind:this={cards[item_idx]}>
|
|
199
|
+
<svelte:fragment slot="kanbanCardTopProps" let:element>
|
|
200
|
+
<slot name="kanbanCardTopProps" {element}/>
|
|
201
|
+
</svelte:fragment>
|
|
202
|
+
|
|
203
|
+
<svelte:fragment slot="kanbanCardMiddleProps" let:element>
|
|
204
|
+
<slot name="kanbanCardMiddleProps" {element}/>
|
|
205
|
+
</svelte:fragment>
|
|
206
|
+
|
|
207
|
+
<svelte:fragment slot="kanbanCardBottomProps" let:element>
|
|
208
|
+
<slot name="kanbanCardBottomProps" {element}/>
|
|
209
|
+
</svelte:fragment>
|
|
210
|
+
</Card>
|
|
211
|
+
|
|
212
|
+
{#if showInserterAfterId == element.Id}
|
|
213
|
+
<Inserter onInsert={async (text) => {await onInsert(currentColumnIdx, text, showInserterAfterId)}}
|
|
214
|
+
bind:this={inserter} />
|
|
215
|
+
{/if}
|
|
216
|
+
{/each}
|
|
217
|
+
{/if}
|
|
218
|
+
|
|
219
|
+
{#if showInserterAfterId === KanbanColumnBottom}
|
|
220
|
+
<Inserter onInsert={async (text) => {await onInsert(currentColumnIdx, text, KanbanColumnBottom)}}
|
|
221
|
+
bind:this={inserter} />
|
|
222
|
+
{/if}
|
|
223
|
+
|
|
224
|
+
</ul>
|
|
181
225
|
</section>
|
|
@@ -1,51 +1,51 @@
|
|
|
1
|
-
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
declare const __propDef: {
|
|
3
|
-
props: {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
get
|
|
43
|
-
get
|
|
44
|
-
get
|
|
45
|
-
get
|
|
46
|
-
get
|
|
47
|
-
get
|
|
48
|
-
get
|
|
49
|
-
get
|
|
50
|
-
}
|
|
51
|
-
export {};
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {
|
|
4
|
+
currentColumnIdx: number;
|
|
5
|
+
onInsert: Function;
|
|
6
|
+
getHeight?: (() => number) | undefined;
|
|
7
|
+
editName?: ((onFinish?: Function | undefined) => void) | undefined;
|
|
8
|
+
SET_LEFT?: 0 | undefined;
|
|
9
|
+
SET_RIGHT?: 1 | undefined;
|
|
10
|
+
CLEAR_LEFT?: 2 | undefined;
|
|
11
|
+
CLEAR_RIGHT?: 3 | undefined;
|
|
12
|
+
setBorder?: ((what_to_do: number) => void) | undefined;
|
|
13
|
+
reload?: (() => void) | undefined;
|
|
14
|
+
findCardByItem?: ((item: object) => any) | undefined;
|
|
15
|
+
activateByItemId?: ((id: number) => void) | undefined;
|
|
16
|
+
add?: ((after?: object | number) => Promise<void>) | undefined;
|
|
17
|
+
activate?: ((e: any) => void) | undefined;
|
|
18
|
+
};
|
|
19
|
+
events: {
|
|
20
|
+
[evt: string]: CustomEvent<any>;
|
|
21
|
+
};
|
|
22
|
+
slots: {
|
|
23
|
+
kanbanCardTopProps: {
|
|
24
|
+
element: object;
|
|
25
|
+
};
|
|
26
|
+
kanbanCardMiddleProps: {
|
|
27
|
+
element: object;
|
|
28
|
+
};
|
|
29
|
+
kanbanCardBottomProps: {
|
|
30
|
+
element: object;
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
export type KanbanProps = typeof __propDef.props;
|
|
35
|
+
export type KanbanEvents = typeof __propDef.events;
|
|
36
|
+
export type KanbanSlots = typeof __propDef.slots;
|
|
37
|
+
export default class Kanban extends SvelteComponentTyped<KanbanProps, KanbanEvents, KanbanSlots> {
|
|
38
|
+
get getHeight(): () => number;
|
|
39
|
+
get editName(): (onFinish?: Function | undefined) => void;
|
|
40
|
+
get SET_LEFT(): 0;
|
|
41
|
+
get SET_RIGHT(): 1;
|
|
42
|
+
get CLEAR_LEFT(): 2;
|
|
43
|
+
get CLEAR_RIGHT(): 3;
|
|
44
|
+
get setBorder(): (what_to_do: number) => void;
|
|
45
|
+
get reload(): () => void;
|
|
46
|
+
get findCardByItem(): (item: object) => any;
|
|
47
|
+
get activateByItemId(): (id: number) => void;
|
|
48
|
+
get add(): (after?: number | object) => Promise<void>;
|
|
49
|
+
get activate(): (e: any) => void;
|
|
50
|
+
}
|
|
51
|
+
export {};
|
|
@@ -7,18 +7,18 @@ export function run(onclose) {
|
|
|
7
7
|
startEditing(insertion_paragraph, onclose);
|
|
8
8
|
}
|
|
9
9
|
let insertion_paragraph;
|
|
10
|
-
</script>
|
|
11
|
-
|
|
12
|
-
<!-- svelte-ignore a11y-click-events-have-key-events -->
|
|
13
|
-
|
|
14
|
-
<li class=" mx-2 pt-2 pb-4 px-1 rounded-md border border-transparent
|
|
15
|
-
bg-stone-100 dark:bg-stone-700">
|
|
16
|
-
|
|
17
|
-
<h3 class=" text-lg font-semibold min-h-[1.75rem]
|
|
18
|
-
sm:text-sm sm:font-semibold sm:min-h-[1.25rem]
|
|
19
|
-
whitespace-nowrap overflow-clip w-full sm:flex-none
|
|
20
|
-
use:editable={onInsert}
|
|
21
|
-
bind:this={insertion_paragraph}>
|
|
22
|
-
|
|
23
|
-
</h3>
|
|
10
|
+
</script>
|
|
11
|
+
|
|
12
|
+
<!-- svelte-ignore a11y-click-events-have-key-events -->
|
|
13
|
+
|
|
14
|
+
<li class=" mx-2 pt-2 pb-4 px-1 rounded-md border border-transparent
|
|
15
|
+
bg-stone-100 dark:bg-stone-700">
|
|
16
|
+
|
|
17
|
+
<h3 class=" text-lg font-semibold min-h-[1.75rem]
|
|
18
|
+
sm:text-sm sm:font-semibold sm:min-h-[1.25rem]
|
|
19
|
+
whitespace-nowrap overflow-clip w-full sm:flex-none "
|
|
20
|
+
use:editable={onInsert}
|
|
21
|
+
bind:this={insertion_paragraph}>
|
|
22
|
+
|
|
23
|
+
</h3>
|
|
24
24
|
</li>
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
declare const __propDef: {
|
|
3
|
-
props: {
|
|
4
|
-
onInsert: any;
|
|
5
|
-
run?: ((onclose: any) => void) | undefined;
|
|
6
|
-
};
|
|
7
|
-
events: {
|
|
8
|
-
[evt: string]: CustomEvent<any>;
|
|
9
|
-
};
|
|
10
|
-
slots: {};
|
|
11
|
-
};
|
|
12
|
-
export type KanbanProps = typeof __propDef.props;
|
|
13
|
-
export type KanbanEvents = typeof __propDef.events;
|
|
14
|
-
export type KanbanSlots = typeof __propDef.slots;
|
|
15
|
-
export default class Kanban extends SvelteComponentTyped<KanbanProps, KanbanEvents, KanbanSlots> {
|
|
16
|
-
get run(): (onclose: any) => void;
|
|
17
|
-
}
|
|
18
|
-
export {};
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {
|
|
4
|
+
onInsert: any;
|
|
5
|
+
run?: ((onclose: any) => void) | undefined;
|
|
6
|
+
};
|
|
7
|
+
events: {
|
|
8
|
+
[evt: string]: CustomEvent<any>;
|
|
9
|
+
};
|
|
10
|
+
slots: {};
|
|
11
|
+
};
|
|
12
|
+
export type KanbanProps = typeof __propDef.props;
|
|
13
|
+
export type KanbanEvents = typeof __propDef.events;
|
|
14
|
+
export type KanbanSlots = typeof __propDef.slots;
|
|
15
|
+
export default class Kanban extends SvelteComponentTyped<KanbanProps, KanbanEvents, KanbanSlots> {
|
|
16
|
+
get run(): (onclose: any) => void;
|
|
17
|
+
}
|
|
18
|
+
export {};
|