@m3ui-vue/m3ui-vue 1.3.8 → 1.4.1
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/API.md +1102 -20
- package/dist/{MButton-D5eJiDza.js → MButton-DQMTIlaV.js} +2 -2
- package/dist/{MButton-D5eJiDza.js.map → MButton-DQMTIlaV.js.map} +1 -1
- package/dist/{MDialog-WqB0jewp.js → MDialog-cdgapGfZ.js} +2 -2
- package/dist/{MDialog-WqB0jewp.js.map → MDialog-cdgapGfZ.js.map} +1 -1
- package/dist/{MListItem-Cf-C2Ru-.js → MListItem-ZkSGIIrb.js} +2 -2
- package/dist/{MListItem-Cf-C2Ru-.js.map → MListItem-ZkSGIIrb.js.map} +1 -1
- package/dist/{MLoadingIndicator-D4GzEZoH.js → MLoadingIndicator-U6_oGx8z.js} +2 -2
- package/dist/{MLoadingIndicator-D4GzEZoH.js.map → MLoadingIndicator-U6_oGx8z.js.map} +1 -1
- package/dist/{MSeekBar-B19xoWE3.js → MSeekBar-DTZVizZg.js} +2 -2
- package/dist/{MSeekBar-B19xoWE3.js.map → MSeekBar-DTZVizZg.js.map} +1 -1
- package/dist/{MSlider-9RoiuebS.js → MSlider-CqJkEYRZ.js} +2 -2
- package/dist/{MSlider-9RoiuebS.js.map → MSlider-CqJkEYRZ.js.map} +1 -1
- package/dist/{MSpinner-BNF8MN-L.js → MSpinner-Btgc-0nb.js} +2 -2
- package/dist/{MSpinner-BNF8MN-L.js.map → MSpinner-Btgc-0nb.js.map} +1 -1
- package/dist/{MTextField-CuG0T3qh.js → MTextField-B6M0gJEO.js} +2 -2
- package/dist/{MTextField-CuG0T3qh.js.map → MTextField-B6M0gJEO.js.map} +1 -1
- package/dist/{MTooltip-Bv7yxngk.js → MTooltip-Dspji4XG.js} +4 -4
- package/dist/{MTooltip-Bv7yxngk.js.map → MTooltip-Dspji4XG.js.map} +1 -1
- package/dist/api.json +1 -1
- package/dist/code-editor.js +1 -1
- package/dist/components/MAudioPlayer.vue.d.ts +2 -2
- package/dist/components/MAvailabilityCalendar.vue.d.ts +83 -0
- package/dist/components/MBeforeAfter.vue.d.ts +61 -0
- package/dist/components/MBodyMap.vue.d.ts +70 -0
- package/dist/components/MCandlestickChart.vue.d.ts +82 -0
- package/dist/components/MCertificate.vue.d.ts +76 -0
- package/dist/components/MCountdown.vue.d.ts +80 -0
- package/dist/components/MCreditCardInput.vue.d.ts +75 -0
- package/dist/components/MMortgageCalculator.vue.d.ts +83 -0
- package/dist/components/MOdontogram.vue.d.ts +86 -0
- package/dist/components/MOrderBook.vue.d.ts +89 -0
- package/dist/components/MOrderTicket.vue.d.ts +91 -0
- package/dist/components/MPosKeypad.vue.d.ts +84 -0
- package/dist/components/MProductConfigurator.vue.d.ts +136 -0
- package/dist/components/MQuiz.vue.d.ts +102 -0
- package/dist/components/MReceipt.vue.d.ts +93 -0
- package/dist/components/MSeatMap.vue.d.ts +131 -0
- package/dist/components/MSeekBar.vue.d.ts +1 -1
- package/dist/components/MTicket.vue.d.ts +83 -0
- package/dist/components/MVideoPlayer.vue.d.ts +1 -1
- package/dist/components/MVitalsChart.vue.d.ts +73 -0
- package/dist/composables/_printElement.d.ts +9 -0
- package/dist/composables/cardBrand.d.ts +25 -0
- package/dist/composables/mortgage.d.ts +37 -0
- package/dist/composables/useLocale.d.ts +131 -0
- package/dist/draw.js +2 -2
- package/dist/flow.js +1 -1
- package/dist/gantt.js +1 -1
- package/dist/index.d.ts +37 -0
- package/dist/locales/index.js +924 -7
- package/dist/locales/index.js.map +1 -1
- package/dist/m3ui-vue.css +1 -1
- package/dist/m3ui.js +10125 -5263
- package/dist/m3ui.js.map +1 -1
- package/dist/map.js +5 -5
- package/dist/media.js +4 -4
- package/dist/pdf.js +4 -4
- package/dist/rich-text-editor.js +4 -4
- package/dist/styles.css +1 -1
- package/dist/{useLocale-D2ucaY-l.js → useLocale-DLKJIRFi.js} +133 -2
- package/dist/useLocale-DLKJIRFi.js.map +1 -0
- package/package.json +1 -1
- package/src/__tests__/MAvailabilityCalendar.test.ts +85 -0
- package/src/__tests__/MBeforeAfter.test.ts +79 -0
- package/src/__tests__/MBodyMap.test.ts +60 -0
- package/src/__tests__/MCandlestickChart.test.ts +66 -0
- package/src/__tests__/MCertificate.test.ts +32 -0
- package/src/__tests__/MCountdown.test.ts +75 -0
- package/src/__tests__/MCreditCardInput.test.ts +122 -0
- package/src/__tests__/MMortgageCalculator.test.ts +49 -0
- package/src/__tests__/MOdontogram.test.ts +93 -0
- package/src/__tests__/MOrderBook.test.ts +66 -0
- package/src/__tests__/MOrderTicket.test.ts +68 -0
- package/src/__tests__/MPosKeypad.test.ts +116 -0
- package/src/__tests__/MProductConfigurator.test.ts +73 -0
- package/src/__tests__/MQuiz.test.ts +104 -0
- package/src/__tests__/MReceipt.test.ts +52 -0
- package/src/__tests__/MSeatMap.test.ts +76 -0
- package/src/__tests__/MTicket.test.ts +38 -0
- package/src/__tests__/MVitalsChart.test.ts +49 -0
- package/src/__tests__/clearToNull.test.ts +30 -0
- package/src/__tests__/mortgage.test.ts +25 -0
- package/src/__tests__/ssr.test.ts +11 -0
- package/src/components/MAutocomplete.vue +2 -2
- package/src/components/MAvailabilityCalendar.vue +460 -0
- package/src/components/MBeforeAfter.vue +248 -0
- package/src/components/MBodyMap.vue +266 -0
- package/src/components/MCandlestickChart.vue +479 -0
- package/src/components/MCertificate.vue +351 -0
- package/src/components/MCountdown.vue +200 -0
- package/src/components/MCreditCardInput.vue +351 -0
- package/src/components/MMortgageCalculator.vue +258 -0
- package/src/components/MOdontogram.vue +462 -0
- package/src/components/MOrderBook.vue +287 -0
- package/src/components/MOrderTicket.vue +217 -0
- package/src/components/MPosKeypad.vue +406 -0
- package/src/components/MProductConfigurator.vue +412 -0
- package/src/components/MQuiz.vue +531 -0
- package/src/components/MReceipt.vue +249 -0
- package/src/components/MSeatMap.vue +431 -0
- package/src/components/MSelect.vue +2 -2
- package/src/components/MTicket.vue +209 -0
- package/src/components/MVitalsChart.vue +303 -0
- package/src/composables/_printElement.ts +36 -0
- package/src/composables/cardBrand.ts +104 -0
- package/src/composables/mortgage.ts +70 -0
- package/src/composables/useLocale.ts +277 -0
- package/src/index.ts +37 -0
- package/src/locales/de.ts +131 -0
- package/src/locales/es.ts +131 -0
- package/src/locales/fr.ts +131 -0
- package/src/locales/ja.ts +131 -0
- package/src/locales/ko.ts +131 -0
- package/src/locales/pt.ts +131 -0
- package/src/locales/zh.ts +131 -0
- package/dist/useLocale-D2ucaY-l.js.map +0 -1
package/dist/API.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# @m3ui-vue/m3ui-vue 1.
|
|
1
|
+
# @m3ui-vue/m3ui-vue 1.4.1 — API reference
|
|
2
2
|
|
|
3
3
|
Material Design 3 components for Vue 3 + Tailwind CSS v4. Generated from the source by
|
|
4
4
|
`scripts/generate-api.mjs`; full docs with live demos at https://m3ui.dev.
|
|
@@ -232,9 +232,49 @@ Props:
|
|
|
232
232
|
- `debounce?: number = 0` — Delay (ms) before filtering and firing @debounced. Selection is always instant
|
|
233
233
|
|
|
234
234
|
Events:
|
|
235
|
-
- `update:modelValue(unknown)` — Emitted on selection — powers v-model
|
|
235
|
+
- `update:modelValue(unknown)` — Emitted on selection — powers v-model (`null` when the clear button empties it)
|
|
236
236
|
- `debounced(string)` — Emitted debounce ms after the user stops typing the search query (only when debounce > 0)
|
|
237
237
|
|
|
238
|
+
### MAvailabilityCalendar
|
|
239
|
+
|
|
240
|
+
A booking calendar for stays (hotel, cabin, apartment, equipment rental): picks a check-in and a check-out night with the price of each night under its day, booked nights blocked, and a minimum / maximum stay. Once a check-in is chosen, only the days that make a valid stay stay pickable: a stay can't run over a booked night, but it can check out on the morning a booked night starts. Dates are `YYYY-MM-DD` strings in local time; each date's price and availability are those of the night that starts on it.
|
|
241
|
+
|
|
242
|
+
Props:
|
|
243
|
+
- `modelValue?: Range = [null, null]` (v-model) — `[checkIn, checkOut]` as `YYYY-MM-DD` (v-model)
|
|
244
|
+
- `prices?: Record<string, number> | ((date: string) => number)` — Price of the night starting on each date: a map or a function
|
|
245
|
+
- `unavailable?: string[] | ((date: string) => boolean)` — Nights already booked or closed: a list of dates or a function
|
|
246
|
+
- `minNights?: number = 1` — Shortest stay, in nights
|
|
247
|
+
- `maxNights?: number` — Longest stay, in nights
|
|
248
|
+
- `min?: string` — First bookable date. Defaults to today
|
|
249
|
+
- `max?: string` — Last bookable night
|
|
250
|
+
- `months?: number = 2` — Months shown side by side (they wrap on narrow screens)
|
|
251
|
+
- `firstDayOfWeek?: number` — 0 = Sunday … 6 = Saturday. Defaults to the locale's first day of the week
|
|
252
|
+
- `currency?: string` — ISO 4217 code to format prices
|
|
253
|
+
- `highlightDeals?: boolean = false` — Colors the cheapest quarter of the nights shown as deals
|
|
254
|
+
- `hideFooter?: boolean = false` — Hides the summary under the months
|
|
255
|
+
- `disabled?: boolean = false`
|
|
256
|
+
|
|
257
|
+
Events:
|
|
258
|
+
- `update:modelValue(Range)` — `[checkIn, checkOut]`, either one `null` — powers v-model
|
|
259
|
+
- `change({ start: string; end: string; nights: number; total: number; })` — Emitted when a stay is complete: `{ start, end, nights, total }`
|
|
260
|
+
|
|
261
|
+
Slots:
|
|
262
|
+
- `#day { date: string; day: number; price: number | undefined; state: DayState; }` — Replaces a day's content (the button stays). Slot props: `{ date, day, price, state }`
|
|
263
|
+
- `#footer { start: string | null; end: string | null; nights: number; total: number; clear: () => void; }` — Replaces the summary under the months. Slot props: `{ start, end, nights, total, clear }`
|
|
264
|
+
|
|
265
|
+
Exposed (template ref):
|
|
266
|
+
- `nights: number`
|
|
267
|
+
- `total: number`
|
|
268
|
+
- `clear: () => void`
|
|
269
|
+
|
|
270
|
+
```ts
|
|
271
|
+
type Range = [string | null, string | null]
|
|
272
|
+
```
|
|
273
|
+
|
|
274
|
+
```ts
|
|
275
|
+
type DayState = 'start' | 'end' | 'range' | 'preview' | 'booked' | 'disabled' | 'available' | 'checkout-only'
|
|
276
|
+
```
|
|
277
|
+
|
|
238
278
|
### MAvatar
|
|
239
279
|
|
|
240
280
|
A circular initials avatar. There's no image-source prop — it always renders extracted initials or a fallback string, never a photo.
|
|
@@ -316,6 +356,74 @@ Props:
|
|
|
316
356
|
Slots:
|
|
317
357
|
- `#error` — Shown instead of the SVG when value is invalid for the given format (e.g. a non-numeric EAN13)
|
|
318
358
|
|
|
359
|
+
### MBeforeAfter
|
|
360
|
+
|
|
361
|
+
Compares two images (or any two pieces of content) stacked on top of each other, split by a handle the user drags: a renovation, a photo edit, a redesign. Clicking anywhere moves the split there; the handle is a slider for the keyboard (arrows, Page Up/Down, Home/End). The root has no size of its own beyond the images: give it a width (and an `aspectRatio`, or a height through `class`) to make it a fixed box.
|
|
362
|
+
|
|
363
|
+
Props:
|
|
364
|
+
- `modelValue?: number` (v-model) — Split position as a percentage (v-model). Without v-model the component keeps its own, starting here
|
|
365
|
+
- `before?: string` — Image URL of the "before" side (left, or top when vertical)
|
|
366
|
+
- `after?: string` — Image URL of the "after" side (right, or bottom when vertical)
|
|
367
|
+
- `beforeAlt?: string` — Alt text of the "before" image
|
|
368
|
+
- `afterAlt?: string` — Alt text of the "after" image
|
|
369
|
+
- `beforeLabel?: string` — Label chip on the "before" side. Defaults to the locale's "Before"; pass an empty string to hide it
|
|
370
|
+
- `afterLabel?: string` — Label chip on the "after" side. Defaults to the locale's "After"; pass an empty string to hide it
|
|
371
|
+
- `orientation?: "horizontal" | "vertical" = "horizontal"` — Direction the divider moves in
|
|
372
|
+
- `hover?: boolean = false` — Moves the split with the pointer on hover, without pressing (mouse only; touch still drags)
|
|
373
|
+
- `aspectRatio?: string` — CSS aspect-ratio of the box, e.g. "16 / 9". Unset sizes to the "after" content
|
|
374
|
+
- `hideHandle?: boolean = false` — Hides the round grip, leaving only the divider line
|
|
375
|
+
- `step?: number = 1` — Percentage moved by an arrow key (Page Up/Down move 10×)
|
|
376
|
+
- `disabled?: boolean = false` — Disables dragging and the keyboard
|
|
377
|
+
|
|
378
|
+
Events:
|
|
379
|
+
- `update:modelValue(number)` — Emitted while dragging or stepping with the keyboard — powers v-model (0–100)
|
|
380
|
+
- `change(number)` — Emitted once when a drag or a key press ends, with the final position
|
|
381
|
+
|
|
382
|
+
Slots:
|
|
383
|
+
- `#after` — Content of the "after" side, replacing the `after` image
|
|
384
|
+
- `#before` — Content of the "before" side, replacing the `before` image
|
|
385
|
+
- `#handle { position: number; dragging: boolean; }` — Replaces the round grip in the middle of the divider. Slot props: `{ position, dragging }`
|
|
386
|
+
|
|
387
|
+
### MBodyMap
|
|
388
|
+
|
|
389
|
+
A body silhouette, front and back, with regions to mark: where it hurts, an injury, a rash, a tattoo, the site of an injection. Each tap moves a region one level up (with `levels` > 1, e.g. mild → moderate → severe) and back to unmarked. Sides are the patient's: on the front view their right is on the viewer's left. Region ids: `head`, `neck`, `chest-right`, `abdomen`, `pelvis`, `shoulder-left`, `upper-arm-right`, `forearm-left`, `hand-right`, `thigh-left`, `knee-right`, `leg-left`, `foot-right`; on the back view the same prefixed with `back-` (`back-head`, `back-shoulder-left`…) plus `back-upper-back-right`, `back-lower-back`, `back-glute-left`, `back-calf-right`.
|
|
390
|
+
|
|
391
|
+
Props:
|
|
392
|
+
- `modelValue?: BodyMapValue = {}` (v-model) — Marked regions: id → level (v-model)
|
|
393
|
+
- `levels?: number = 1` — Levels a region cycles through. 1 = a plain on/off selection
|
|
394
|
+
- `levelColors?: string[]` — Color of each level (any CSS color). Defaults to a ramp from the error container to the error color
|
|
395
|
+
- `levelLabels?: string[]` — Names of the levels, shown in the legend, e.g. ['Mild', 'Moderate', 'Severe']
|
|
396
|
+
- `view?: "both" | "front" | "back" = "both"` — Which side(s) of the body to draw
|
|
397
|
+
- `disabledRegions?: string[] = []` — Region ids that can't be marked
|
|
398
|
+
- `readonly?: boolean = false` — Shows the marks but doesn't change them
|
|
399
|
+
|
|
400
|
+
Events:
|
|
401
|
+
- `update:modelValue(BodyMapValue)` — The marked regions — powers v-model
|
|
402
|
+
- `select(BodyRegion & { level: number; })` — A region changed: `{ id, label, view, level }` (level 0 = cleared)
|
|
403
|
+
|
|
404
|
+
Slots:
|
|
405
|
+
- `#legend { levels: number; colors: string[]; labels: string[] | undefined; }` — Replaces the levels legend. Slot props: `{ levels, colors, labels }`
|
|
406
|
+
|
|
407
|
+
```ts
|
|
408
|
+
/** Marked regions of an `MBodyMap`: region id → level (1…levels). Regions not in the record are unmarked. */
|
|
409
|
+
export type BodyMapValue = Record<string, number>
|
|
410
|
+
```
|
|
411
|
+
|
|
412
|
+
```ts
|
|
413
|
+
/** A region of the body map, as passed to `select` and the `region` slot. */
|
|
414
|
+
export interface BodyRegion {
|
|
415
|
+
/** e.g. "head", "shoulder-right", "back-calf-left" */
|
|
416
|
+
id: string
|
|
417
|
+
/** Translated name, e.g. "Shoulder, right" */
|
|
418
|
+
label: string
|
|
419
|
+
view: 'front' | 'back'
|
|
420
|
+
}
|
|
421
|
+
```
|
|
422
|
+
|
|
423
|
+
```ts
|
|
424
|
+
interface Region extends BodyRegion { shape: Shape }
|
|
425
|
+
```
|
|
426
|
+
|
|
319
427
|
### MBottomAppBar
|
|
320
428
|
|
|
321
429
|
M3's bottom app bar (a port of Compose's `BottomAppBar`): navigation and key actions at the bottom of small screens, with an optional FAB at the end. With `flexible` it's M3 Expressive's `FlexibleBottomAppBar`, a shorter bar whose actions spread across it. With `scrollBehavior="exit-always"` it collapses as the content scrolls down and comes back as it scrolls up.
|
|
@@ -483,6 +591,44 @@ export interface CalendarEvent {
|
|
|
483
591
|
}
|
|
484
592
|
```
|
|
485
593
|
|
|
594
|
+
### MCandlestickChart
|
|
595
|
+
|
|
596
|
+
A candlestick (OHLC) chart for prices: stocks, crypto, commodities, an exchange rate. Drawn in plain SVG with no chart library: candles, volume bars, moving averages, the last-price line and a crosshair with the candle's open / high / low / close. Drag (or swipe) to pan through history, Ctrl + wheel (or a trackpad / two-finger pinch) to zoom; the arrow keys move the crosshair. Appending candles keeps the chart pinned to the latest one while it's in view, so it can be fed live.
|
|
597
|
+
|
|
598
|
+
Props:
|
|
599
|
+
- `data: Candle[]` — Candles, oldest first
|
|
600
|
+
- `height?: number = 320` — Height in px
|
|
601
|
+
- `volume?: boolean = true` — Volume bars under the candles (when the data has volume)
|
|
602
|
+
- `movingAverages?: number[] = []` — Periods of simple moving averages to draw over the candles, e.g. [20, 50]
|
|
603
|
+
- `visible?: number = 60` — Candles visible at first (the latest ones)
|
|
604
|
+
- `upColor?: string = "var(--color-success)"` — Color of rising candles (any CSS color)
|
|
605
|
+
- `downColor?: string = "var(--color-error)"` — Color of falling candles (any CSS color)
|
|
606
|
+
- `decimals?: number = 2` — Decimals of prices
|
|
607
|
+
- `currency?: string` — ISO 4217 code to format prices as money
|
|
608
|
+
- `lastPrice?: boolean = true` — Draws the dashed line at the last close
|
|
609
|
+
|
|
610
|
+
Events:
|
|
611
|
+
- `hover(Candle | null)` — The candle under the crosshair, or null when it leaves
|
|
612
|
+
|
|
613
|
+
Slots:
|
|
614
|
+
- `#legend { candle: Candle | undefined; change: number; changePercent: number; }` — Replaces the O/H/L/C legend. Slot props: `{ candle, change, changePercent }`
|
|
615
|
+
|
|
616
|
+
Exposed (template ref):
|
|
617
|
+
- `reset: () => void` — Shows the latest candles again
|
|
618
|
+
|
|
619
|
+
```ts
|
|
620
|
+
/** One period of an `MCandlestickChart`. */
|
|
621
|
+
export interface Candle {
|
|
622
|
+
/** Start of the period (Date, ISO string or epoch ms) */
|
|
623
|
+
time: Date | string | number
|
|
624
|
+
open: number
|
|
625
|
+
high: number
|
|
626
|
+
low: number
|
|
627
|
+
close: number
|
|
628
|
+
volume?: number
|
|
629
|
+
}
|
|
630
|
+
```
|
|
631
|
+
|
|
486
632
|
### MCard
|
|
487
633
|
|
|
488
634
|
A flexible surface for grouping related content — three variants following the M3 elevation system, with optional header image, structured title/subtitle, and action buttons.
|
|
@@ -556,6 +702,43 @@ Props:
|
|
|
556
702
|
Slots:
|
|
557
703
|
- `#default` — Content, centered.
|
|
558
704
|
|
|
705
|
+
### MCertificate
|
|
706
|
+
|
|
707
|
+
A printable certificate or diploma: a course completion, an award, a training, a membership. It keeps an A4 shape at any width and scales its type with it, so the same component works as a thumbnail, on screen and on paper; `print()` prints just the certificate on an A4 page. Three looks: `classic` (double frame and serif type), `modern` (a colored band) and `minimal`.
|
|
708
|
+
|
|
709
|
+
Props:
|
|
710
|
+
- `recipient: string` — Who receives it
|
|
711
|
+
- `title?: string` — Big title. Defaults to the locale's "Certificate of completion"
|
|
712
|
+
- `presentedTo?: string` — Line before the name. Defaults to the locale's "This certifies that"
|
|
713
|
+
- `description?: string` — What it is for, e.g. "has completed the course Vue 3 Fundamentals (24 hours)"
|
|
714
|
+
- `issuer?: string` — Name of the issuing organization
|
|
715
|
+
- `date?: string | number | Date` — Date it was awarded (Date, ISO string or epoch ms)
|
|
716
|
+
- `code?: string` — Certificate number or verification code
|
|
717
|
+
- `signatures?: CertificateSignature[] = []`
|
|
718
|
+
- `variant?: "classic" | "modern" | "minimal" = "classic"` — Look of the certificate
|
|
719
|
+
- `color?: string = "primary"` — Accent color: a role (primary, secondary, tertiary, error, success) or any CSS color
|
|
720
|
+
- `seal?: string | false = "workspace_premium"` — Material Symbol in the seal; `false` hides the seal
|
|
721
|
+
- `orientation?: "landscape" | "portrait" = "landscape"`
|
|
722
|
+
|
|
723
|
+
Slots:
|
|
724
|
+
- `#logo` — The issuer's logo, at the top
|
|
725
|
+
- `#default` — Extra content under the description (grades, hours, a QR to verify)
|
|
726
|
+
- `#seal` — Replaces the seal (a rosette with an icon)
|
|
727
|
+
|
|
728
|
+
Exposed (template ref):
|
|
729
|
+
- `print: () => void`
|
|
730
|
+
|
|
731
|
+
```ts
|
|
732
|
+
/** A signature line of an `MCertificate`. */
|
|
733
|
+
export interface CertificateSignature {
|
|
734
|
+
name: string
|
|
735
|
+
/** e.g. "Course director" */
|
|
736
|
+
role?: string
|
|
737
|
+
/** Image of the signature (a URL or a data URL, e.g. from MSignaturePad), drawn over the line */
|
|
738
|
+
image?: string
|
|
739
|
+
}
|
|
740
|
+
```
|
|
741
|
+
|
|
559
742
|
### MChart
|
|
560
743
|
|
|
561
744
|
Import from `@m3ui-vue/m3ui-vue/chart`.
|
|
@@ -837,6 +1020,89 @@ Events:
|
|
|
837
1020
|
- `error(unknown)` — Emitted if the browser refuses the clipboard write
|
|
838
1021
|
- `copied(string)` — Emitted with the copied value after a successful clipboard write
|
|
839
1022
|
|
|
1023
|
+
### MCountdown
|
|
1024
|
+
|
|
1025
|
+
MCountdown — a countdown to a date: days, hours, minutes and seconds with rolling digits, in boxes or inline. Unit names come from `Intl` in the app's language. Units left out of `units` fold into the next larger one shown (no `days` → 50 hours). Ticks on the second boundary; every tick costs one timer, not one per digit.
|
|
1026
|
+
|
|
1027
|
+
Props:
|
|
1028
|
+
- `to: string | number | Date` — The moment it counts down to: a `Date`, a timestamp in ms, or a date string
|
|
1029
|
+
- `units?: CountdownUnit[] = ["days", "hours", "minutes", "seconds"]` — Units shown, largest first; leaving one out folds it into the next larger one
|
|
1030
|
+
- `variant?: "inline" | "boxes" = "boxes"` — `boxes`: each unit in its own container with its name below; `inline`: one line of text (3d 04h 12m)
|
|
1031
|
+
- `size?: "sm" | "md" | "lg" = "md"` — Digit size
|
|
1032
|
+
- `labels?: boolean = true` — Show unit names
|
|
1033
|
+
- `hideEmpty?: boolean = false` — Hide leading units while they're zero (no "0 days" a few hours before)
|
|
1034
|
+
- `animate?: boolean = true` — Roll the digits; false (or the system's reduced motion) swaps them
|
|
1035
|
+
- `locale?: string` — BCP-47 language for the unit names; defaults to the app's locale
|
|
1036
|
+
|
|
1037
|
+
Events:
|
|
1038
|
+
- `finished()` — Emitted once when the countdown reaches zero (not on mount if `to` is already past)
|
|
1039
|
+
- `tick(CountdownParts)` — Emitted every second with the `CountdownParts`
|
|
1040
|
+
|
|
1041
|
+
Slots:
|
|
1042
|
+
- `#finished` — Shown instead of the countdown once it reaches zero
|
|
1043
|
+
- `#default { days: number; hours: number; minutes: number; seconds: number; total: number; finished: boolean; }` — Replaces the whole rendering; receives `CountdownParts` (`days`, `hours`, `minutes`, `seconds`, `total`, `finished`)
|
|
1044
|
+
|
|
1045
|
+
Exposed (template ref):
|
|
1046
|
+
- `parts: CountdownParts`
|
|
1047
|
+
|
|
1048
|
+
```ts
|
|
1049
|
+
export type CountdownUnit = 'days' | 'hours' | 'minutes' | 'seconds'
|
|
1050
|
+
```
|
|
1051
|
+
|
|
1052
|
+
```ts
|
|
1053
|
+
/** What the default slot receives: the time left, split into the units shown */
|
|
1054
|
+
export interface CountdownParts {
|
|
1055
|
+
days: number
|
|
1056
|
+
hours: number
|
|
1057
|
+
minutes: number
|
|
1058
|
+
seconds: number
|
|
1059
|
+
/** Milliseconds left (0 once finished) */
|
|
1060
|
+
total: number
|
|
1061
|
+
finished: boolean
|
|
1062
|
+
}
|
|
1063
|
+
```
|
|
1064
|
+
|
|
1065
|
+
### MCreditCardInput
|
|
1066
|
+
|
|
1067
|
+
Card payment fields: number, expiry, security code and optionally the cardholder's name, with a live card preview that turns over while the security code is typed. The number is grouped as its network prints it (4-6-5 for American Express), the network is detected from the first digits, and every field is checked (length, Luhn checksum, a future expiry, the code's length for that network). It only collects and checks what is typed: it doesn't tokenize or send anything. Hand the value to your payment provider's SDK.
|
|
1068
|
+
|
|
1069
|
+
Props:
|
|
1070
|
+
- `modelValue: CreditCardValue` (v-model) — Card value (v-model)
|
|
1071
|
+
- `preview?: boolean = true` — Shows the card preview above the fields
|
|
1072
|
+
- `showName?: boolean = false` — Adds the "Name on card" field
|
|
1073
|
+
- `variant?: "filled" | "outlined" = "filled"` — Visual style of the fields
|
|
1074
|
+
- `autoAdvance?: boolean = true` — Moves focus to the next field once one is complete and valid
|
|
1075
|
+
- `errors?: Partial<Record<CreditCardField, string>>` — Error messages to show regardless of the built-in checks, e.g. a decline from the server
|
|
1076
|
+
- `disabled?: boolean = false` — Disables every field
|
|
1077
|
+
|
|
1078
|
+
Events:
|
|
1079
|
+
- `update:modelValue(CreditCardValue)` — Emitted on every change — powers v-model
|
|
1080
|
+
- `complete(CreditCardValue)` — Emitted when every field becomes valid, with the value
|
|
1081
|
+
- `brand(CardBrand)` — Emitted when the detected network changes
|
|
1082
|
+
|
|
1083
|
+
Slots:
|
|
1084
|
+
- `#brand { brand: CardBrand; name: string; }` — Replaces the network wordmark on the preview. Slot props: `{ brand, name }`
|
|
1085
|
+
|
|
1086
|
+
Exposed (template ref):
|
|
1087
|
+
- `brand: CardBrand` — Detected card network
|
|
1088
|
+
- `valid: boolean` — Whether every field is valid
|
|
1089
|
+
- `validate: () => boolean` — Shows the errors of every field (as if each had been visited) and returns whether all are valid
|
|
1090
|
+
- `focus: (field?: CreditCardField) => void | undefined` — Focuses a field (the number by default)
|
|
1091
|
+
|
|
1092
|
+
```ts
|
|
1093
|
+
/** Value of `MCreditCardInput` (v-model). `number` holds digits only; `expiry` is `MM/YY`. */
|
|
1094
|
+
export interface CreditCardValue {
|
|
1095
|
+
number: string
|
|
1096
|
+
expiry: string
|
|
1097
|
+
cvc: string
|
|
1098
|
+
name?: string
|
|
1099
|
+
}
|
|
1100
|
+
```
|
|
1101
|
+
|
|
1102
|
+
```ts
|
|
1103
|
+
export type CreditCardField = 'number' | 'expiry' | 'cvc' | 'name'
|
|
1104
|
+
```
|
|
1105
|
+
|
|
840
1106
|
### MDataTable
|
|
841
1107
|
|
|
842
1108
|
A feature-rich data table — everything MTable has, plus column resize/pin/toggle, row grouping, striped/dense density, sticky header, expandable rows, and CSV export.
|
|
@@ -1102,6 +1368,7 @@ Props:
|
|
|
1102
1368
|
|
|
1103
1369
|
Events:
|
|
1104
1370
|
- `update:modelValue(value: DrawItem[])`
|
|
1371
|
+
- `change(items: DrawItem[])` — Fires after every edit with the new items (the same as `update:modelValue`)
|
|
1105
1372
|
- `update:tool(value: DrawTool)`
|
|
1106
1373
|
- `update:color(value: string)`
|
|
1107
1374
|
- `update:size(value: number)`
|
|
@@ -1111,7 +1378,6 @@ Events:
|
|
|
1111
1378
|
- `update:pages(value: number)`
|
|
1112
1379
|
- `update:selection(value: string[])`
|
|
1113
1380
|
- `update:viewport(value: { x: number; y: number; zoom: number; })`
|
|
1114
|
-
- `change(items: DrawItem[])` — Fires after every edit with the new items (the same as `update:modelValue`)
|
|
1115
1381
|
|
|
1116
1382
|
Slots:
|
|
1117
1383
|
- `#default` — Overlays: a toolbar (MDrawToolbar), a layers panel (MDrawLayers), anything positioned over the canvas
|
|
@@ -1263,7 +1529,7 @@ Props:
|
|
|
1263
1529
|
- `direction?: "right" | "left" | "up" | "down" | "radial" = "up"` — Speed-dial expand direction
|
|
1264
1530
|
- `to?: string | Record<string, any>` — Vue Router destination — renders as RouterLink instead of button
|
|
1265
1531
|
- `persistent?: boolean = false` — Keep speed-dial open after clicking an item or clicking outside
|
|
1266
|
-
- `align?: "
|
|
1532
|
+
- `align?: "end" | "start" = "start"` — For the `up`/`down` #content panel only: which edge it anchors to when it's wider than the FAB itself. 'start' (default) keeps its left edge aligned with the FAB's left edge (existing behavior); 'end' aligns the right edges instead, which keeps a wide panel from running off-screen when the FAB sits in the bottom-right corner, a common placement.
|
|
1267
1533
|
- `scrim?: boolean = false` — Dims the rest of the screen behind the #content panel while open (has no effect on the `items` speed dial). A plain sibling with its own fade transition, independent of the panel's enter/leave transform, so it doesn't visually shrink/lag along with it.
|
|
1268
1534
|
- `contentTransition?: "none" | "scale" | "fade" = "scale"` — How the #content panel itself animates open/closed. 'scale' (default) is the original fade+scale. 'fade' drops the scale — use this when the slot content already animates its own entrance (e.g. a staggered per-item reveal), so the panel doesn't *also* scale as a group on top of that; it still gives Vue a real transition to wait for on close, so the content's own leave animation has time to play instead of just vanishing. 'none' skips any panel-level transition entirely.
|
|
1269
1535
|
- `rippleColor?: string` — Any CSS color for the press ripple; defaults to the FAB's content color
|
|
@@ -1295,7 +1561,7 @@ Props:
|
|
|
1295
1561
|
- `size?: "small" | "large" | "regular" = "regular"` — Trigger FAB size — independent from `itemSize` below.
|
|
1296
1562
|
- `itemSize?: "small" | "large" | "regular" = "large"` — Menu item row size — independent from the trigger FAB's own `size`.
|
|
1297
1563
|
- `direction?: "up" | "down" = "up"` — Which side of the FAB the menu list opens toward
|
|
1298
|
-
- `align?: "
|
|
1564
|
+
- `align?: "end" | "start" = "end"` — Which edge the (usually wider-than-the-FAB) menu list anchors to — 'end' keeps it from running off-screen when the FAB sits in a bottom-right corner
|
|
1299
1565
|
- `scrim?: boolean = true` — Dim the rest of the screen while the menu is open
|
|
1300
1566
|
- `persistent?: boolean = false` — Keep the menu open after clicking an item or clicking outside
|
|
1301
1567
|
- `disabled?: boolean = false` — Disables the trigger FAB
|
|
@@ -1375,8 +1641,8 @@ A thin, prop-driven wrapper around CSS flexbox — direction, alignment, justifi
|
|
|
1375
1641
|
|
|
1376
1642
|
Props:
|
|
1377
1643
|
- `direction?: "row" | "column" | "row-reverse" | "column-reverse" = "row"` — Flex direction
|
|
1378
|
-
- `align?: "center" | "
|
|
1379
|
-
- `justify?: "center" | "
|
|
1644
|
+
- `align?: "center" | "end" | "start" | "stretch" | "baseline" = "stretch"` — Cross-axis alignment (align-items)
|
|
1645
|
+
- `justify?: "center" | "end" | "start" | "between" | "around" | "evenly" = "start"` — Main-axis alignment (justify-content)
|
|
1380
1646
|
- `gap?: "none" | "xs" | "sm" | "md" | "lg" | "xl" = "none"` — Gap between items
|
|
1381
1647
|
- `wrap?: boolean = false` — Allow items to wrap
|
|
1382
1648
|
- `inline?: boolean = false` — Use inline-flex instead of flex
|
|
@@ -1814,7 +2080,7 @@ Props:
|
|
|
1814
2080
|
- `icon?: string` — Material Symbol
|
|
1815
2081
|
- `variant?: "elevated" | "filled" | "outlined" = "outlined"`
|
|
1816
2082
|
- `color?: "error" | "primary" | "secondary" | "tertiary" | "neutral" = "primary"` — The icon container's color role
|
|
1817
|
-
- `handles?: "
|
|
2083
|
+
- `handles?: "both" | "none" | "source" | "target" = "both"` — Which handles it draws
|
|
1818
2084
|
- `sourcePosition?: FlowPosition`
|
|
1819
2085
|
- `targetPosition?: FlowPosition`
|
|
1820
2086
|
|
|
@@ -1879,9 +2145,9 @@ Props:
|
|
|
1879
2145
|
|
|
1880
2146
|
Events:
|
|
1881
2147
|
- `link({ from: string; to: string; type: NonNullable<"FS" | "SS" | "FF" | "SF" | undefined>; })` — A dependency was drawn: `{ from, to, type }` (it's also added to the task)
|
|
2148
|
+
- `change({ tasks: GanttTask<any>[]; kind: "progress" | "reorder" | "move" | "resize" | "rename"; })` — A drag or a key changed tasks: `{ tasks, kind }` with the changed tasks and `'move' | 'resize' | 'progress' | 'reorder' | 'rename'`
|
|
1882
2149
|
- `delete({ tasks: GanttTask<any>[]; })` — Tasks were deleted: `{ tasks }`
|
|
1883
2150
|
- `update:selection(string[])`
|
|
1884
|
-
- `change({ tasks: GanttTask<any>[]; kind: "progress" | "reorder" | "move" | "resize" | "rename"; })` — A drag or a key changed tasks: `{ tasks, kind }` with the changed tasks and `'move' | 'resize' | 'progress' | 'reorder' | 'rename'`
|
|
1885
2151
|
- `update:tasks(GanttTask<any>[])`
|
|
1886
2152
|
- `update:scale(TimeUnit)`
|
|
1887
2153
|
- `update:collapsed(string[])`
|
|
@@ -1947,7 +2213,7 @@ Props:
|
|
|
1947
2213
|
- `lg?: 1 | 2 | 3 | 4 | 5 | 6 | 12` — Columns at lg breakpoint
|
|
1948
2214
|
- `xl?: 1 | 2 | 3 | 4 | 5 | 6 | 12` — Columns at xl breakpoint
|
|
1949
2215
|
- `gap?: "none" | "xs" | "sm" | "md" | "lg" | "xl" = "md"` — Gap between items
|
|
1950
|
-
- `alignItems?: "center" | "
|
|
2216
|
+
- `alignItems?: "center" | "end" | "start" | "stretch" = "stretch"` — Vertical alignment
|
|
1951
2217
|
|
|
1952
2218
|
Slots:
|
|
1953
2219
|
- `#default` — The grid items.
|
|
@@ -2707,6 +2973,45 @@ Slots:
|
|
|
2707
2973
|
- `#default` — Item label text.
|
|
2708
2974
|
- `#children` — Nested submenu items. In the parent MMenu's default 'flyout' mode, clicking or hovering (mouse only) the item opens a side panel — supports unlimited nesting depth. In 'push' mode, clicking the item instead swaps the whole menu panel to the submenu with a back header; hover does nothing.
|
|
2709
2975
|
|
|
2976
|
+
### MMortgageCalculator
|
|
2977
|
+
|
|
2978
|
+
A mortgage / loan calculator for a property listing or a bank: price, down payment, rate and term in, the monthly payment, the principal vs interest split and the yearly amortization schedule out. Supports the french system (the same payment every month) and the german one (the same principal every month, falling payments). The math is also exported on its own as `amortize()`.
|
|
2979
|
+
|
|
2980
|
+
Props:
|
|
2981
|
+
- `modelValue: MortgageInput` (v-model) — The inputs (v-model)
|
|
2982
|
+
- `system?: "french" | "german" = "french"` — `french`: fixed payment. `german`: fixed principal, payments fall over time
|
|
2983
|
+
- `terms?: number[] = [10, 15, 20, 25, 30]` — Terms offered, in years
|
|
2984
|
+
- `extras?: { label: string; amount: number; }[] = []` — Monthly costs added on top of the loan payment, e.g. property tax or insurance
|
|
2985
|
+
- `currency?: string` — ISO 4217 code to format amounts
|
|
2986
|
+
- `variant?: "filled" | "outlined" = "outlined"` — Fields layout: the default filled or outlined
|
|
2987
|
+
- `readonly?: boolean = false` — Hides the inputs, showing only the results (for a read-only quote)
|
|
2988
|
+
- `scheduleOpen?: boolean = false` — Shows the yearly schedule open
|
|
2989
|
+
|
|
2990
|
+
Events:
|
|
2991
|
+
- `update:modelValue(MortgageInput)` — The inputs — powers v-model
|
|
2992
|
+
|
|
2993
|
+
Slots:
|
|
2994
|
+
- `#summary { loan: number; monthly: number; schedule: Amortization; }` — Replaces the result panel. Slot props: `{ loan, monthly, schedule }`
|
|
2995
|
+
|
|
2996
|
+
Exposed (template ref):
|
|
2997
|
+
- `loan: number`
|
|
2998
|
+
- `monthly: number`
|
|
2999
|
+
- `schedule: Amortization`
|
|
3000
|
+
|
|
3001
|
+
```ts
|
|
3002
|
+
/** The inputs of an `MMortgageCalculator` (its v-model). */
|
|
3003
|
+
export interface MortgageInput {
|
|
3004
|
+
/** Price of the property */
|
|
3005
|
+
price: number
|
|
3006
|
+
/** Down payment, in money (not percent) */
|
|
3007
|
+
down: number
|
|
3008
|
+
/** Yearly interest rate, in percent */
|
|
3009
|
+
rate: number
|
|
3010
|
+
/** Term in years */
|
|
3011
|
+
years: number
|
|
3012
|
+
}
|
|
3013
|
+
```
|
|
3014
|
+
|
|
2710
3015
|
### MMultiAutocomplete
|
|
2711
3016
|
|
|
2712
3017
|
Multi-value autocomplete with inline search. Type to filter, Enter to toggle, Backspace to remove last chip.
|
|
@@ -2947,6 +3252,134 @@ Exposed (template ref):
|
|
|
2947
3252
|
- `blur: () => void | undefined` — Takes focus away from the field
|
|
2948
3253
|
- `select: () => void | undefined` — Selects all its text
|
|
2949
3254
|
|
|
3255
|
+
### MOdontogram
|
|
3256
|
+
|
|
3257
|
+
A dental chart: every tooth with its five surfaces (mesial, distal, buccal, lingual, occlusal) and whole-tooth conditions (missing, to extract, crown, root canal, implant). Pick a condition in the toolbar, then tap a surface or a tooth number to chart it; tapping again removes it. FDI or Universal numbering, permanent or primary teeth. Keyboard: each tooth is one tab stop; arrows move between teeth, M / D / B / L / O chart that surface with a surface condition, Enter charts a tooth condition, Delete clears the tooth.
|
|
3258
|
+
|
|
3259
|
+
Props:
|
|
3260
|
+
- `modelValue?: OdontogramValue = {}` (v-model) — The chart (v-model)
|
|
3261
|
+
- `tool?: string` (v-model:tool) — Condition picked in the toolbar, or "eraser" (v-model:tool)
|
|
3262
|
+
- `conditions?: OdontogramCondition[]` — Conditions offered. Defaults to caries, filling, sealant, crown, root canal, implant, missing and to extract
|
|
3263
|
+
- `numbering?: "fdi" | "universal" = "fdi"` — Tooth numbering: FDI two-digit (11–48) or Universal (1–32, A–T for primary teeth)
|
|
3264
|
+
- `dentition?: "primary" | "permanent" = "permanent"` — Adult (32) or primary (20) teeth
|
|
3265
|
+
- `hideToolbar?: boolean = false` — Hides the condition picker (e.g. when the app draws its own)
|
|
3266
|
+
- `readonly?: boolean = false` — Shows the chart but doesn't change it
|
|
3267
|
+
|
|
3268
|
+
Events:
|
|
3269
|
+
- `update:modelValue(OdontogramValue)` — The chart — powers v-model
|
|
3270
|
+
- `change({ tooth: string; surface?: ToothSurface | undefined; condition: string | null; })` — A tooth changed: `{ tooth, surface?, condition }` (condition null = cleared)
|
|
3271
|
+
- `update:tool(string)` — The condition picked — powers v-model:tool
|
|
3272
|
+
|
|
3273
|
+
Slots:
|
|
3274
|
+
- `#toolbar { conditions: OdontogramCondition[]; tool: string; setTool: (k: string) => void; }` — Replaces the condition picker. Slot props: `{ conditions, tool, setTool }`
|
|
3275
|
+
|
|
3276
|
+
```ts
|
|
3277
|
+
/** Teeth by number (in the chosen numbering) → their state. */
|
|
3278
|
+
export type OdontogramValue = Record<string, ToothState>
|
|
3279
|
+
```
|
|
3280
|
+
|
|
3281
|
+
```ts
|
|
3282
|
+
/**
|
|
3283
|
+
* Something to chart. `surface` conditions paint one face (caries, a filling); `tooth` conditions mark the whole
|
|
3284
|
+
* tooth. The built-in tooth keys `missing`, `extraction`, `crown`, `rootCanal` and `implant` get their own drawing;
|
|
3285
|
+
* any other tooth key outlines the tooth in its color.
|
|
3286
|
+
*/
|
|
3287
|
+
export interface OdontogramCondition {
|
|
3288
|
+
key: string
|
|
3289
|
+
label: string
|
|
3290
|
+
color: string
|
|
3291
|
+
scope: 'surface' | 'tooth'
|
|
3292
|
+
}
|
|
3293
|
+
```
|
|
3294
|
+
|
|
3295
|
+
```ts
|
|
3296
|
+
/** The chart of one tooth: a condition per surface, and conditions of the whole tooth. */
|
|
3297
|
+
export interface ToothState {
|
|
3298
|
+
surfaces?: Partial<Record<ToothSurface, string>>
|
|
3299
|
+
conditions?: string[]
|
|
3300
|
+
}
|
|
3301
|
+
```
|
|
3302
|
+
|
|
3303
|
+
```ts
|
|
3304
|
+
export type ToothSurface = 'mesial' | 'distal' | 'buccal' | 'lingual' | 'occlusal'
|
|
3305
|
+
```
|
|
3306
|
+
|
|
3307
|
+
```ts
|
|
3308
|
+
// ── teeth, in chart order (viewer's left to right) ──
|
|
3309
|
+
interface Tooth { fdi: number; label: string; upper: boolean; /** patient's right = viewer's left */ right: boolean }
|
|
3310
|
+
```
|
|
3311
|
+
|
|
3312
|
+
### MOrderBook
|
|
3313
|
+
|
|
3314
|
+
A live order book (market depth) for an exchange or trading screen: asks above, bids below (or side by side), each level with its size, the running total and a depth bar, and the last price and spread in the middle. Levels whose size changes flash; `step` groups levels into coarser price buckets. Clicking a level emits it, e.g. to fill an order form's price.
|
|
3315
|
+
|
|
3316
|
+
Props:
|
|
3317
|
+
- `bids: OrderBookLevel[]` — Buy orders, `[price, size]`, any order
|
|
3318
|
+
- `asks: OrderBookLevel[]` — Sell orders, `[price, size]`, any order
|
|
3319
|
+
- `levels?: number = 10` — Levels shown per side
|
|
3320
|
+
- `step?: number` — Groups prices into buckets of this size (bids round down, asks round up)
|
|
3321
|
+
- `decimals?: number` — Decimals of prices. Defaults to the decimals of `step`, or 2
|
|
3322
|
+
- `sizeDecimals?: number = 4` — Decimals of sizes
|
|
3323
|
+
- `lastPrice?: number` — Last traded price, shown between the sides; its arrow follows the previous value
|
|
3324
|
+
- `layout?: "split" | "stacked" = "stacked"` — Asks above bids, or bids and asks side by side
|
|
3325
|
+
- `flash?: boolean = true` — Flashes levels whose size changed
|
|
3326
|
+
- `bidColor?: string = "var(--color-success)"` — Color of bids (any CSS color)
|
|
3327
|
+
- `askColor?: string = "var(--color-error)"` — Color of asks (any CSS color)
|
|
3328
|
+
|
|
3329
|
+
Events:
|
|
3330
|
+
- `select({ price: number; size: number; side: "bid" | "ask"; })` — A level was clicked: `{ price, size, side }`
|
|
3331
|
+
|
|
3332
|
+
Slots:
|
|
3333
|
+
- `#middle { lastPrice: number | undefined; direction: "up" | "down" | null; spread: number | undefined; spreadPercent: number | undefined; }` — Replaces the last price / spread row. Slot props: `{ lastPrice, direction, spread, spreadPercent }`
|
|
3334
|
+
|
|
3335
|
+
```ts
|
|
3336
|
+
/** A price level of an `MOrderBook`: `[price, size]`. */
|
|
3337
|
+
export type OrderBookLevel = [price: number, size: number]
|
|
3338
|
+
```
|
|
3339
|
+
|
|
3340
|
+
### MOrderTicket
|
|
3341
|
+
|
|
3342
|
+
A kitchen ticket (comanda) for a kitchen display or an order queue: the order number, where it goes, how long it has been waiting (the header turns amber, then red, as it ages) and its lines with quantities, modifiers and notes. Tapping a line crosses it out as done; once every line is done `complete` fires. Every ticket on the page shares one clock.
|
|
3343
|
+
|
|
3344
|
+
Props:
|
|
3345
|
+
- `number: string | number` — Order number shown big in the header, e.g. 42 or "A-17"
|
|
3346
|
+
- `title?: string` — Where it goes, e.g. "Table 7", "Takeaway · Ana"
|
|
3347
|
+
- `icon?: string` — Material Symbol before the title, e.g. "restaurant", "takeout_dining", "two_wheeler"
|
|
3348
|
+
- `createdAt: string | number | Date` — When the order came in (Date, ISO string or epoch ms); drives the timer
|
|
3349
|
+
- `finishedAt?: string | number | Date` — When it was finished: freezes the timer at that moment
|
|
3350
|
+
- `items: OrderItem[]` — The order lines
|
|
3351
|
+
- `done?: (string | number)[] = []` (v-model:done) — Ids of the lines done (v-model:done)
|
|
3352
|
+
- `note?: string` — A note for the whole order
|
|
3353
|
+
- `warnAfter?: number = 10` — Minutes after which the header turns to the warning color
|
|
3354
|
+
- `lateAfter?: number = 20` — Minutes after which the header turns to the error color
|
|
3355
|
+
- `readonly?: boolean = false` — Read-only: lines can't be ticked
|
|
3356
|
+
|
|
3357
|
+
Events:
|
|
3358
|
+
- `complete()` — Emitted when the last line is marked done
|
|
3359
|
+
- `update:done((string | number)[])` — Emitted with the ids of the lines marked done — powers v-model:done
|
|
3360
|
+
|
|
3361
|
+
Slots:
|
|
3362
|
+
- `#header` — Extra content in the header, under the title (e.g. chips with the waiter or channel)
|
|
3363
|
+
- `#item { item: OrderItem; done: boolean; }` — Replaces a line's content (the tappable row stays). Slot props: `{ item, done }`
|
|
3364
|
+
- `#actions { allDone: boolean; elapsed: number; }` — Content at the bottom (e.g. bump / recall buttons). Slot props: `{ allDone, elapsed }`
|
|
3365
|
+
|
|
3366
|
+
```ts
|
|
3367
|
+
/** A line of an `MOrderTicket`. */
|
|
3368
|
+
export interface OrderItem {
|
|
3369
|
+
id: string | number
|
|
3370
|
+
name: string
|
|
3371
|
+
quantity?: number
|
|
3372
|
+
modifiers?: OrderModifier[]
|
|
3373
|
+
/** A free note for this line, e.g. "allergy: nuts" */
|
|
3374
|
+
note?: string
|
|
3375
|
+
}
|
|
3376
|
+
```
|
|
3377
|
+
|
|
3378
|
+
```ts
|
|
3379
|
+
/** A modifier on an order line: a plain string, or with a kind to style additions and removals. */
|
|
3380
|
+
export type OrderModifier = string | { label: string; kind?: 'add' | 'remove' | 'info' }
|
|
3381
|
+
```
|
|
3382
|
+
|
|
2950
3383
|
### MOverlay
|
|
2951
3384
|
|
|
2952
3385
|
Full-screen overlay with scrim and teleport to body. A generic low-level building block — content is entirely up to you via the default slot. Your class, role and aria attributes go on the content layer (over the scrim), so `class="flex items-center justify-center bg-black"` lays out and paints the slot.
|
|
@@ -3107,6 +3540,112 @@ Events:
|
|
|
3107
3540
|
- `update:modelValue(string)` — Emitted on every box change — powers v-model
|
|
3108
3541
|
- `complete(string)` — Fires once with the full code as soon as every box is filled — the natural place to trigger auto-submit
|
|
3109
3542
|
|
|
3543
|
+
### MPosKeypad
|
|
3544
|
+
|
|
3545
|
+
A large touch keypad for a point of sale, a kiosk or a cash drawer: amounts, quantities, a waiter's PIN. It shows the value formatted (with a currency when one is given), can enter amounts cash-register style (digits shift in from the right, `1` `2` `5` `0` → 12.50), offers quick-amount chips and, given the amount due, shows what's left to pay or the change to give back. Holding delete clears everything. With the keypad focused (or `keyboard="global"`), the physical keyboard works too: digits, `.`/`,`, Backspace, Escape to clear and Enter to submit. The value (v-model) is a plain decimal string ("12.50", or the digits of a PIN) so leading zeros survive.
|
|
3546
|
+
|
|
3547
|
+
Props:
|
|
3548
|
+
- `modelValue: string` (v-model) — Value (v-model): a decimal string like "12.50", or a digit string in `pin` mode
|
|
3549
|
+
- `mode?: "amount" | "integer" | "pin" = "amount"` — What is typed: `amount` (decimals, currency formatting), `integer` (quantities, no decimals) or `pin` (digits shown as dots, leading zeros kept)
|
|
3550
|
+
- `decimals?: number = 2` — Decimal places of an amount
|
|
3551
|
+
- `entry?: "shift" | "free" = "free"` — How an amount is entered: `free` (a decimal-point key) or `shift` (cash register: digits shift in from the right, with a `00` key instead of the point)
|
|
3552
|
+
- `currency?: string` — ISO 4217 code (e.g. "USD", "ARS") to format the amount as money. Unset shows a plain number
|
|
3553
|
+
- `max?: number` — Largest amount accepted; keys that would pass it are ignored
|
|
3554
|
+
- `maxLength?: number` — Most digits accepted (a PIN's length, for one). With `pin` mode, filling it emits `submit` on its own
|
|
3555
|
+
- `quickAmounts?: number[]` — Chips above the keys with preset amounts
|
|
3556
|
+
- `quickMode?: "set" | "add" = "set"` — Whether a quick amount replaces the value or adds to it
|
|
3557
|
+
- `due?: number` — Amount due: shows the remaining amount under the value, or the change once it's covered
|
|
3558
|
+
- `actionLabel?: string` — Label of the submit button. Without it (and without the `action` slot) there is no button
|
|
3559
|
+
- `actionIcon?: string` — Material Symbol on the submit button
|
|
3560
|
+
- `actionDisabled?: boolean` — Disables the submit button. By default it's disabled while the value is empty or doesn't cover `due`
|
|
3561
|
+
- `hideDisplay?: boolean = false` — Hides the value display (e.g. the value is shown elsewhere)
|
|
3562
|
+
- `keyboard?: "none" | "focus" | "global" = "focus"` — Physical keyboard: while the keypad is focused, always (`global`), or never
|
|
3563
|
+
- `haptics?: boolean = false` — A short vibration on every key, on devices that support it
|
|
3564
|
+
- `disabled?: boolean = false` — Disables every key
|
|
3565
|
+
|
|
3566
|
+
Events:
|
|
3567
|
+
- `update:modelValue(string)` — Emitted on every key — powers v-model
|
|
3568
|
+
- `key(string)` — Emitted on every key press, with the key (`'0'`–`'9'`, `'00'`, `'.'`, `'backspace'`, `'clear'`)
|
|
3569
|
+
- `submit(string)` — Emitted by the action button or Enter, with the value
|
|
3570
|
+
|
|
3571
|
+
Slots:
|
|
3572
|
+
- `#display { value: string; formatted: string; amount: number; }` — Replaces the value display. Slot props: `{ value, formatted, amount }`
|
|
3573
|
+
- `#action { value: string; amount: number; submit: () => void; }` — Replaces the submit button. Slot props: `{ value, amount, submit }`
|
|
3574
|
+
|
|
3575
|
+
### MProductConfigurator
|
|
3576
|
+
|
|
3577
|
+
Picks the variant and extras of a product with the price updating live: a size and color in a store, the doneness, sides and extras of a dish, the drinks of a combo. Groups are single choice, multiple choice (with min/max) or per-option quantities; `isAvailable` crosses out combinations that don't exist (a size out of stock in that color). The add button stays disabled until every group is satisfied.
|
|
3578
|
+
|
|
3579
|
+
Props:
|
|
3580
|
+
- `groups: ProductOptionGroup[]` — The option groups
|
|
3581
|
+
- `modelValue?: ProductSelection = {}` (v-model) — The selection (v-model), keyed by group key
|
|
3582
|
+
- `basePrice?: number = 0` — Price of the product before options
|
|
3583
|
+
- `quantity?: number | null = 1` (v-model:quantity) — Units of the product (v-model:quantity). Pass `null` to hide the quantity stepper
|
|
3584
|
+
- `maxQuantity?: number = 99` — Most units of the product
|
|
3585
|
+
- `currency?: string` — ISO 4217 code to format prices
|
|
3586
|
+
- `actionLabel?: string` — Label of the add button; without it there is no button
|
|
3587
|
+
- `isAvailable?: ((group: ProductOptionGroup, option: ProductOption, selection: ProductSelection) => boolean)` — Whether an option can be picked given the rest of the selection, e.g. a size out of stock in the chosen color. Unavailable options are crossed out and can't be picked
|
|
3588
|
+
- `disabled?: boolean = false`
|
|
3589
|
+
|
|
3590
|
+
Events:
|
|
3591
|
+
- `update:modelValue(ProductSelection)` — The selection, keyed by group key — powers v-model
|
|
3592
|
+
- `add({ selection: ProductSelection; quantity: number; unitPrice: number; total: number; })` — Emitted by the add button with `{ selection, quantity, unitPrice, total }`
|
|
3593
|
+
- `update:quantity(number)` — Units of the product — powers v-model:quantity
|
|
3594
|
+
|
|
3595
|
+
Slots:
|
|
3596
|
+
- `#header` — Content above the groups (the product's photo, name, description)
|
|
3597
|
+
- `#option { group: ProductOptionGroup; option: ProductOption; selected: boolean; available: boolean; }` — Replaces an option's label in list display. Slot props: `{ group, option, selected, available }`
|
|
3598
|
+
- `#action { valid: boolean; total: number; quantity: number; add: () => void; }` — Replaces the add button. Slot props: `{ valid, total, quantity, add }`
|
|
3599
|
+
|
|
3600
|
+
Exposed (template ref):
|
|
3601
|
+
- `valid: boolean`
|
|
3602
|
+
- `unitPrice: number`
|
|
3603
|
+
- `total: number`
|
|
3604
|
+
|
|
3605
|
+
```ts
|
|
3606
|
+
/** One choice in a `ProductOptionGroup`. */
|
|
3607
|
+
export interface ProductOption {
|
|
3608
|
+
value: string
|
|
3609
|
+
label: string
|
|
3610
|
+
/** Price added by this option (per unit; negative lowers it) */
|
|
3611
|
+
price?: number
|
|
3612
|
+
/** Swatch color for `display: 'swatches'` (any CSS color) */
|
|
3613
|
+
color?: string
|
|
3614
|
+
/** Swatch image for `display: 'swatches'` */
|
|
3615
|
+
image?: string
|
|
3616
|
+
/** A line under the label in list display */
|
|
3617
|
+
description?: string
|
|
3618
|
+
disabled?: boolean
|
|
3619
|
+
}
|
|
3620
|
+
```
|
|
3621
|
+
|
|
3622
|
+
```ts
|
|
3623
|
+
/**
|
|
3624
|
+
* A group of options of a product: a size, a color, extras, the sides of a combo.
|
|
3625
|
+
* - `single`: pick one (radio list, chips or swatches). Its value is a string.
|
|
3626
|
+
* - `multiple`: pick several, between `min` and `max` (checkbox list or chips). Its value is a string array.
|
|
3627
|
+
* - `quantity`: a count of each option, up to `max` in total (+/− rows). Its value is `{ [option]: count }`.
|
|
3628
|
+
*/
|
|
3629
|
+
export interface ProductOptionGroup {
|
|
3630
|
+
key: string
|
|
3631
|
+
label: string
|
|
3632
|
+
type?: 'single' | 'multiple' | 'quantity'
|
|
3633
|
+
/** How the options are drawn. Defaults to `list` (`chips` for sizes is a good fit, `swatches` for colors) */
|
|
3634
|
+
display?: 'list' | 'chips' | 'swatches'
|
|
3635
|
+
/** A single group must have a choice */
|
|
3636
|
+
required?: boolean
|
|
3637
|
+
/** Least selections / units in a multiple or quantity group */
|
|
3638
|
+
min?: number
|
|
3639
|
+
/** Most selections / units in a multiple or quantity group */
|
|
3640
|
+
max?: number
|
|
3641
|
+
options: ProductOption[]
|
|
3642
|
+
}
|
|
3643
|
+
```
|
|
3644
|
+
|
|
3645
|
+
```ts
|
|
3646
|
+
export type ProductSelection = Record<string, string | string[] | Record<string, number> | undefined>
|
|
3647
|
+
```
|
|
3648
|
+
|
|
3110
3649
|
### MProgressBar
|
|
3111
3650
|
|
|
3112
3651
|
A linear progress indicator — determinate, indeterminate, or the M3 Expressive wavy variant.
|
|
@@ -3161,6 +3700,71 @@ Props:
|
|
|
3161
3700
|
Slots:
|
|
3162
3701
|
- `#error` — Shown instead of the SVG when value is too large to encode at the given errorCorrectionLevel
|
|
3163
3702
|
|
|
3703
|
+
### MQuiz
|
|
3704
|
+
|
|
3705
|
+
A quiz for a course, an onboarding or a training: single and multiple choice, true/false, putting items in order and typed answers, one question at a time with a progress bar. With `feedback="immediate"` each answer is checked on the spot with its explanation; with `"end"` everything is revealed in the results. The results show the score, pass / fail against `passScore`, and a review of every question. An optional time limit ends the quiz when it runs out.
|
|
3706
|
+
|
|
3707
|
+
Props:
|
|
3708
|
+
- `questions: QuizQuestion[]`
|
|
3709
|
+
- `feedback?: "end" | "immediate" = "immediate"` — Check each answer right away, or only reveal them in the results
|
|
3710
|
+
- `shuffle?: boolean = false` — Shuffles the questions on every attempt
|
|
3711
|
+
- `shuffleOptions?: boolean = false` — Shuffles the options of choice questions
|
|
3712
|
+
- `passScore?: number` — Percent needed to pass, e.g. 70. Without it there's no pass / fail
|
|
3713
|
+
- `timeLimit?: number` — Time limit for the whole quiz, in seconds
|
|
3714
|
+
- `review?: boolean = true` — Lists every question with the given and the right answer in the results
|
|
3715
|
+
- `allowRetry?: boolean = true` — Offers to try again from the results
|
|
3716
|
+
|
|
3717
|
+
Events:
|
|
3718
|
+
- `finish(QuizResult)` — The quiz ended, with its `QuizResult`
|
|
3719
|
+
- `answer({ id: string | number; value: QuizAnswer | undefined; correct: boolean; })` — A question was answered (checked): `{ id, value, correct }`
|
|
3720
|
+
|
|
3721
|
+
Slots:
|
|
3722
|
+
- `#result { result: QuizResult; retry: () => void; }` — Replaces the results screen. Slot props: `{ result, retry }`
|
|
3723
|
+
|
|
3724
|
+
Exposed (template ref):
|
|
3725
|
+
- `restart: () => void`
|
|
3726
|
+
- `result: QuizResult`
|
|
3727
|
+
|
|
3728
|
+
```ts
|
|
3729
|
+
/**
|
|
3730
|
+
* A question of an `MQuiz`.
|
|
3731
|
+
* - `single`: `answer` is the index of the right option.
|
|
3732
|
+
* - `multiple`: `answer` is the indices of every right option (all of them, and only them, to score).
|
|
3733
|
+
* - `truefalse`: `answer` is a boolean.
|
|
3734
|
+
* - `order`: `options` are given in the right order; the quiz shuffles them.
|
|
3735
|
+
* - `text`: `answer` is the accepted answer(s); case, accents and extra spaces are ignored.
|
|
3736
|
+
*/
|
|
3737
|
+
export interface QuizQuestion {
|
|
3738
|
+
id: string | number
|
|
3739
|
+
type?: 'single' | 'multiple' | 'truefalse' | 'order' | 'text'
|
|
3740
|
+
prompt: string
|
|
3741
|
+
/** An image shown with the prompt */
|
|
3742
|
+
image?: string
|
|
3743
|
+
options?: string[]
|
|
3744
|
+
answer?: number | number[] | boolean | string | string[]
|
|
3745
|
+
/** Shown after answering: why the answer is what it is */
|
|
3746
|
+
explanation?: string
|
|
3747
|
+
/** Points the question is worth */
|
|
3748
|
+
points?: number
|
|
3749
|
+
}
|
|
3750
|
+
```
|
|
3751
|
+
|
|
3752
|
+
```ts
|
|
3753
|
+
export type QuizAnswer = number | number[] | boolean | string
|
|
3754
|
+
```
|
|
3755
|
+
|
|
3756
|
+
```ts
|
|
3757
|
+
/** The outcome of a finished quiz. */
|
|
3758
|
+
export interface QuizResult {
|
|
3759
|
+
score: number
|
|
3760
|
+
total: number
|
|
3761
|
+
percent: number
|
|
3762
|
+
/** Whether `percent` reached `passScore` (always true without one) */
|
|
3763
|
+
passed: boolean
|
|
3764
|
+
answers: Record<string, { value: QuizAnswer | undefined; correct: boolean }>
|
|
3765
|
+
}
|
|
3766
|
+
```
|
|
3767
|
+
|
|
3164
3768
|
### MRadio
|
|
3165
3769
|
|
|
3166
3770
|
A single radio button, for when you lay out the options yourself. It's selected when `modelValue` equals its `value`; for a plain list of options, MRadioGroup is simpler.
|
|
@@ -3215,6 +3819,63 @@ Props:
|
|
|
3215
3819
|
Events:
|
|
3216
3820
|
- `update:modelValue(number)` — Emitted when the user rates by click, drag or keyboard (v-model). Dragging past the first icon emits 0
|
|
3217
3821
|
|
|
3822
|
+
### MReceipt
|
|
3823
|
+
|
|
3824
|
+
A sales receipt in the look of a thermal printer ticket (58 or 80 mm): header, lines with quantity and amount, subtotal, discounts and taxes, total, payments and change. All the math is done in cents, so totals never drift. `print()` prints only the receipt, sized to the paper.
|
|
3825
|
+
|
|
3826
|
+
Props:
|
|
3827
|
+
- `items: ReceiptItem[]` — The lines sold
|
|
3828
|
+
- `adjustments?: ReceiptAdjustment[] = []` — Discounts, taxes, tips, fees, applied after the subtotal in this order
|
|
3829
|
+
- `payments?: ReceiptPayment[] = []` — Payments made; more than the total shows the change
|
|
3830
|
+
- `currency?: string` — ISO 4217 code, e.g. "USD". Without one, amounts are plain numbers
|
|
3831
|
+
- `number?: string | number` — Receipt / invoice number, shown under the header
|
|
3832
|
+
- `date?: string | number | Date` — Date of the sale (Date, ISO string or epoch ms)
|
|
3833
|
+
- `paper?: "auto" | "80mm" | "58mm" = "80mm"` — Paper width: 58 mm, 80 mm, or the width of the container
|
|
3834
|
+
- `edge?: "zigzag" | "straight" = "zigzag"` — Torn zigzag edges at the top and bottom, or straight
|
|
3835
|
+
- `footer?: string` — Text at the bottom when the `footer` slot isn't used
|
|
3836
|
+
|
|
3837
|
+
Slots:
|
|
3838
|
+
- `#header` — Top of the receipt: the store's logo, name, address, tax id
|
|
3839
|
+
- `#item { item: ReceiptItem; amount: number; }` — Replaces a line. Slot props: `{ item, amount }`
|
|
3840
|
+
- `#footer` — Bottom of the receipt: a thank-you line, a QR, return policy
|
|
3841
|
+
|
|
3842
|
+
Exposed (template ref):
|
|
3843
|
+
- `print: () => void`
|
|
3844
|
+
- `totals: { subtotal: number; total: number; paid: number; change: number; }` — Totals in the receipt's units (not cents)
|
|
3845
|
+
|
|
3846
|
+
```ts
|
|
3847
|
+
/** A line of an `MReceipt`. `price` is the unit price; the line amount is `price × quantity`. */
|
|
3848
|
+
export interface ReceiptItem {
|
|
3849
|
+
name: string
|
|
3850
|
+
quantity?: number
|
|
3851
|
+
price: number
|
|
3852
|
+
/** Extra text under the name, e.g. "No onion" or a SKU */
|
|
3853
|
+
note?: string
|
|
3854
|
+
}
|
|
3855
|
+
```
|
|
3856
|
+
|
|
3857
|
+
```ts
|
|
3858
|
+
/**
|
|
3859
|
+
* A line after the subtotal: a discount, a tax, a tip, a service fee. Give `amount` (negative for a discount) or
|
|
3860
|
+
* `percent` of the subtotal (negative for a discount). `included` marks a tax already inside the prices: it's
|
|
3861
|
+
* shown but not added again. Percentages apply to the running total, in the order given (put discounts first).
|
|
3862
|
+
*/
|
|
3863
|
+
export interface ReceiptAdjustment {
|
|
3864
|
+
label: string
|
|
3865
|
+
amount?: number
|
|
3866
|
+
percent?: number
|
|
3867
|
+
included?: boolean
|
|
3868
|
+
}
|
|
3869
|
+
```
|
|
3870
|
+
|
|
3871
|
+
```ts
|
|
3872
|
+
/** A payment toward the total, e.g. `{ method: 'Cash', amount: 50 }`. Paying more than the total shows the change. */
|
|
3873
|
+
export interface ReceiptPayment {
|
|
3874
|
+
method: string
|
|
3875
|
+
amount: number
|
|
3876
|
+
}
|
|
3877
|
+
```
|
|
3878
|
+
|
|
3218
3879
|
### MRelative
|
|
3219
3880
|
|
|
3220
3881
|
Wrapper that sets `position: relative` on a container. Use it as the positioning parent for MAbsolute children.
|
|
@@ -3262,9 +3923,9 @@ Props:
|
|
|
3262
3923
|
- `beforeDelete?: ((events: TimelineEvent<any>[]) => boolean | Promise<boolean>)`
|
|
3263
3924
|
|
|
3264
3925
|
Events:
|
|
3926
|
+
- `change({ events: TimelineEvent<any>[]; kind: "move" | "resize"; })` — A drag or a key changed bookings: `{ events, kind: 'move' | 'resize' }`
|
|
3265
3927
|
- `delete({ events: TimelineEvent<any>[]; })` — Bookings were deleted: `{ events }`
|
|
3266
3928
|
- `update:selection(string[])`
|
|
3267
|
-
- `change({ events: TimelineEvent<any>[]; kind: "move" | "resize"; })` — A drag or a key changed bookings: `{ events, kind: 'move' | 'resize' }`
|
|
3268
3929
|
- `update:scale(TimeUnit)`
|
|
3269
3930
|
- `update:collapsed(string[])`
|
|
3270
3931
|
- `update:events(TimelineEvent<any>[])`
|
|
@@ -3484,7 +4145,7 @@ Props:
|
|
|
3484
4145
|
- `placeholder?: string` — Defaults to the locale's "Search..."
|
|
3485
4146
|
- `variant?: "fullscreen" | "fullscreen-contained" | "docked" = "docked"` — 'docked' grows into a rounded panel anchored below the bar (default). 'fullscreen' takes over the whole viewport, matching M3's mobile search pattern — the leading icon becomes a back button either way. 'fullscreen-contained' (M3 Expressive's ExpandedFullScreenContainedSearchBar) also takes the whole viewport, on surface-container-low, but keeps the input in its pill shape, with no divider.
|
|
3486
4147
|
- `leadingIcon?: string = "search"` — Icon shown in the collapsed bar
|
|
3487
|
-
- `iconPosition?: "
|
|
4148
|
+
- `iconPosition?: "end" | "start" = "start"` — Which side of the *collapsed* bar the leading icon sits on. The expanded panel's back button always stays at the start regardless — that's a near-universal "go back" convention.
|
|
3488
4149
|
- `textAlign?: "center" | "start" = "start"` — Centers the input/placeholder text instead of the M3-standard start alignment (an iOS-style look some apps use for the collapsed bar).
|
|
3489
4150
|
- `loading?: boolean = false` — Shows a spinner in the expanded header instead of the clear button
|
|
3490
4151
|
- `clearable?: boolean = true` — Shows a clear (×) button once there is a query
|
|
@@ -3528,6 +4189,72 @@ Exposed (template ref):
|
|
|
3528
4189
|
- `focus: (options?: FocusOptions | undefined) => void | undefined` — Focuses the input
|
|
3529
4190
|
- `blur: () => void | undefined` — Takes focus away from the input
|
|
3530
4191
|
|
|
4192
|
+
### MSeatMap
|
|
4193
|
+
|
|
4194
|
+
Seat picker for a cinema, theater, stadium, bus or plane. The hall is drawn from rows of characters: each character is a seat of the category with that `key`, and `_` or a space leaves a gap (an aisle, or an empty row when the whole line is blank). Seats are named theater style (row letters, seat numbers: "F12") or plane style (row numbers, seat letters: "12C"), and those names are the ids used in v-model. Arrow keys move between seats, Enter/Space picks one. With `max: 1` picking another seat moves the selection.
|
|
4195
|
+
|
|
4196
|
+
Props:
|
|
4197
|
+
- `modelValue?: string[] = []` (v-model) — Ids of the selected seats (v-model)
|
|
4198
|
+
- `layout: string[]` — Rows of the hall, top to bottom. Each character is a seat of that category; `_` or a space is a gap
|
|
4199
|
+
- `categories?: SeatCategory[] = []` — Seat categories by layout character. Characters without one use a default "Standard" look
|
|
4200
|
+
- `occupied?: string[] = []` — Ids of seats already taken
|
|
4201
|
+
- `blocked?: string[] = []` — Ids of seats that can't be picked (out of service, kept free)
|
|
4202
|
+
- `naming?: "theater" | "plane" = "theater"` — Seat naming: row letters + seat numbers ("F12"), or row numbers + seat letters ("12C")
|
|
4203
|
+
- `rowLabels?: string[]` — Custom row labels, one per seat row (blank rows don't count)
|
|
4204
|
+
- `numbering?: "ltr" | "rtl" = "ltr"` — Seats are numbered from the left (`ltr`) or from the right (`rtl`) of each row
|
|
4205
|
+
- `max?: number` — Most seats that can be selected
|
|
4206
|
+
- `stage?: string | false` — Label of the screen/stage. Defaults to the locale's "Screen"; `false` hides it
|
|
4207
|
+
- `stagePosition?: "top" | "bottom" = "top"` — Side the screen/stage is drawn on
|
|
4208
|
+
- `seatSize?: number = 32` — Seat size in px
|
|
4209
|
+
- `showRowLabels?: boolean = true` — Shows row labels at both ends of each row
|
|
4210
|
+
- `legend?: boolean = true` — Shows the legend
|
|
4211
|
+
- `currency?: string` — ISO 4217 code to format prices (e.g. "USD"). Unset shows plain numbers
|
|
4212
|
+
- `disabled?: boolean = false` — Disables picking
|
|
4213
|
+
|
|
4214
|
+
Events:
|
|
4215
|
+
- `update:modelValue(string[])` — Emitted with the ids of the selected seats — powers v-model
|
|
4216
|
+
- `select(SeatInfo, boolean)` — Emitted when a seat is picked or released, with `(seat, selected)`
|
|
4217
|
+
- `limit()` — Emitted when a seat is picked while `max` seats are already selected
|
|
4218
|
+
|
|
4219
|
+
Slots:
|
|
4220
|
+
- `#seat { seat: SeatInfo; state: SeatState; category: SeatCategory | undefined; }` — Replaces a seat's content (the button stays). Slot props: `{ seat, state, category }`
|
|
4221
|
+
- `#legend { categories: SeatCategory[]; }` — Replaces the legend under the map. Slot props: `{ categories }`
|
|
4222
|
+
|
|
4223
|
+
```ts
|
|
4224
|
+
/** A seat type: its key is the character that marks it in `layout`. */
|
|
4225
|
+
export interface SeatCategory {
|
|
4226
|
+
/** Single character used for this category in `layout` rows */
|
|
4227
|
+
key: string
|
|
4228
|
+
/** Name shown in the legend and the seat's label, e.g. "Premium" */
|
|
4229
|
+
label: string
|
|
4230
|
+
/** A color role (`primary`, `secondary`, `tertiary`, `error`, `success`) or any CSS color. Default `primary` */
|
|
4231
|
+
color?: string
|
|
4232
|
+
/** Price, shown in the legend and the seat's label */
|
|
4233
|
+
price?: number
|
|
4234
|
+
}
|
|
4235
|
+
```
|
|
4236
|
+
|
|
4237
|
+
```ts
|
|
4238
|
+
/** A seat as laid out by `MSeatMap`, given to the `seat` slot and the `select` event. */
|
|
4239
|
+
export interface SeatInfo {
|
|
4240
|
+
/** Id used in v-model, `occupied` and `blocked`: "F12" (theater naming) or "12C" (plane naming) */
|
|
4241
|
+
id: string
|
|
4242
|
+
/** Row label, e.g. "F" or "12" */
|
|
4243
|
+
row: string
|
|
4244
|
+
/** Seat label within the row, e.g. "12" or "C" */
|
|
4245
|
+
number: string
|
|
4246
|
+
/** Category key (the layout character) */
|
|
4247
|
+
category: string
|
|
4248
|
+
/** Grid row and column (0-based, gaps included) */
|
|
4249
|
+
r: number
|
|
4250
|
+
c: number
|
|
4251
|
+
}
|
|
4252
|
+
```
|
|
4253
|
+
|
|
4254
|
+
```ts
|
|
4255
|
+
export type SeatState = 'available' | 'selected' | 'occupied' | 'blocked'
|
|
4256
|
+
```
|
|
4257
|
+
|
|
3531
4258
|
### MSection
|
|
3532
4259
|
|
|
3533
4260
|
A titled content section with optional subtitle, header actions, and divider.
|
|
@@ -3634,7 +4361,7 @@ Props:
|
|
|
3634
4361
|
- `noResultsText?: string` — Text shown when options is empty — defaults to the current locale's string
|
|
3635
4362
|
|
|
3636
4363
|
Events:
|
|
3637
|
-
- `update:modelValue(unknown)` — Emitted with the selected option's value.
|
|
4364
|
+
- `update:modelValue(unknown)` — Emitted with the selected option's value (`null` when the clear button empties it).
|
|
3638
4365
|
|
|
3639
4366
|
```ts
|
|
3640
4367
|
export interface SelectOption {
|
|
@@ -3825,7 +4552,7 @@ Props:
|
|
|
3825
4552
|
- `showTooltip?: boolean = false` — Show value tooltip while dragging
|
|
3826
4553
|
- `orientation?: "horizontal" | "vertical" = "horizontal"` — Slider orientation
|
|
3827
4554
|
- `size?: "xs" | "sm" | "md" | "lg" | "xl" = "xs"` — Track and thumb size
|
|
3828
|
-
- `variant?: "standard" | "
|
|
4555
|
+
- `variant?: "standard" | "range" | "centered" = "standard"` — Standard, centered (from middle), or range (two thumbs)
|
|
3829
4556
|
- `stops?: boolean = false` — Show stop dots at each step (max 30 visible), and make a dragged thumb snap from step to step instead of following the pointer smoothly (a discrete slider)
|
|
3830
4557
|
- `icon?: string` — Material Symbol icon shown before the slider — hides once the fill reaches it
|
|
3831
4558
|
- `color?: "error" | "primary" | "secondary" | "tertiary" = "primary"` — Base color — used for the fill and thumb unless overridden by fillColor/thumbColor
|
|
@@ -3958,8 +4685,8 @@ Flex stack with gap, alignment, and optional dividers between items.
|
|
|
3958
4685
|
Props:
|
|
3959
4686
|
- `direction?: "row" | "column" = "column"` — Stack direction
|
|
3960
4687
|
- `gap?: "none" | "xs" | "sm" | "md" | "lg" | "xl" = "md"` — Gap between items (ignored when divider is true)
|
|
3961
|
-
- `align?: "center" | "
|
|
3962
|
-
- `justify?: "center" | "
|
|
4688
|
+
- `align?: "center" | "end" | "start" | "stretch" | "baseline" = "stretch"` — Cross-axis alignment
|
|
4689
|
+
- `justify?: "center" | "end" | "start" | "between" | "around" | "evenly" = "start"` — Main-axis alignment
|
|
3963
4690
|
- `wrap?: boolean = false` — Allow items to wrap
|
|
3964
4691
|
- `divider?: boolean = false` — Show dividers between items instead of a gap
|
|
3965
4692
|
- `inline?: boolean = false` — Use inline-flex
|
|
@@ -4274,12 +5001,56 @@ Slots:
|
|
|
4274
5001
|
- `#trailing` — Custom trailing content (e.g. an icon button) — replaces the built-in clear button when present
|
|
4275
5002
|
|
|
4276
5003
|
Exposed (template ref):
|
|
4277
|
-
- `inputEl:
|
|
5004
|
+
- `inputEl: HTMLTextAreaElement | HTMLInputElement | null` — The `<input>` (or `<textarea>`) element
|
|
4278
5005
|
- `focus: (options?: FocusOptions | undefined) => void | undefined` — Focuses the field
|
|
4279
5006
|
- `blur: () => void | undefined` — Takes focus away from the field
|
|
4280
5007
|
- `select: () => void | undefined` — Selects all its text
|
|
4281
5008
|
- `setSelectionRange: (start: number, end: number, direction?: "none" | "forward" | "backward" | undefined) => void | undefined` — Selects part of its text (e.g. a file name without its extension)
|
|
4282
5009
|
|
|
5010
|
+
### MTicket
|
|
5011
|
+
|
|
5012
|
+
A ticket with a tear-off stub: a boarding pass, a bus or train ticket, a concert or cinema entry, a coupon. The stub is separated by a perforated line with two notches cut out, and usually holds the code to scan (put an `MQRCode` or `MBarcode` in the `stub` slot). Trips get a from → to route; any ticket gets a grid of fields.
|
|
5013
|
+
|
|
5014
|
+
Props:
|
|
5015
|
+
- `title?: string` — Title in the colored band, e.g. the airline, the event or the movie
|
|
5016
|
+
- `subtitle?: string` — A line under the title, e.g. the venue or the date
|
|
5017
|
+
- `icon?: string` — Material Symbol before the title
|
|
5018
|
+
- `color?: string = "primary"` — Band color: a role (primary, secondary, tertiary, error, success) or any CSS color
|
|
5019
|
+
- `from?: TicketStop` — Where the trip starts
|
|
5020
|
+
- `to?: TicketStop` — Where the trip ends
|
|
5021
|
+
- `transport?: string = "flight"` — Material Symbol between from and to
|
|
5022
|
+
- `fields?: TicketField[] = []` — Label/value pairs in a grid
|
|
5023
|
+
- `orientation?: "horizontal" | "vertical" = "horizontal"` — Stub beside the main part (an event ticket) or under it (a phone boarding pass)
|
|
5024
|
+
- `stubSize?: string = "10rem"` — Width of the stub in horizontal orientation (any CSS length)
|
|
5025
|
+
- `notch?: number = 12` — Radius of the notches cut at the perforation, in px
|
|
5026
|
+
|
|
5027
|
+
Slots:
|
|
5028
|
+
- `#header` — Replaces the title row in the colored band (e.g. an airline logo and a status chip)
|
|
5029
|
+
- `#default` — Content of the main part, under the route and fields
|
|
5030
|
+
- `#stub` — Content of the stub: a QR, a barcode, a number
|
|
5031
|
+
|
|
5032
|
+
```ts
|
|
5033
|
+
/** One end of a trip in an `MTicket`: an airport, a station, a terminal. */
|
|
5034
|
+
export interface TicketStop {
|
|
5035
|
+
/** Short code shown big, e.g. "EZE" or "RET" */
|
|
5036
|
+
code: string
|
|
5037
|
+
/** City or station name under the code */
|
|
5038
|
+
name?: string
|
|
5039
|
+
/** Departure / arrival time, shown under the name */
|
|
5040
|
+
time?: string
|
|
5041
|
+
}
|
|
5042
|
+
```
|
|
5043
|
+
|
|
5044
|
+
```ts
|
|
5045
|
+
/** A label/value pair on an `MTicket`, e.g. `{ label: 'Gate', value: 'B12' }`. */
|
|
5046
|
+
export interface TicketField {
|
|
5047
|
+
label: string
|
|
5048
|
+
value: string | number
|
|
5049
|
+
/** Emphasizes the value (e.g. the seat or the gate) */
|
|
5050
|
+
strong?: boolean
|
|
5051
|
+
}
|
|
5052
|
+
```
|
|
5053
|
+
|
|
4283
5054
|
### MTimeline
|
|
4284
5055
|
|
|
4285
5056
|
An event timeline with icon dots, dates, and colors — a single column, alternating left/right, or horizontal. With `current` (or items' `status`) it tracks progress: done steps filled with a solid line, the current one pulsing, the rest outlined with a dashed line. Every part can be replaced through slots, which receive `{ item, index }`; your item type flows into them.
|
|
@@ -4421,8 +5192,8 @@ Props:
|
|
|
4421
5192
|
- `variant?: "docked" | "floating" = "docked"` — Docked (edge-attached, full width/height, bordered) or floating (rounded pill with shadow)
|
|
4422
5193
|
- `orientation?: "horizontal" | "vertical" = "horizontal"` — Layout direction
|
|
4423
5194
|
- `color?: "surface" | "primary" | "secondary" | "tertiary" = "surface"` — Background color scheme
|
|
4424
|
-
- `fabPosition?: "
|
|
4425
|
-
- `align?: "center" | "
|
|
5195
|
+
- `fabPosition?: "end" | "start" | "none" = "none"` — Where the #fab slot renders relative to the toolbar body
|
|
5196
|
+
- `align?: "center" | "end" | "start" | "between" = "center"` — Item alignment along the main axis
|
|
4426
5197
|
- `collapseOnScroll?: string | boolean | HTMLElement | null = false` — Collapse a floating toolbar as the content scrolls down and expand it as it scrolls back up (40px each way): `true` follows the window, or pass the scrolling element (or a CSS selector for it). Off by default
|
|
4427
5198
|
- `expanded?: boolean = true` (v-model:expanded) — A floating toolbar's state: collapsed, it shows only the FAB, or only its center without one. Default `true`
|
|
4428
5199
|
|
|
@@ -4769,6 +5540,50 @@ export interface VTableColumn {
|
|
|
4769
5540
|
}
|
|
4770
5541
|
```
|
|
4771
5542
|
|
|
5543
|
+
### MVitalsChart
|
|
5544
|
+
|
|
5545
|
+
A vitals flowsheet: one row per vital sign (heart rate, blood pressure, SpO₂, temperature, respiratory rate…) over a shared time axis, each with its normal range as a band, readings outside it in the error color, and the latest value (with a High / Low tag) beside the row. Blood pressure and other pair readings are drawn as bars from the lower to the upper value. Hovering (or the arrow keys) moves a crosshair across every row at once.
|
|
5546
|
+
|
|
5547
|
+
Props:
|
|
5548
|
+
- `series: VitalSeries[]`
|
|
5549
|
+
- `rowHeight?: number = 64` — Height of each row's plot, in px
|
|
5550
|
+
- `from?: string | number | Date` — Start of the time axis (defaults to the first reading)
|
|
5551
|
+
- `to?: string | number | Date` — End of the time axis (defaults to the last reading)
|
|
5552
|
+
|
|
5553
|
+
Events:
|
|
5554
|
+
- `hover(number | null)` — The time under the crosshair (epoch ms), or null when it leaves
|
|
5555
|
+
|
|
5556
|
+
Slots:
|
|
5557
|
+
- `#label { series: { data: VitalReading[]; key: string; label: string; unit?: string | undefined; color?: string | undefined; decimals?: number | undefined; normal?: [number, number] | [[number, number], [number, number]] | undefined; domain?: [number, number] | undefined; }; reading: VitalReading | undefined; status: "normal" | "high" | "low"; }` — Replaces a row's label column. Slot props: `{ series, reading, status }`
|
|
5558
|
+
|
|
5559
|
+
```ts
|
|
5560
|
+
/** A vital sign: its readings, unit and normal range. */
|
|
5561
|
+
export interface VitalSeries {
|
|
5562
|
+
key: string
|
|
5563
|
+
label: string
|
|
5564
|
+
unit?: string
|
|
5565
|
+
/** Line / point color (any CSS color). Defaults to the primary color */
|
|
5566
|
+
color?: string
|
|
5567
|
+
decimals?: number
|
|
5568
|
+
/**
|
|
5569
|
+
* Normal range, drawn as a band. For pair readings give one range per value:
|
|
5570
|
+
* `[[90, 120], [60, 80]]` for systolic and diastolic
|
|
5571
|
+
*/
|
|
5572
|
+
normal?: [number, number] | [[number, number], [number, number]]
|
|
5573
|
+
/** Fixed axis range; by default it fits the readings and the normal band */
|
|
5574
|
+
domain?: [number, number]
|
|
5575
|
+
data: VitalReading[]
|
|
5576
|
+
}
|
|
5577
|
+
```
|
|
5578
|
+
|
|
5579
|
+
```ts
|
|
5580
|
+
/** One reading of a vital sign. A pair is a range reading such as blood pressure: `[systolic, diastolic]`. */
|
|
5581
|
+
export interface VitalReading {
|
|
5582
|
+
time: Date | string | number
|
|
5583
|
+
value: number | [number, number]
|
|
5584
|
+
}
|
|
5585
|
+
```
|
|
5586
|
+
|
|
4772
5587
|
### MWindow
|
|
4773
5588
|
|
|
4774
5589
|
A floating, draggable, resizable window — the building block for a desktop-style multi-window UI inside your app. Drag from the title bar, resize from any edge or corner, minimize to just the title bar, maximize (or double-click the title bar) to fill its container, and click any window to bring it to front. The window in front shows a stronger title bar and elevation, the others step back. Material 3 has no window component, so this one is built from M3 pieces: surface tones, elevation levels, 32dp icon buttons with state layers, and standard motion.
|
|
@@ -5903,6 +6718,54 @@ A decor kind's name: a built-in one in the app's language (unless renamed), else
|
|
|
5903
6718
|
floorDecorName(kind: string, kinds: Record<string, FloorDecorKind>, locale: M3Locale): string
|
|
5904
6719
|
```
|
|
5905
6720
|
|
|
6721
|
+
### detectCardBrand
|
|
6722
|
+
|
|
6723
|
+
Card network of a (partial) number, from its leading digits. Spaces and dashes are ignored.
|
|
6724
|
+
|
|
6725
|
+
```ts
|
|
6726
|
+
detectCardBrand(number: string): CardBrandInfo
|
|
6727
|
+
```
|
|
6728
|
+
|
|
6729
|
+
### luhnCheck
|
|
6730
|
+
|
|
6731
|
+
Luhn (mod 10) checksum of a card number. Spaces and dashes are ignored.
|
|
6732
|
+
|
|
6733
|
+
```ts
|
|
6734
|
+
luhnCheck(number: string): boolean
|
|
6735
|
+
```
|
|
6736
|
+
|
|
6737
|
+
### formatCardNumber
|
|
6738
|
+
|
|
6739
|
+
Formats digits with the brand's gaps: `"4242424242424242"` → `"4242 4242 4242 4242"`.
|
|
6740
|
+
|
|
6741
|
+
```ts
|
|
6742
|
+
formatCardNumber(number: string): string
|
|
6743
|
+
```
|
|
6744
|
+
|
|
6745
|
+
### isValidCardNumber
|
|
6746
|
+
|
|
6747
|
+
Whether a card number is complete and valid for its brand (length, plus Luhn where the network uses it).
|
|
6748
|
+
|
|
6749
|
+
```ts
|
|
6750
|
+
isValidCardNumber(number: string): boolean
|
|
6751
|
+
```
|
|
6752
|
+
|
|
6753
|
+
### isValidExpiry
|
|
6754
|
+
|
|
6755
|
+
Whether an `MM/YY` expiry is well formed and not in the past (a card is valid through its expiry month).
|
|
6756
|
+
|
|
6757
|
+
```ts
|
|
6758
|
+
isValidExpiry(expiry: string, now: Date = new Date()): boolean
|
|
6759
|
+
```
|
|
6760
|
+
|
|
6761
|
+
### amortize
|
|
6762
|
+
|
|
6763
|
+
Builds the payment schedule of a loan. Amounts are rounded to cents per payment and the last payment absorbs the rounding, so the balance ends at exactly 0.
|
|
6764
|
+
|
|
6765
|
+
```ts
|
|
6766
|
+
amortize({ principal, rate, years, system = 'french', periodsPerYear = 12 }: AmortizationOptions): Amortization
|
|
6767
|
+
```
|
|
6768
|
+
|
|
5906
6769
|
### emojiCategories
|
|
5907
6770
|
|
|
5908
6771
|
```ts
|
|
@@ -7871,6 +8734,152 @@ export interface M3Locale {
|
|
|
7871
8734
|
drawUnlockLayer: string
|
|
7872
8735
|
drawLayerUp: string
|
|
7873
8736
|
drawLayerDown: string
|
|
8737
|
+
// MBeforeAfter
|
|
8738
|
+
compareBefore: string
|
|
8739
|
+
compareAfter: string
|
|
8740
|
+
compareSlider: string
|
|
8741
|
+
// MCreditCardInput
|
|
8742
|
+
cardNumber: string
|
|
8743
|
+
cardExpiry: string
|
|
8744
|
+
cardCvc: string
|
|
8745
|
+
cardName: string
|
|
8746
|
+
cardInvalidNumber: string
|
|
8747
|
+
cardInvalidExpiry: string
|
|
8748
|
+
cardInvalidCvc: string
|
|
8749
|
+
// MPosKeypad
|
|
8750
|
+
keypadDelete: string
|
|
8751
|
+
keypadClear: string
|
|
8752
|
+
keypadChange: string
|
|
8753
|
+
keypadRemaining: string
|
|
8754
|
+
// MSeatMap ({seat} is replaced at runtime)
|
|
8755
|
+
seatStage: string
|
|
8756
|
+
seatAvailable: string
|
|
8757
|
+
seatSelected: string
|
|
8758
|
+
seatOccupied: string
|
|
8759
|
+
seatLabel: string
|
|
8760
|
+
// MReceipt
|
|
8761
|
+
receiptSubtotal: string
|
|
8762
|
+
receiptTotal: string
|
|
8763
|
+
receiptPaid: string
|
|
8764
|
+
receiptChange: string
|
|
8765
|
+
// MProductConfigurator ({n} is replaced at runtime)
|
|
8766
|
+
configRequired: string
|
|
8767
|
+
configOptional: string
|
|
8768
|
+
configChooseUpTo: string
|
|
8769
|
+
configChooseAtLeast: string
|
|
8770
|
+
configChooseExactly: string
|
|
8771
|
+
configUnavailable: string
|
|
8772
|
+
configQuantity: string
|
|
8773
|
+
configIncrease: string
|
|
8774
|
+
configDecrease: string
|
|
8775
|
+
// MAvailabilityCalendar ({n} is replaced at runtime)
|
|
8776
|
+
availNight: string
|
|
8777
|
+
availNights: string
|
|
8778
|
+
availMinNights: string
|
|
8779
|
+
availCheckIn: string
|
|
8780
|
+
availCheckOut: string
|
|
8781
|
+
availSelectCheckIn: string
|
|
8782
|
+
availSelectCheckOut: string
|
|
8783
|
+
availUnavailable: string
|
|
8784
|
+
// MCandlestickChart
|
|
8785
|
+
chartOpen: string
|
|
8786
|
+
chartHigh: string
|
|
8787
|
+
chartLow: string
|
|
8788
|
+
chartClose: string
|
|
8789
|
+
chartVolume: string
|
|
8790
|
+
// MOrderBook
|
|
8791
|
+
bookPrice: string
|
|
8792
|
+
bookSize: string
|
|
8793
|
+
bookTotal: string
|
|
8794
|
+
bookSpread: string
|
|
8795
|
+
// MMortgageCalculator ({n} is replaced at runtime)
|
|
8796
|
+
mortgagePrice: string
|
|
8797
|
+
mortgageDown: string
|
|
8798
|
+
mortgageRate: string
|
|
8799
|
+
mortgageTerm: string
|
|
8800
|
+
mortgageYears: string
|
|
8801
|
+
mortgageLoan: string
|
|
8802
|
+
mortgageMonthly: string
|
|
8803
|
+
mortgageFirstPayment: string
|
|
8804
|
+
mortgageLastPayment: string
|
|
8805
|
+
mortgagePrincipal: string
|
|
8806
|
+
mortgageInterest: string
|
|
8807
|
+
mortgageTotal: string
|
|
8808
|
+
mortgageSchedule: string
|
|
8809
|
+
mortgageYear: string
|
|
8810
|
+
mortgageBalance: string
|
|
8811
|
+
// MBodyMap ({part} is replaced at runtime)
|
|
8812
|
+
bodyFront: string
|
|
8813
|
+
bodyBack: string
|
|
8814
|
+
bodyRight: string
|
|
8815
|
+
bodyLeft: string
|
|
8816
|
+
bodyRear: string
|
|
8817
|
+
bodyHead: string
|
|
8818
|
+
bodyNeck: string
|
|
8819
|
+
bodyChest: string
|
|
8820
|
+
bodyAbdomen: string
|
|
8821
|
+
bodyPelvis: string
|
|
8822
|
+
bodyShoulder: string
|
|
8823
|
+
bodyUpperArm: string
|
|
8824
|
+
bodyForearm: string
|
|
8825
|
+
bodyHand: string
|
|
8826
|
+
bodyThigh: string
|
|
8827
|
+
bodyKnee: string
|
|
8828
|
+
bodyLeg: string
|
|
8829
|
+
bodyFoot: string
|
|
8830
|
+
bodyUpperBack: string
|
|
8831
|
+
bodyLowerBack: string
|
|
8832
|
+
bodyGlute: string
|
|
8833
|
+
bodyCalf: string
|
|
8834
|
+
// MOdontogram ({n} is replaced at runtime)
|
|
8835
|
+
odontoTooth: string
|
|
8836
|
+
odontoUpper: string
|
|
8837
|
+
odontoLower: string
|
|
8838
|
+
odontoMesial: string
|
|
8839
|
+
odontoDistal: string
|
|
8840
|
+
odontoBuccal: string
|
|
8841
|
+
odontoLingual: string
|
|
8842
|
+
odontoOcclusal: string
|
|
8843
|
+
odontoCaries: string
|
|
8844
|
+
odontoFilling: string
|
|
8845
|
+
odontoSealant: string
|
|
8846
|
+
odontoCrown: string
|
|
8847
|
+
odontoRootCanal: string
|
|
8848
|
+
odontoImplant: string
|
|
8849
|
+
odontoMissing: string
|
|
8850
|
+
odontoExtraction: string
|
|
8851
|
+
odontoEraser: string
|
|
8852
|
+
// MVitalsChart
|
|
8853
|
+
vitalsNormal: string
|
|
8854
|
+
vitalsHigh: string
|
|
8855
|
+
vitalsLow: string
|
|
8856
|
+
vitalsNoData: string
|
|
8857
|
+
// MQuiz ({n}, {total}, {score}, {answer} are replaced at runtime)
|
|
8858
|
+
quizCheck: string
|
|
8859
|
+
quizNext: string
|
|
8860
|
+
quizFinish: string
|
|
8861
|
+
quizCorrect: string
|
|
8862
|
+
quizIncorrect: string
|
|
8863
|
+
quizCorrectAnswer: string
|
|
8864
|
+
quizQuestionOf: string
|
|
8865
|
+
quizScore: string
|
|
8866
|
+
quizPassed: string
|
|
8867
|
+
quizFailed: string
|
|
8868
|
+
quizRetry: string
|
|
8869
|
+
quizTrue: string
|
|
8870
|
+
quizFalse: string
|
|
8871
|
+
quizSelectAll: string
|
|
8872
|
+
quizOrderHint: string
|
|
8873
|
+
quizMoveUp: string
|
|
8874
|
+
quizMoveDown: string
|
|
8875
|
+
quizTypeAnswer: string
|
|
8876
|
+
quizTimeLeft: string
|
|
8877
|
+
quizReview: string
|
|
8878
|
+
// MCertificate
|
|
8879
|
+
certTitle: string
|
|
8880
|
+
certPresentedTo: string
|
|
8881
|
+
certDate: string
|
|
8882
|
+
certId: string
|
|
7874
8883
|
}
|
|
7875
8884
|
```
|
|
7876
8885
|
|
|
@@ -8285,6 +9294,79 @@ export type FloorTool = 'select' | 'wall' | 'area' | 'polygon'
|
|
|
8285
9294
|
export type FloorItemKind = 'table' | 'area' | 'wall' | 'decor'
|
|
8286
9295
|
```
|
|
8287
9296
|
|
|
9297
|
+
```ts
|
|
9298
|
+
/** Card networks recognized by `detectCardBrand()` and `MCreditCardInput`. */
|
|
9299
|
+
export type CardBrand =
|
|
9300
|
+
| 'visa'
|
|
9301
|
+
| 'mastercard'
|
|
9302
|
+
| 'amex'
|
|
9303
|
+
| 'discover'
|
|
9304
|
+
| 'diners'
|
|
9305
|
+
| 'jcb'
|
|
9306
|
+
| 'unionpay'
|
|
9307
|
+
| 'maestro'
|
|
9308
|
+
| 'naranja'
|
|
9309
|
+
| 'cabal'
|
|
9310
|
+
| 'unknown'
|
|
9311
|
+
```
|
|
9312
|
+
|
|
9313
|
+
```ts
|
|
9314
|
+
export interface CardBrandInfo {
|
|
9315
|
+
brand: CardBrand
|
|
9316
|
+
/** Display name, e.g. "Mastercard" */
|
|
9317
|
+
name: string
|
|
9318
|
+
/** Valid lengths of the number, in digits */
|
|
9319
|
+
lengths: number[]
|
|
9320
|
+
/** Digit counts after which a space is shown, e.g. [4, 8, 12] → `4242 4242 4242 4242` */
|
|
9321
|
+
gaps: number[]
|
|
9322
|
+
/** Length of the security code */
|
|
9323
|
+
cvcLength: number
|
|
9324
|
+
/** Whether the number has to pass the Luhn checksum */
|
|
9325
|
+
luhn: boolean
|
|
9326
|
+
}
|
|
9327
|
+
```
|
|
9328
|
+
|
|
9329
|
+
```ts
|
|
9330
|
+
export interface Amortization {
|
|
9331
|
+
payments: AmortizationPayment[]
|
|
9332
|
+
firstPayment: number
|
|
9333
|
+
lastPayment: number
|
|
9334
|
+
totalInterest: number
|
|
9335
|
+
totalPaid: number
|
|
9336
|
+
}
|
|
9337
|
+
```
|
|
9338
|
+
|
|
9339
|
+
```ts
|
|
9340
|
+
export interface AmortizationOptions {
|
|
9341
|
+
/** Amount borrowed */
|
|
9342
|
+
principal: number
|
|
9343
|
+
/** Yearly nominal interest rate, in percent (e.g. 6.5) */
|
|
9344
|
+
rate: number
|
|
9345
|
+
/** Term in years */
|
|
9346
|
+
years: number
|
|
9347
|
+
/**
|
|
9348
|
+
* `french`: the same payment every period (most of the world's mortgages).
|
|
9349
|
+
* `german`: the same principal every period, so payments start higher and fall.
|
|
9350
|
+
*/
|
|
9351
|
+
system?: 'french' | 'german'
|
|
9352
|
+
/** Payments per year */
|
|
9353
|
+
periodsPerYear?: number
|
|
9354
|
+
}
|
|
9355
|
+
```
|
|
9356
|
+
|
|
9357
|
+
```ts
|
|
9358
|
+
/** One payment of an amortization schedule. */
|
|
9359
|
+
export interface AmortizationPayment {
|
|
9360
|
+
/** 1-based payment number */
|
|
9361
|
+
n: number
|
|
9362
|
+
payment: number
|
|
9363
|
+
principal: number
|
|
9364
|
+
interest: number
|
|
9365
|
+
/** Balance left after this payment */
|
|
9366
|
+
balance: number
|
|
9367
|
+
}
|
|
9368
|
+
```
|
|
9369
|
+
|
|
8288
9370
|
```ts
|
|
8289
9371
|
// Generated by scripts/generate-emoji-data.mjs from Unicode emoji-test.txt (Emoji 15). Don't edit by hand.
|
|
8290
9372
|
// Emoji data © Unicode, Inc., under the Unicode License v3 (dist/THIRD_PARTY_LICENSES.md, scripts/licenses/unicode-license-v3.txt).
|
|
@@ -8303,7 +9385,7 @@ export interface EmojiCategory {
|
|
|
8303
9385
|
`M3Locale` keys (pass a partial object to `createM3UI({ locale })`; presets from `@m3ui-vue/m3ui-vue/locales`:
|
|
8304
9386
|
`esLocale`, `frLocale`, `ptLocale`, `deLocale`, `jaLocale`, `zhLocale`, `koLocale`):
|
|
8305
9387
|
|
|
8306
|
-
lang, search, noResults, close, cancel, confirm, loading, menu, previous, next, today, more, selectedCount, recordCount, expand, collapse, clear, columns, exportCsv, noGroup, finish, dropText, selectText, maxSizePrefix, remove, selectDate, ok, dateToggleInput, dateToggleCalendar, dateInputLabel, selectTime, timeHourSelection, timeMinuteSelection, timePeriodToggle, timeToggleKeyboard, timeToggleDial, timeToggleScroll, sheetExpand, sheetCollapse, sheetDismiss, seekBar, seekBarValue, seekBarShowRemaining, seekBarShowDuration, selectRange, pickStart, pickEnd, previousMonth, nextMonth, selectColor, colorHue, colorSaturation, colorBrightness, colorAlpha, colorEyedropper, colorOriginal, colorFormat, colorRecent, colorPresets, dayView, weekView, allDay, emojiSearch, emojiNoResults, emojiRecent, emojiSkinTone, emojiSkinTones, emojiCategorySmileys, emojiCategoryGestures, emojiCategoryPeople, emojiCategoryAnimals, emojiCategoryNature, emojiCategoryFood, emojiCategoryActivities, emojiCategoryTravel, emojiCategoryObjects, emojiCategorySymbols, emojiCategoryFlags, available, selected, noItems, moveAllRight, moveRight, moveLeft, moveAllLeft, searchCommand, navigateHint, selectHint, openHint, closeHint, loadingMore, noMoreItems, bold, italic, underline, strikethrough, highlight, bulletList, orderedList, blockquote, code, alignLeft, alignCenter, alignRight, undo, redo, link, image, paragraph, heading1, heading2, heading3, insertLink, insertImage, imageUrlLabel, insert, jsonValid, jsonInvalid, jsonFormat, jsonMinify, jsonElements, jsonFields, resultSuccessTitle, resultSuccessDesc, resultErrorTitle, resultErrorDesc, resultWarningTitle, resultWarningDesc, resultInfoTitle, resultInfoDesc, result404Title, result404Desc, result403Title, result403Desc, result500Title, result500Desc, chatTyping, chatRecordingAudio, reorderHandle, reorderGrabbed, reorderMoved, reorderDropped, reorderCancelled, selectAll, clearSearch, kanbanMoved, windowMinimize, windowMaximize, windowRestore, paginationRange, paginationPage, previousPage, nextPage, carousel, carouselItem, sparklineSummary, sliderRangeStart, sliderRangeEnd, mapTitle, mapMarker, mapZoomIn, mapZoomOut, mapResetBearing, mapFindMyLocation, mapLocationNotAvailable, mapEnterFullscreen, mapExitFullscreen, mapToggleAttribution, mapFeedback, mapCtrlScroll, mapCmdScroll, mapTwoFingers, mapLayers, mapSearchLayers, mapNoLayers, mapShowLayer, mapHideLayer, mapOpacity, mapDownload, mapNoBaseLayer, mapHoverInfo, mapNoValue, mapMeasureDistance, mapMeasureArea, mapClearMeasurements, mapDeleteMeasurement, mapTotal, mapSearchPlaces, timelineShowMore, timelineShowLess, mediaPlayer, mediaPlay, mediaPause, mediaReplay, mediaSeekBack, mediaSeekForward, mediaSeconds, mediaMute, mediaUnmute, mediaVolume, mediaFullscreen, mediaExitFullscreen, mediaPictureInPicture, mediaSettings, mediaSpeed, mediaSpeedNormal, mediaSubtitles, mediaSubtitlesOff, mediaQuality, mediaQualityAuto, mediaLive, mediaError, mediaRepeat, mediaRepeatOne, mediaShuffle, pdfViewer, pdfThumbnails, pdfOutline, pdfPage, pdfZoom, pdfZoomIn, pdfZoomOut, pdfFitWidth, pdfFitPage, pdfSearch, pdfSearchPrevious, pdfSearchNext, pdfMatchCount, pdfNoMatches, pdfMore, pdfRotate, pdfDownload, pdfPrint, pdfFullscreen, pdfExitFullscreen, pdfPassword, pdfPasswordLabel, pdfWrongPassword, pdfOpen, pdfError, pdfLoading, pdfAnnotate, pdfSelect, pdfHighlight, pdfNote, pdfDraw, pdfEraser, pdfInkWidth, pdfColor, pdfUndo, pdfCopy, pdfDelete, pdfNotePlaceholder, pdfAddComment, flowCanvas, flowNode, flowEdge, flowZoomIn, flowZoomOut, flowFitView, flowLock, flowUnlock, flowUndo, flowRedo, flowMinimap, flowMoved, flowConnected, flowDeleted, flowDeleteEdge, flowDelete, ganttChart, ganttTask, ganttStart, ganttEnd, ganttDuration, ganttProgress, ganttDays, ganttHours, ganttMilestone, ganttQuarter, ganttToday, ganttZoomIn, ganttZoomOut, ganttExpandAll, ganttCollapseAll, ganttExpand, ganttCollapse, ganttUndo, ganttRedo, ganttScaleHour, ganttScaleDay, ganttScaleWeek, ganttScaleMonth, ganttScaleQuarter, ganttScaleYear, ganttMoved, ganttProgressSet, ganttLinked, ganttUnlink, ganttDeleted, ganttDelete, ganttReordered, ganttSlack, ganttCritical, ganttBaseline, ganttEmpty, ganttResize, timelineResource, timelineConflict, timelineMoved, timelineEmpty, cropArea, cropRotateLeft, cropRotateRight, cropFlip, cropReset, cropFree, drawCanvas, drawTools, drawMore, drawSelect, drawPan, drawPen, drawBrush, drawMarker, drawHighlighter, drawEraser, drawStrokeEraser, drawLine, drawArrow, drawRect, drawEllipse, drawText, drawFill, drawColor, floorPlan, floorSeats, floorRotate, floorTools, floorMove, floorDrawWall, floorDrawZone, floorAddTable, floorAddDecor, floorDuplicate, floorDelete, floorUndo, floorRedo, floorLabel, floorSeatsField, floorShape, floorRound, floorSquare, floorLong, floorAngle, floorFlip, floorZoomIn, floorZoomOut, floorZoomFit, floorOverlaps, floorSeatN, floorDrawShape, floorShapeHint, floorColor, floorThickness, floorWidth, floorHeight, floorMerge, floorSplit, floorNothingPicked, floorTablesPicked, floorTableN, floorZone, floorWall, floorDeleteCorner, floorFinishWall, floorCancel, floorDecorDoor, floorDecorWindow, floorDecorPlant, floorDecorColumn, floorDecorRestroom, floorDecorKitchen, floorDecorRegister, floorDecorStairs, floorDecorLabel, drawCustomColor, drawSize, drawUndo, drawRedo, drawDelete, drawLayers, drawLayer, drawLayerName, drawAddLayer, drawDeleteLayer, drawShowLayer, drawHideLayer, drawLockLayer, drawUnlockLayer, drawLayerUp, drawLayerDown
|
|
9388
|
+
lang, search, noResults, close, cancel, confirm, loading, menu, previous, next, today, more, selectedCount, recordCount, expand, collapse, clear, columns, exportCsv, noGroup, finish, dropText, selectText, maxSizePrefix, remove, selectDate, ok, dateToggleInput, dateToggleCalendar, dateInputLabel, selectTime, timeHourSelection, timeMinuteSelection, timePeriodToggle, timeToggleKeyboard, timeToggleDial, timeToggleScroll, sheetExpand, sheetCollapse, sheetDismiss, seekBar, seekBarValue, seekBarShowRemaining, seekBarShowDuration, selectRange, pickStart, pickEnd, previousMonth, nextMonth, selectColor, colorHue, colorSaturation, colorBrightness, colorAlpha, colorEyedropper, colorOriginal, colorFormat, colorRecent, colorPresets, dayView, weekView, allDay, emojiSearch, emojiNoResults, emojiRecent, emojiSkinTone, emojiSkinTones, emojiCategorySmileys, emojiCategoryGestures, emojiCategoryPeople, emojiCategoryAnimals, emojiCategoryNature, emojiCategoryFood, emojiCategoryActivities, emojiCategoryTravel, emojiCategoryObjects, emojiCategorySymbols, emojiCategoryFlags, available, selected, noItems, moveAllRight, moveRight, moveLeft, moveAllLeft, searchCommand, navigateHint, selectHint, openHint, closeHint, loadingMore, noMoreItems, bold, italic, underline, strikethrough, highlight, bulletList, orderedList, blockquote, code, alignLeft, alignCenter, alignRight, undo, redo, link, image, paragraph, heading1, heading2, heading3, insertLink, insertImage, imageUrlLabel, insert, jsonValid, jsonInvalid, jsonFormat, jsonMinify, jsonElements, jsonFields, resultSuccessTitle, resultSuccessDesc, resultErrorTitle, resultErrorDesc, resultWarningTitle, resultWarningDesc, resultInfoTitle, resultInfoDesc, result404Title, result404Desc, result403Title, result403Desc, result500Title, result500Desc, chatTyping, chatRecordingAudio, reorderHandle, reorderGrabbed, reorderMoved, reorderDropped, reorderCancelled, selectAll, clearSearch, kanbanMoved, windowMinimize, windowMaximize, windowRestore, paginationRange, paginationPage, previousPage, nextPage, carousel, carouselItem, sparklineSummary, sliderRangeStart, sliderRangeEnd, mapTitle, mapMarker, mapZoomIn, mapZoomOut, mapResetBearing, mapFindMyLocation, mapLocationNotAvailable, mapEnterFullscreen, mapExitFullscreen, mapToggleAttribution, mapFeedback, mapCtrlScroll, mapCmdScroll, mapTwoFingers, mapLayers, mapSearchLayers, mapNoLayers, mapShowLayer, mapHideLayer, mapOpacity, mapDownload, mapNoBaseLayer, mapHoverInfo, mapNoValue, mapMeasureDistance, mapMeasureArea, mapClearMeasurements, mapDeleteMeasurement, mapTotal, mapSearchPlaces, timelineShowMore, timelineShowLess, mediaPlayer, mediaPlay, mediaPause, mediaReplay, mediaSeekBack, mediaSeekForward, mediaSeconds, mediaMute, mediaUnmute, mediaVolume, mediaFullscreen, mediaExitFullscreen, mediaPictureInPicture, mediaSettings, mediaSpeed, mediaSpeedNormal, mediaSubtitles, mediaSubtitlesOff, mediaQuality, mediaQualityAuto, mediaLive, mediaError, mediaRepeat, mediaRepeatOne, mediaShuffle, pdfViewer, pdfThumbnails, pdfOutline, pdfPage, pdfZoom, pdfZoomIn, pdfZoomOut, pdfFitWidth, pdfFitPage, pdfSearch, pdfSearchPrevious, pdfSearchNext, pdfMatchCount, pdfNoMatches, pdfMore, pdfRotate, pdfDownload, pdfPrint, pdfFullscreen, pdfExitFullscreen, pdfPassword, pdfPasswordLabel, pdfWrongPassword, pdfOpen, pdfError, pdfLoading, pdfAnnotate, pdfSelect, pdfHighlight, pdfNote, pdfDraw, pdfEraser, pdfInkWidth, pdfColor, pdfUndo, pdfCopy, pdfDelete, pdfNotePlaceholder, pdfAddComment, flowCanvas, flowNode, flowEdge, flowZoomIn, flowZoomOut, flowFitView, flowLock, flowUnlock, flowUndo, flowRedo, flowMinimap, flowMoved, flowConnected, flowDeleted, flowDeleteEdge, flowDelete, ganttChart, ganttTask, ganttStart, ganttEnd, ganttDuration, ganttProgress, ganttDays, ganttHours, ganttMilestone, ganttQuarter, ganttToday, ganttZoomIn, ganttZoomOut, ganttExpandAll, ganttCollapseAll, ganttExpand, ganttCollapse, ganttUndo, ganttRedo, ganttScaleHour, ganttScaleDay, ganttScaleWeek, ganttScaleMonth, ganttScaleQuarter, ganttScaleYear, ganttMoved, ganttProgressSet, ganttLinked, ganttUnlink, ganttDeleted, ganttDelete, ganttReordered, ganttSlack, ganttCritical, ganttBaseline, ganttEmpty, ganttResize, timelineResource, timelineConflict, timelineMoved, timelineEmpty, cropArea, cropRotateLeft, cropRotateRight, cropFlip, cropReset, cropFree, drawCanvas, drawTools, drawMore, drawSelect, drawPan, drawPen, drawBrush, drawMarker, drawHighlighter, drawEraser, drawStrokeEraser, drawLine, drawArrow, drawRect, drawEllipse, drawText, drawFill, drawColor, floorPlan, floorSeats, floorRotate, floorTools, floorMove, floorDrawWall, floorDrawZone, floorAddTable, floorAddDecor, floorDuplicate, floorDelete, floorUndo, floorRedo, floorLabel, floorSeatsField, floorShape, floorRound, floorSquare, floorLong, floorAngle, floorFlip, floorZoomIn, floorZoomOut, floorZoomFit, floorOverlaps, floorSeatN, floorDrawShape, floorShapeHint, floorColor, floorThickness, floorWidth, floorHeight, floorMerge, floorSplit, floorNothingPicked, floorTablesPicked, floorTableN, floorZone, floorWall, floorDeleteCorner, floorFinishWall, floorCancel, floorDecorDoor, floorDecorWindow, floorDecorPlant, floorDecorColumn, floorDecorRestroom, floorDecorKitchen, floorDecorRegister, floorDecorStairs, floorDecorLabel, drawCustomColor, drawSize, drawUndo, drawRedo, drawDelete, drawLayers, drawLayer, drawLayerName, drawAddLayer, drawDeleteLayer, drawShowLayer, drawHideLayer, drawLockLayer, drawUnlockLayer, drawLayerUp, drawLayerDown, compareBefore, compareAfter, compareSlider, cardNumber, cardExpiry, cardCvc, cardName, cardInvalidNumber, cardInvalidExpiry, cardInvalidCvc, keypadDelete, keypadClear, keypadChange, keypadRemaining, seatStage, seatAvailable, seatSelected, seatOccupied, seatLabel, receiptSubtotal, receiptTotal, receiptPaid, receiptChange, configRequired, configOptional, configChooseUpTo, configChooseAtLeast, configChooseExactly, configUnavailable, configQuantity, configIncrease, configDecrease, availNight, availNights, availMinNights, availCheckIn, availCheckOut, availSelectCheckIn, availSelectCheckOut, availUnavailable, chartOpen, chartHigh, chartLow, chartClose, chartVolume, bookPrice, bookSize, bookTotal, bookSpread, mortgagePrice, mortgageDown, mortgageRate, mortgageTerm, mortgageYears, mortgageLoan, mortgageMonthly, mortgageFirstPayment, mortgageLastPayment, mortgagePrincipal, mortgageInterest, mortgageTotal, mortgageSchedule, mortgageYear, mortgageBalance, bodyFront, bodyBack, bodyRight, bodyLeft, bodyRear, bodyHead, bodyNeck, bodyChest, bodyAbdomen, bodyPelvis, bodyShoulder, bodyUpperArm, bodyForearm, bodyHand, bodyThigh, bodyKnee, bodyLeg, bodyFoot, bodyUpperBack, bodyLowerBack, bodyGlute, bodyCalf, odontoTooth, odontoUpper, odontoLower, odontoMesial, odontoDistal, odontoBuccal, odontoLingual, odontoOcclusal, odontoCaries, odontoFilling, odontoSealant, odontoCrown, odontoRootCanal, odontoImplant, odontoMissing, odontoExtraction, odontoEraser, vitalsNormal, vitalsHigh, vitalsLow, vitalsNoData, quizCheck, quizNext, quizFinish, quizCorrect, quizIncorrect, quizCorrectAnswer, quizQuestionOf, quizScore, quizPassed, quizFailed, quizRetry, quizTrue, quizFalse, quizSelectAll, quizOrderHint, quizMoveUp, quizMoveDown, quizTypeAnswer, quizTimeLeft, quizReview, certTitle, certPresentedTo, certDate, certId
|
|
8307
9389
|
|
|
8308
9390
|
## Theme tokens
|
|
8309
9391
|
|