@optionfactory/fml 9.0.0-rc13 → 9.0.0-rc14
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 +1 -1
- package/dist/client-errors.iife.js +6 -11
- package/dist/client-errors.iife.js.map +1 -1
- package/dist/client-errors.iife.min.js +1 -1
- package/dist/client-errors.iife.min.js.map +1 -1
- package/dist/custom-elements.json +45 -10
- package/dist/fml.css +5 -5
- package/dist/fml.css.map +1 -1
- package/dist/fml.iife.js +472 -56
- package/dist/fml.iife.js.map +1 -1
- package/dist/fml.iife.min.js +1 -1
- package/dist/fml.iife.min.js.map +1 -1
- package/dist/ftl.iife.js +2 -2
- package/dist/ftl.iife.js.map +1 -1
- package/dist/ftl.iife.min.js +1 -1
- package/dist/ftl.iife.min.js.map +1 -1
- package/dist/ftl.min.mjs +1 -1
- package/dist/ftl.min.mjs.map +1 -1
- package/dist/ftl.mjs +2 -2
- package/dist/ftl.mjs.map +1 -1
- package/dist/ful.css +5 -5
- package/dist/ful.css.map +1 -1
- package/dist/ful.d.mts +79 -7
- package/dist/ful.iife.js +470 -54
- package/dist/ful.iife.js.map +1 -1
- package/dist/ful.iife.min.js +1 -1
- package/dist/ful.iife.min.js.map +1 -1
- package/dist/ful.min.mjs +1 -1
- package/dist/ful.min.mjs.map +1 -1
- package/dist/ful.mjs +470 -54
- package/dist/ful.mjs.map +1 -1
- package/dist/vscode.html-custom-data.json +27 -7
- package/dist/web-types.json +51 -11
- package/package.json +1 -1
package/dist/ful.d.mts
CHANGED
|
@@ -303,6 +303,8 @@ declare class Field extends ParsedElement {
|
|
|
303
303
|
* @param {string} [context] the path below this field's name, '' when exact
|
|
304
304
|
*/
|
|
305
305
|
setCustomValidity(error?: string, context?: string): void;
|
|
306
|
+
/** The form the platform associated the field with, null outside one: a native control's own `form`. */
|
|
307
|
+
get form(): HTMLFormElement | null;
|
|
306
308
|
/** Submits the associated form through its first submitter, as Enter on a native control would. */
|
|
307
309
|
_requestSubmit(): void;
|
|
308
310
|
/**
|
|
@@ -632,8 +634,10 @@ declare class Anchors {
|
|
|
632
634
|
* the popover, giving toggle and light dismiss with no script of your own
|
|
633
635
|
* @param {boolean} [options.expanded] keeps the invoker's `aria-expanded` in
|
|
634
636
|
* step with the popover
|
|
635
|
-
* @param {boolean} [options.stretch] widens the popover to
|
|
636
|
-
* is what a combobox
|
|
637
|
+
* @param {boolean} [options.stretch] widens the popover to at least its
|
|
638
|
+
* invoker's width, capped by its own `max-width`, which is what a combobox
|
|
639
|
+
* dropdown wants; it flips above the invoker where the viewport leaves no
|
|
640
|
+
* room below
|
|
637
641
|
* @param {boolean} [options.handPlace] places here on every platform rather
|
|
638
642
|
* than only as a fallback, which a popover asks for when it needs to know
|
|
639
643
|
* where its invoker ended up: the tooltip's note points a callout at it, and
|
|
@@ -648,6 +652,35 @@ declare class Anchors {
|
|
|
648
652
|
stretch?: boolean;
|
|
649
653
|
handPlace?: boolean;
|
|
650
654
|
}): void;
|
|
655
|
+
/**
|
|
656
|
+
* Shows and places a popover beside an anchor, once: the popover shared by
|
|
657
|
+
* many invokers, each open handing over its own anchor, and an anchor that
|
|
658
|
+
* is a rectangle rather than an element, one read out of an iframe being
|
|
659
|
+
* the case a paired invoker could not cover. No pairing, no reflow
|
|
660
|
+
* following, no close wiring: closing is the caller's, or the platform's
|
|
661
|
+
* for a light-dismissing popover.
|
|
662
|
+
*
|
|
663
|
+
* The placement is the menus' own geometry, below the anchor and
|
|
664
|
+
* start-aligned, clamped into the viewport; `flip` moves it above the
|
|
665
|
+
* anchor where the viewport leaves no room below, as the css
|
|
666
|
+
* `position-try-fallbacks` the paired popovers declare. A popover not
|
|
667
|
+
* already open is shown before it is placed, so the first position anybody
|
|
668
|
+
* sees is the right one.
|
|
669
|
+
*
|
|
670
|
+
* @param {HTMLElement} popover the `[popover]` element to show, or an
|
|
671
|
+
* already-shown element to place
|
|
672
|
+
* @param {Element|DOMRect} anchor the element, or the rectangle, to place
|
|
673
|
+
* beside
|
|
674
|
+
* @param {object} [options]
|
|
675
|
+
* @param {boolean} [options.flip] place above the anchor where no room is
|
|
676
|
+
* left below
|
|
677
|
+
* @param {number} [options.gap] the distance from the anchor, in pixels
|
|
678
|
+
* @returns {HTMLElement} the popover
|
|
679
|
+
*/
|
|
680
|
+
static show(popover: HTMLElement, anchor: Element | DOMRect, { flip, gap }?: {
|
|
681
|
+
flip?: boolean;
|
|
682
|
+
gap?: number;
|
|
683
|
+
}): HTMLElement;
|
|
651
684
|
}
|
|
652
685
|
/**
|
|
653
686
|
* Fetches a select's whole vocabulary from a url and serves every later read
|
|
@@ -765,6 +798,7 @@ declare class Select extends Field {
|
|
|
765
798
|
#private;
|
|
766
799
|
static attributes: string[];
|
|
767
800
|
static observed: string[];
|
|
801
|
+
unmarshal(attr: any, str: any): any;
|
|
768
802
|
static slots: boolean;
|
|
769
803
|
static template: string;
|
|
770
804
|
static templates: {
|
|
@@ -969,7 +1003,9 @@ export type FilterCriterion = {
|
|
|
969
1003
|
* the data-jpa compare annotations.
|
|
970
1004
|
*/
|
|
971
1005
|
declare class CompareFilter extends Input {
|
|
1006
|
+
#private;
|
|
972
1007
|
static observed: string[];
|
|
1008
|
+
static attributes: string[];
|
|
973
1009
|
static OPERATORS: string[];
|
|
974
1010
|
static DEFAULT_OPERATOR: string;
|
|
975
1011
|
static template: string;
|
|
@@ -1030,7 +1066,9 @@ declare class NumberFilter extends CompareFilter {
|
|
|
1030
1066
|
}
|
|
1031
1067
|
/** The compare filter over text, carrying a case sensitivity beside the operator. */
|
|
1032
1068
|
declare class TextFilter extends CompareFilter {
|
|
1069
|
+
#private;
|
|
1033
1070
|
static observed: string[];
|
|
1071
|
+
static attributes: string[];
|
|
1034
1072
|
static template: string;
|
|
1035
1073
|
_defaultOperator(): string;
|
|
1036
1074
|
_vocabulary(): string[];
|
|
@@ -1078,6 +1116,7 @@ declare class BooleanFilter extends Field {
|
|
|
1078
1116
|
_vocabulary(): string[];
|
|
1079
1117
|
get value(): any[] | null;
|
|
1080
1118
|
set value(v: any[] | null);
|
|
1119
|
+
formResetCallback(): void;
|
|
1081
1120
|
/** @returns {FilterCriterion|null} */
|
|
1082
1121
|
get criterion(): FilterCriterion | null;
|
|
1083
1122
|
get disabled(): boolean;
|
|
@@ -1181,6 +1220,34 @@ declare class Dialog extends ParsedElement {
|
|
|
1181
1220
|
*/
|
|
1182
1221
|
refresh(): Promise<any[] | undefined>;
|
|
1183
1222
|
close(result: any): void;
|
|
1223
|
+
/**
|
|
1224
|
+
* Asks a question in a dialog of the page's own, resolving with its outcome
|
|
1225
|
+
* and removing the element afterwards: the element stays the author's when
|
|
1226
|
+
* the question lives in the page, while a question asked from a button had
|
|
1227
|
+
* to build, render, show, answer and clean up by hand.
|
|
1228
|
+
*
|
|
1229
|
+
* The body is text or a node: a string is never read as markup, an
|
|
1230
|
+
* `innerHTML` sink being a thing the library does not carry. Each button is
|
|
1231
|
+
* a `[result, label, className?]` tuple, rendered as its answer.
|
|
1232
|
+
* @param {string} header
|
|
1233
|
+
* @param {string|Node} body
|
|
1234
|
+
* @param {[string, string, string?][]} [buttons]
|
|
1235
|
+
* @returns {Promise<DialogOutcome>}
|
|
1236
|
+
*/
|
|
1237
|
+
static ask(header: string, body: string | Node, buttons?: [string, string, string?][]): Promise<DialogOutcome>;
|
|
1238
|
+
/**
|
|
1239
|
+
* Asks a yes/no question, resolving with the confirm button's answer:
|
|
1240
|
+
* the cancel button, the close button and Escape all answer false, a
|
|
1241
|
+
* dismissal being the negative.
|
|
1242
|
+
* @param {string} header
|
|
1243
|
+
* @param {string|Node} body
|
|
1244
|
+
* @param {{ confirm?: string, cancel?: string }} [labels] overriding the localized defaults
|
|
1245
|
+
* @returns {Promise<boolean>}
|
|
1246
|
+
*/
|
|
1247
|
+
static confirm(header: string, body: string | Node, labels?: {
|
|
1248
|
+
confirm?: string;
|
|
1249
|
+
cancel?: string;
|
|
1250
|
+
}): Promise<boolean>;
|
|
1184
1251
|
}
|
|
1185
1252
|
/**
|
|
1186
1253
|
* A side panel drawer on the native dialog platform, update() owning its
|
|
@@ -1199,15 +1266,15 @@ declare class Drawer extends ParsedElement {
|
|
|
1199
1266
|
render({ slots }: {
|
|
1200
1267
|
slots: any;
|
|
1201
1268
|
}): void;
|
|
1202
|
-
get
|
|
1203
|
-
set
|
|
1269
|
+
get header(): any;
|
|
1270
|
+
set header(v: any);
|
|
1204
1271
|
/**
|
|
1205
|
-
* Opens the drawer under the given
|
|
1272
|
+
* Opens the drawer under the given header and waits for the callback: a
|
|
1206
1273
|
* resolved value paints the content section (which is returned), a
|
|
1207
1274
|
* rejection paints the problems and travels to the caller, and an update
|
|
1208
1275
|
* superseded by a newer one paints nothing.
|
|
1209
1276
|
*/
|
|
1210
|
-
update(
|
|
1277
|
+
update(header: any, cb: any): Promise<any>;
|
|
1211
1278
|
/**
|
|
1212
1279
|
* Re-fires section:requested on the content, open or closed: the explicit
|
|
1213
1280
|
* request for a body that wants refreshing. A failed refresh paints its
|
|
@@ -1228,8 +1295,13 @@ declare class Toasts extends ParsedElement {
|
|
|
1228
1295
|
* Appends a toast carrying the message (a Failure shows its problems'
|
|
1229
1296
|
* reasons, one per line), severity picking the theme and the announcement,
|
|
1230
1297
|
* the toast retiring through its own timer or its dismiss button.
|
|
1298
|
+
*
|
|
1299
|
+
* The timer holds while the toast is hovered or holds the focus, so an
|
|
1300
|
+
* actionable toast waits for its reader: `action` is `{ label, onClick }`,
|
|
1301
|
+
* a button beside the message whose click answers and retires. The same
|
|
1302
|
+
* options travel in the `show-toast` event's detail.
|
|
1231
1303
|
* @param {any} message
|
|
1232
|
-
* @param {any} [options] severity and
|
|
1304
|
+
* @param {any} [options] severity, timeout and action
|
|
1233
1305
|
* @returns {HTMLElement}
|
|
1234
1306
|
*/
|
|
1235
1307
|
show(message: any, options?: any): HTMLElement;
|