@leavepulse/ui 0.43.0 → 0.43.2
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/assets/{LpCommandPalette-s_kKuCRf.css → LpCommandPalette-DH7sPcKP.css} +21 -21
- package/dist/assets/{LpImageEditor-D-s8tNGO.css → LpImageEditor-Ct7Y3aNu.css} +6 -6
- package/dist/components/LpCommandPalette.vue.js +2 -2
- package/dist/components/LpImageEditor.vue.js +2 -2
- package/dist/components/modalDepth.js +2 -2
- package/package.json +1 -1
- package/src/components/LpCommandPalette.vue +4 -4
- package/src/components/LpImageEditor.vue +2 -2
- package/src/components/commandSearch.ts +1 -1
- package/src/components/modalDepth.ts +2 -2
- package/src/composables/useHotkeys.ts +1 -1
|
@@ -5,81 +5,81 @@
|
|
|
5
5
|
* pane from its right edge as it grows. Animating the columns themselves made
|
|
6
6
|
* every line of the list and the pane re-wrap on every frame.
|
|
7
7
|
*/
|
|
8
|
-
.lp-cmd-dialog[data-v-
|
|
8
|
+
.lp-cmd-dialog[data-v-0175ffca] {
|
|
9
9
|
--lp-cmd-list: min(92vw, 40rem);
|
|
10
10
|
--lp-cmd-pane: max(0px, min(26rem, 96vw - var(--lp-cmd-list)));
|
|
11
11
|
width: var(--lp-cmd-list);
|
|
12
12
|
}
|
|
13
|
-
.lp-cmd-split[data-v-
|
|
13
|
+
.lp-cmd-split[data-v-0175ffca] {
|
|
14
14
|
transition:
|
|
15
15
|
width 300ms var(--ease-emphasized, ease),
|
|
16
16
|
min-height 300ms var(--ease-emphasized, ease);
|
|
17
17
|
}
|
|
18
18
|
@media (min-width: 768px) {
|
|
19
|
-
.lp-cmd-split .lp-cmd-list[data-v-
|
|
19
|
+
.lp-cmd-split .lp-cmd-list[data-v-0175ffca] {
|
|
20
20
|
flex: 0 0 auto;
|
|
21
21
|
/* the dialog's 1px border on each side */
|
|
22
22
|
width: calc(var(--lp-cmd-list) - 2px);
|
|
23
23
|
}
|
|
24
|
-
.lp-cmd-dialog[data-pane="open"][data-v-
|
|
24
|
+
.lp-cmd-dialog[data-pane="open"][data-v-0175ffca] {
|
|
25
25
|
width: calc(var(--lp-cmd-list) + var(--lp-cmd-pane));
|
|
26
26
|
min-height: min(76vh, 36rem);
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
|
-
.lp-cmd-pane[data-v-
|
|
29
|
+
.lp-cmd-pane[data-v-0175ffca] {
|
|
30
30
|
width: var(--lp-cmd-pane);
|
|
31
31
|
}
|
|
32
32
|
/*
|
|
33
33
|
* The pane rides in from the right edge while the dialog opens up to it, and
|
|
34
34
|
* leaves the same way, for as long as the dialog takes to close over it.
|
|
35
35
|
*/
|
|
36
|
-
.lp-cmd-pane-enter-active[data-v-
|
|
37
|
-
.lp-cmd-pane-leave-active[data-v-
|
|
36
|
+
.lp-cmd-pane-enter-active[data-v-0175ffca],
|
|
37
|
+
.lp-cmd-pane-leave-active[data-v-0175ffca] {
|
|
38
38
|
transition:
|
|
39
39
|
transform 300ms var(--ease-emphasized, ease),
|
|
40
40
|
opacity 300ms ease;
|
|
41
41
|
}
|
|
42
|
-
.lp-cmd-pane-enter-from[data-v-
|
|
43
|
-
.lp-cmd-pane-leave-to[data-v-
|
|
42
|
+
.lp-cmd-pane-enter-from[data-v-0175ffca],
|
|
43
|
+
.lp-cmd-pane-leave-to[data-v-0175ffca] {
|
|
44
44
|
opacity: 0;
|
|
45
45
|
transform: translateX(40%);
|
|
46
46
|
}
|
|
47
|
-
.lp-cmd-para[data-v-
|
|
48
|
-
animation: lp-cmd-para-in-
|
|
47
|
+
.lp-cmd-para[data-v-0175ffca] {
|
|
48
|
+
animation: lp-cmd-para-in-0175ffca 260ms ease-out both;
|
|
49
49
|
}
|
|
50
|
-
@keyframes lp-cmd-para-in-
|
|
50
|
+
@keyframes lp-cmd-para-in-0175ffca {
|
|
51
51
|
from {
|
|
52
52
|
opacity: 0;
|
|
53
53
|
transform: translateY(4px);
|
|
54
54
|
}
|
|
55
55
|
}
|
|
56
56
|
@media (prefers-reduced-motion: reduce) {
|
|
57
|
-
.lp-cmd-split[data-v-
|
|
58
|
-
.lp-cmd-pane-enter-active[data-v-
|
|
59
|
-
.lp-cmd-pane-leave-active[data-v-
|
|
57
|
+
.lp-cmd-split[data-v-0175ffca],
|
|
58
|
+
.lp-cmd-pane-enter-active[data-v-0175ffca],
|
|
59
|
+
.lp-cmd-pane-leave-active[data-v-0175ffca] {
|
|
60
60
|
transition: none;
|
|
61
61
|
}
|
|
62
|
-
.lp-cmd-para[data-v-
|
|
62
|
+
.lp-cmd-para[data-v-0175ffca] {
|
|
63
63
|
animation: none;
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
|
-
.lp-cmd-excerpt[data-v-
|
|
66
|
+
.lp-cmd-excerpt[data-v-0175ffca] {
|
|
67
67
|
display: -webkit-box;
|
|
68
68
|
-webkit-box-orient: vertical;
|
|
69
69
|
overflow: hidden;
|
|
70
70
|
}
|
|
71
71
|
/* Each result eases in; honours reduced motion. */
|
|
72
|
-
.lp-cmd-item[data-v-
|
|
73
|
-
animation: lp-cmd-in-
|
|
72
|
+
.lp-cmd-item[data-v-0175ffca] {
|
|
73
|
+
animation: lp-cmd-in-0175ffca 140ms ease-out both;
|
|
74
74
|
}
|
|
75
|
-
@keyframes lp-cmd-in-
|
|
75
|
+
@keyframes lp-cmd-in-0175ffca {
|
|
76
76
|
from {
|
|
77
77
|
opacity: 0;
|
|
78
78
|
transform: translateY(3px);
|
|
79
79
|
}
|
|
80
80
|
}
|
|
81
81
|
@media (prefers-reduced-motion: reduce) {
|
|
82
|
-
.lp-cmd-item[data-v-
|
|
82
|
+
.lp-cmd-item[data-v-0175ffca] {
|
|
83
83
|
animation: none;
|
|
84
84
|
}
|
|
85
85
|
}
|
|
@@ -2,22 +2,22 @@
|
|
|
2
2
|
/* The picture settles into the frame instead of appearing in it. Scale rather
|
|
3
3
|
than a slide: the frame is the fixed thing here and the image lives inside
|
|
4
4
|
it, so anything that moved would read as a crop that had shifted. */
|
|
5
|
-
.lp-editor__image[data-v-
|
|
6
|
-
animation: lp-editor-in-
|
|
5
|
+
.lp-editor__image[data-v-a19a8cf6] {
|
|
6
|
+
animation: lp-editor-in-a19a8cf6 var(--duration-slow) var(--ease-settle) both;
|
|
7
7
|
}
|
|
8
|
-
.lp-editor__image--waiting[data-v-
|
|
8
|
+
.lp-editor__image--waiting[data-v-a19a8cf6] {
|
|
9
9
|
opacity: 0;
|
|
10
10
|
animation: none;
|
|
11
11
|
}
|
|
12
|
-
@keyframes lp-editor-in-
|
|
12
|
+
@keyframes lp-editor-in-a19a8cf6 {
|
|
13
13
|
from {
|
|
14
14
|
opacity: 0;
|
|
15
15
|
scale: 1.04;
|
|
16
16
|
}
|
|
17
17
|
}
|
|
18
18
|
@media (prefers-reduced-motion: reduce) {
|
|
19
|
-
.lp-editor__image[data-v-
|
|
20
|
-
.lp-editor__image--waiting[data-v-
|
|
19
|
+
.lp-editor__image[data-v-a19a8cf6],
|
|
20
|
+
.lp-editor__image--waiting[data-v-a19a8cf6] {
|
|
21
21
|
opacity: 1;
|
|
22
22
|
scale: 1;
|
|
23
23
|
animation: none;
|
|
@@ -9,7 +9,7 @@ import { useHotkeys } from "../composables/useHotkeys.js";
|
|
|
9
9
|
import { useModalLayer } from "./modalDepth.js";
|
|
10
10
|
import { parseCommandQuery, rankCommandItems, swapCommandTerms } from "./commandSearch.js";
|
|
11
11
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper-1tPrXgE0.js";
|
|
12
|
-
import '../assets/LpCommandPalette-
|
|
12
|
+
import '../assets/LpCommandPalette-DH7sPcKP.css';const _hoisted_1 = { class: "flex shrink-0 items-center gap-2.5 border-b border-line px-4" };
|
|
13
13
|
const _hoisted_2 = ["title", "onClick"];
|
|
14
14
|
const _hoisted_3 = ["aria-activedescendant", "placeholder", "onKeydown"];
|
|
15
15
|
const _hoisted_4 = {
|
|
@@ -783,7 +783,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
783
783
|
};
|
|
784
784
|
}
|
|
785
785
|
});
|
|
786
|
-
const LpCommandPalette = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
786
|
+
const LpCommandPalette = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-0175ffca"]]);
|
|
787
787
|
export {
|
|
788
788
|
LpCommandPalette as default
|
|
789
789
|
};
|
|
@@ -7,7 +7,7 @@ import "reka-ui";
|
|
|
7
7
|
import { _ as _sfc_main$2 } from "../chunks/LpIcon-CCnX5_2j.js";
|
|
8
8
|
import { useMergedAttrs } from "../composables/useMergedClass.js";
|
|
9
9
|
import { _ as _export_sfc } from "../chunks/_plugin-vue_export-helper-1tPrXgE0.js";
|
|
10
|
-
import '../assets/LpImageEditor-
|
|
10
|
+
import '../assets/LpImageEditor-Ct7Y3aNu.css';const _hoisted_1 = ["aria-label"];
|
|
11
11
|
const _hoisted_2 = ["src"];
|
|
12
12
|
const _hoisted_3 = {
|
|
13
13
|
key: 0,
|
|
@@ -363,7 +363,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
363
363
|
};
|
|
364
364
|
}
|
|
365
365
|
});
|
|
366
|
-
const LpImageEditor = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
366
|
+
const LpImageEditor = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-a19a8cf6"]]);
|
|
367
367
|
export {
|
|
368
368
|
LpImageEditor as default
|
|
369
369
|
};
|
|
@@ -18,8 +18,8 @@ function useModalLayer() {
|
|
|
18
18
|
layer: computed(() => {
|
|
19
19
|
const drop = fromTop.value * STEP;
|
|
20
20
|
return {
|
|
21
|
-
scrim: `calc(var(--z-
|
|
22
|
-
panel: `calc(var(--z-
|
|
21
|
+
scrim: `calc(var(--z-overlay) - ${drop})`,
|
|
22
|
+
panel: `calc(var(--z-modal) - ${drop})`,
|
|
23
23
|
nested: stack.value.indexOf(id) > 0
|
|
24
24
|
};
|
|
25
25
|
})
|
package/package.json
CHANGED
|
@@ -192,7 +192,7 @@ const props = withDefaults(
|
|
|
192
192
|
groupLimit?: number
|
|
193
193
|
/**
|
|
194
194
|
* When the query matches nothing, retry it as if typed in the other
|
|
195
|
-
* keyboard layout (QWERTY ↔
|
|
195
|
+
* keyboard layout (QWERTY ↔ Cyrillic). Off for an app whose commands are
|
|
196
196
|
* meant to be typed in one layout only.
|
|
197
197
|
*/
|
|
198
198
|
layoutFallback?: boolean
|
|
@@ -451,8 +451,8 @@ function refresh() {
|
|
|
451
451
|
const source = computed<Command[]>(() => (mode.value ? modeItems.value : props.commands))
|
|
452
452
|
|
|
453
453
|
/*
|
|
454
|
-
* Keyboard layouts typed through each other
|
|
455
|
-
*
|
|
454
|
+
* Keyboard layouts typed through each other use a QWERTY ↔ Cyrillic map.
|
|
455
|
+
* Only that pair is mapped —
|
|
456
456
|
* the one bilingual setup common enough to be worth a table — and it is a
|
|
457
457
|
* fallback, tried only when the query as typed matches nothing.
|
|
458
458
|
*/
|
|
@@ -829,7 +829,7 @@ onBeforeUnmount(release)
|
|
|
829
829
|
|
|
830
830
|
// Through useHotkeys rather than a listener of its own: the palette is the one
|
|
831
831
|
// shortcut that has to work from inside a text field, and `code` is what makes
|
|
832
|
-
// it fire on a layout where Ctrl-K
|
|
832
|
+
// it fire on a layout where Ctrl-K has a different reported key.
|
|
833
833
|
useHotkeys(() =>
|
|
834
834
|
props.hotkey
|
|
835
835
|
? [
|
|
@@ -347,8 +347,8 @@ function onWheel(event: WheelEvent) {
|
|
|
347
347
|
* Shortcuts, through the kit's registry rather than a switch of my own.
|
|
348
348
|
*
|
|
349
349
|
* useHotkeys answers three things a hand-rolled handler gets wrong, and one of
|
|
350
|
-
* them bites here specifically:
|
|
351
|
-
*
|
|
350
|
+
* them bites here specifically: a Cyrillic layout changes the reported key,
|
|
351
|
+
* so matching the letter alone would leave the shortcut dead for
|
|
352
352
|
* the person most likely to be using this. Scoped to the viewport, so two
|
|
353
353
|
* editors on a page do not both answer the same key.
|
|
354
354
|
*/
|
|
@@ -13,7 +13,7 @@ export interface CommandSearchTerms {
|
|
|
13
13
|
|
|
14
14
|
const QUERY_TOKEN = /(-?)(?:(in):)?(?:"([^"]*)"|(\S+))/giu
|
|
15
15
|
const LATIN = "qwertyuiop[]asdfghjkl;'zxcvbnm,.`"
|
|
16
|
-
const CYRILLIC = "
|
|
16
|
+
const CYRILLIC = "\u0439\u0446\u0443\u043A\u0435\u043D\u0433\u0448\u0449\u0437\u0445\u044A\u0444\u044B\u0432\u0430\u043F\u0440\u043E\u043B\u0434\u0436\u044D\u044F\u0447\u0441\u043C\u0438\u0442\u044C\u0431\u044E\u0451"
|
|
17
17
|
const SWAP = new Map<string, string>()
|
|
18
18
|
|
|
19
19
|
for (let i = 0; i < LATIN.length; i++) {
|
|
@@ -27,8 +27,8 @@ export function useModalLayer(): {
|
|
|
27
27
|
layer: computed(() => {
|
|
28
28
|
const drop = fromTop.value * STEP
|
|
29
29
|
return {
|
|
30
|
-
scrim: `calc(var(--z-
|
|
31
|
-
panel: `calc(var(--z-
|
|
30
|
+
scrim: `calc(var(--z-overlay) - ${drop})`,
|
|
31
|
+
panel: `calc(var(--z-modal) - ${drop})`,
|
|
32
32
|
nested: stack.value.indexOf(id) > 0,
|
|
33
33
|
}
|
|
34
34
|
}),
|
|
@@ -9,7 +9,7 @@ import { computed, onBeforeUnmount, onMounted, shallowReactive, type MaybeRefOrG
|
|
|
9
9
|
*
|
|
10
10
|
* layout — a binding names its key twice over. `key` is what the layout
|
|
11
11
|
* produced, `code` is the physical position, and either matching counts. On
|
|
12
|
-
* a Cyrillic layout Ctrl+K arrives
|
|
12
|
+
* a Cyrillic layout Ctrl+K arrives under a different `key` with `code: "KeyK"`, and a
|
|
13
13
|
* user pressing the key printed "K" expects it to work either way.
|
|
14
14
|
*
|
|
15
15
|
* IME — a composing input delivers every keystroke as its own event, so
|