@colixsystems/widget-sdk 0.362.0 → 0.363.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -3
- package/dist/contract.cjs +234 -29
- package/dist/contract.js +234 -29
- package/dist/index.d.ts +7 -0
- package/dist/sdk-texts.cjs +934 -84
- package/dist/sdk-texts.js +934 -85
- package/dist/signing-hooks.js +2 -1
- package/package.json +1 -1
- package/src/contract.js +234 -29
- package/src/sdk-texts.js +934 -85
package/dist/signing-hooks.js
CHANGED
|
@@ -311,7 +311,8 @@ export function useSigningRounds(fileIds) {
|
|
|
311
311
|
* never queued. A refused action sets `error` and rejects with it: `code` and
|
|
312
312
|
* `message` come from the server, `errors` has one entry per refused signer
|
|
313
313
|
* (with `index`, its place in the list sent), `retryAfter` is the seconds to
|
|
314
|
-
* wait
|
|
314
|
+
* wait, and `cause.details` is the server's body (a too-large prepare's
|
|
315
|
+
* `limit_bytes` included). When the refusal means the round is no longer what was shown, the
|
|
315
316
|
* round is read again.
|
|
316
317
|
*/
|
|
317
318
|
export function useSigningRound(fileId) {
|
package/package.json
CHANGED
package/src/contract.js
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
// the compiler's generated layout `elevationStyles`, and widgets reading
|
|
10
10
|
// `useTheme().elevation` — so a widget shadow and a container shadow match.
|
|
11
11
|
import { COMPONENT_PROPS, COMPONENT_PROPS_ERROR_PREFIX, componentPropsError, tabItemKey } from "./component-props.js";
|
|
12
|
-
import { COMPONENT_TEXTS, fillSdkText, localizedText } from "./sdk-texts.js";
|
|
12
|
+
import { COMPONENT_TEXTS, LANGUAGE_ALIASES, fillSdkText, localizedText } from "./sdk-texts.js";
|
|
13
13
|
import { formatDateForDisplay } from "./date-label.js";
|
|
14
14
|
|
|
15
15
|
const ELEVATION = Object.freeze({
|
|
@@ -4068,7 +4068,7 @@ const PRIMITIVES = [
|
|
|
4068
4068
|
{
|
|
4069
4069
|
name: "Select",
|
|
4070
4070
|
description:
|
|
4071
|
-
'Themed picker for ONE value of a known list, or several with `multiple`. `<Select label="Status" value={status} onValueChange={setStatus} options={[{ value: "open", label: "Open" }, { value: "done", label: "Done" }]} placeholder="Choose a status" />` — the default way to let the user pick ONE of a known list. The trigger is the app\'s input field (Design > Components > Inputs) showing the chosen label; pressing it opens the options at SCREEN level, in a sheet painted from Design > Components > Dropdown menus, so no card or scroll container can clip them, and a long list scrolls inside the sheet. The trigger is a button that opens a dialog (expanded state included) and each option carries the option role and its selected state on both hosts; the list around them is a listbox on the web only. On the web Enter, Space or an arrow key opens it, the arrow keys, Home and End move between options, Enter or Space chooses, Escape closes, and focus returns to the trigger; on Android the back button closes it. Props: `options` (`[{ value, label, disabled?, testID? }]`, `value` a string or number, unique), `value`, `onValueChange(value, option)`, `placeholder` (default "Select"; every default text here is in the app\'s language
|
|
4071
|
+
'Themed picker for ONE value of a known list, or several with `multiple`. `<Select label="Status" value={status} onValueChange={setStatus} options={[{ value: "open", label: "Open" }, { value: "done", label: "Done" }]} placeholder="Choose a status" />` — the default way to let the user pick ONE of a known list. The trigger is the app\'s input field (Design > Components > Inputs) showing the chosen label; pressing it opens the options at SCREEN level, in a sheet painted from Design > Components > Dropdown menus, so no card or scroll container can clip them, and a long list scrolls inside the sheet. The trigger is a button that opens a dialog (expanded state included) and each option carries the option role and its selected state on both hosts; the list around them is a listbox on the web only. On the web Enter, Space or an arrow key opens it, the arrow keys, Home and End move between options, Enter or Space chooses, Escape closes, and focus returns to the trigger; on Android the back button closes it. Props: `options` (`[{ value, label, disabled?, testID? }]`, `value` a string or number, unique), `value`, `onValueChange(value, option)`, `placeholder` (default "Select"; every default text here is in the app\'s language), `title` (the sheet\'s heading; defaults to a text `label`), `emptyText` (default "No options"), `label`, `helper`, `error`, `disabled`, `accessibilityLabel`, `closeAccessibilityLabel`, `background` / `textColor` / `borderColor` / `radius` / `height` to override one field, `style` (the trigger), `containerStyle`, `testID`; any other prop lands on the trigger. Use it rather than a dropdown of your own; when the request needs options it cannot show (colour swatches, photos with two-line captions), put a small swatch or photo picker in a `<Popover>` at its button, or a long or full-screen option list in a `<Modal>` (an emoji choice is `<EmojiPicker>`) — never an absolutely positioned list, which the widget\'s container clips on both hosts. MULTIPLE: `<Select multiple label="Tags" values={tags} onValuesChange={setTags} options={tagOptions} />` — the default way to let the user pick SEVERAL of a known list. The same trigger and sheet; each option shows a tick box and toggles, the listbox is multiselectable on the web, and the sheet\'s Done button commits the choice through `onValuesChange(values, options)` (values in listed order, called only when they changed); closing the sheet any other way (backdrop, Escape, Android back) keeps the previous choice. Space toggles the focused option on the web. The trigger shows the picked labels as small chips while they fit on its one line, otherwise "N selected" (`selectedCountText(count)` to translate it), and `placeholder` while nothing is picked; `doneText` (default "Done") names the button. In this mode `value` / `onValueChange` are ignored. A handful of options always shown inline is a `<ChipGroup selection="multiple">` of `<Chip>`s instead. SEARCHABLE: a long list the user should type to narrow. `searchable` filters the given `options` by label as they type; `onSearch(query)` hands you the trimmed query when the sheet opens (\"\") and once typing pauses (`searchDebounceMs`, default 250), and you answer with new `options` and `loading` meanwhile (`optionsError` when it failed); or pass `options` as an async function of the query and Select fetches, keeping only the latest answer. The sheet then leads with the app\'s search field (Design > Components > Search fields), shows a spinner while loading, `noResultsText` (default \"No results\") when a query finds nothing and `loadErrorText` on failure, and its rows take the Lists row height and padding when the theme sets them. It remembers the label of every option it has shown; pass `selectedOptions` for a saved value the first page may not hold, or the trigger shows the placeholder. An option may carry `leading` (an `<Avatar>`, an icon) drawn before its label. Picking people, groups or a table\'s records is `<PeoplePicker>`, which does all of this for you.',
|
|
4072
4072
|
rnComponent: null,
|
|
4073
4073
|
docsUrl: null,
|
|
4074
4074
|
},
|
|
@@ -5616,33 +5616,235 @@ function sharedTranslationKey(key) {
|
|
|
5616
5616
|
return `${SHARED_TRANSLATION_PREFIX}${key}`;
|
|
5617
5617
|
}
|
|
5618
5618
|
|
|
5619
|
-
// The predefined set. Map of bare key ->
|
|
5620
|
-
// hand because a lone word machine-translates to the
|
|
5621
|
-
// "Avboka")
|
|
5622
|
-
//
|
|
5623
|
-
//
|
|
5624
|
-
//
|
|
5619
|
+
// The predefined set. Map of bare key -> its text in each of the nine app
|
|
5620
|
+
// languages, written by hand because a lone word machine-translates to the
|
|
5621
|
+
// wrong sense ("Cancel" -> "Avboka"). Outside the nine, a base language is
|
|
5622
|
+
// machine-translated at seeding and any other language gets no row, so it
|
|
5623
|
+
// reads the base.
|
|
5624
|
+
// Adding/removing a key is a CONTRACT change (it grows the dictionary every
|
|
5625
|
+
// tenant gets), so the list lives with the contract and the seeder reads it
|
|
5626
|
+
// from here — never a second copy.
|
|
5625
5627
|
const SHARED_TRANSLATION_KEYS = Object.freeze({
|
|
5626
|
-
submit: {
|
|
5627
|
-
|
|
5628
|
-
|
|
5629
|
-
|
|
5630
|
-
|
|
5631
|
-
|
|
5632
|
-
|
|
5633
|
-
|
|
5634
|
-
|
|
5635
|
-
|
|
5636
|
-
|
|
5637
|
-
|
|
5638
|
-
|
|
5639
|
-
|
|
5640
|
-
|
|
5641
|
-
|
|
5642
|
-
|
|
5643
|
-
|
|
5644
|
-
|
|
5645
|
-
|
|
5628
|
+
submit: {
|
|
5629
|
+
en: "Submit",
|
|
5630
|
+
da: "Send",
|
|
5631
|
+
de: "Absenden",
|
|
5632
|
+
es: "Enviar",
|
|
5633
|
+
fi: "Lähetä",
|
|
5634
|
+
fr: "Envoyer",
|
|
5635
|
+
it: "Invia",
|
|
5636
|
+
nb: "Send",
|
|
5637
|
+
sv: "Skicka",
|
|
5638
|
+
},
|
|
5639
|
+
cancel: {
|
|
5640
|
+
en: "Cancel",
|
|
5641
|
+
da: "Annuller",
|
|
5642
|
+
de: "Abbrechen",
|
|
5643
|
+
es: "Cancelar",
|
|
5644
|
+
fi: "Peruuta",
|
|
5645
|
+
fr: "Annuler",
|
|
5646
|
+
it: "Annulla",
|
|
5647
|
+
nb: "Avbryt",
|
|
5648
|
+
sv: "Avbryt",
|
|
5649
|
+
},
|
|
5650
|
+
save: {
|
|
5651
|
+
en: "Save",
|
|
5652
|
+
da: "Gem",
|
|
5653
|
+
de: "Speichern",
|
|
5654
|
+
es: "Guardar",
|
|
5655
|
+
fi: "Tallenna",
|
|
5656
|
+
fr: "Enregistrer",
|
|
5657
|
+
it: "Salva",
|
|
5658
|
+
nb: "Lagre",
|
|
5659
|
+
sv: "Spara",
|
|
5660
|
+
},
|
|
5661
|
+
delete: {
|
|
5662
|
+
en: "Delete",
|
|
5663
|
+
da: "Slet",
|
|
5664
|
+
de: "Löschen",
|
|
5665
|
+
es: "Eliminar",
|
|
5666
|
+
fi: "Poista",
|
|
5667
|
+
fr: "Supprimer",
|
|
5668
|
+
it: "Elimina",
|
|
5669
|
+
nb: "Slett",
|
|
5670
|
+
sv: "Ta bort",
|
|
5671
|
+
},
|
|
5672
|
+
edit: {
|
|
5673
|
+
en: "Edit",
|
|
5674
|
+
da: "Rediger",
|
|
5675
|
+
de: "Bearbeiten",
|
|
5676
|
+
es: "Editar",
|
|
5677
|
+
fi: "Muokkaa",
|
|
5678
|
+
fr: "Modifier",
|
|
5679
|
+
it: "Modifica",
|
|
5680
|
+
nb: "Rediger",
|
|
5681
|
+
sv: "Redigera",
|
|
5682
|
+
},
|
|
5683
|
+
close: {
|
|
5684
|
+
en: "Close",
|
|
5685
|
+
da: "Luk",
|
|
5686
|
+
de: "Schließen",
|
|
5687
|
+
es: "Cerrar",
|
|
5688
|
+
fi: "Sulje",
|
|
5689
|
+
fr: "Fermer",
|
|
5690
|
+
it: "Chiudi",
|
|
5691
|
+
nb: "Lukk",
|
|
5692
|
+
sv: "Stäng",
|
|
5693
|
+
},
|
|
5694
|
+
confirm: {
|
|
5695
|
+
en: "Confirm",
|
|
5696
|
+
da: "Bekræft",
|
|
5697
|
+
de: "Bestätigen",
|
|
5698
|
+
es: "Confirmar",
|
|
5699
|
+
fi: "Vahvista",
|
|
5700
|
+
fr: "Confirmer",
|
|
5701
|
+
it: "Conferma",
|
|
5702
|
+
nb: "Bekreft",
|
|
5703
|
+
sv: "Bekräfta",
|
|
5704
|
+
},
|
|
5705
|
+
back: {
|
|
5706
|
+
en: "Back",
|
|
5707
|
+
da: "Tilbage",
|
|
5708
|
+
de: "Zurück",
|
|
5709
|
+
es: "Volver",
|
|
5710
|
+
fi: "Takaisin",
|
|
5711
|
+
fr: "Retour",
|
|
5712
|
+
it: "Indietro",
|
|
5713
|
+
nb: "Tilbake",
|
|
5714
|
+
sv: "Tillbaka",
|
|
5715
|
+
},
|
|
5716
|
+
next: {
|
|
5717
|
+
en: "Next",
|
|
5718
|
+
da: "Næste",
|
|
5719
|
+
de: "Weiter",
|
|
5720
|
+
es: "Siguiente",
|
|
5721
|
+
fi: "Seuraava",
|
|
5722
|
+
fr: "Suivant",
|
|
5723
|
+
it: "Avanti",
|
|
5724
|
+
nb: "Neste",
|
|
5725
|
+
sv: "Nästa",
|
|
5726
|
+
},
|
|
5727
|
+
previous: {
|
|
5728
|
+
en: "Previous",
|
|
5729
|
+
da: "Forrige",
|
|
5730
|
+
de: "Vorherige",
|
|
5731
|
+
es: "Anterior",
|
|
5732
|
+
fi: "Edellinen",
|
|
5733
|
+
fr: "Précédent",
|
|
5734
|
+
it: "Precedente",
|
|
5735
|
+
nb: "Forrige",
|
|
5736
|
+
sv: "Föregående",
|
|
5737
|
+
},
|
|
5738
|
+
yes: {
|
|
5739
|
+
en: "Yes",
|
|
5740
|
+
da: "Ja",
|
|
5741
|
+
de: "Ja",
|
|
5742
|
+
es: "Sí",
|
|
5743
|
+
fi: "Kyllä",
|
|
5744
|
+
fr: "Oui",
|
|
5745
|
+
it: "Sì",
|
|
5746
|
+
nb: "Ja",
|
|
5747
|
+
sv: "Ja",
|
|
5748
|
+
},
|
|
5749
|
+
no: {
|
|
5750
|
+
en: "No",
|
|
5751
|
+
da: "Nej",
|
|
5752
|
+
de: "Nein",
|
|
5753
|
+
es: "No",
|
|
5754
|
+
fi: "Ei",
|
|
5755
|
+
fr: "Non",
|
|
5756
|
+
it: "No",
|
|
5757
|
+
nb: "Nei",
|
|
5758
|
+
sv: "Nej",
|
|
5759
|
+
},
|
|
5760
|
+
ok: {
|
|
5761
|
+
en: "OK",
|
|
5762
|
+
da: "OK",
|
|
5763
|
+
de: "OK",
|
|
5764
|
+
es: "OK",
|
|
5765
|
+
fi: "OK",
|
|
5766
|
+
fr: "OK",
|
|
5767
|
+
it: "OK",
|
|
5768
|
+
nb: "OK",
|
|
5769
|
+
sv: "OK",
|
|
5770
|
+
},
|
|
5771
|
+
loading: {
|
|
5772
|
+
en: "Loading…",
|
|
5773
|
+
da: "Indlæser…",
|
|
5774
|
+
de: "Wird geladen…",
|
|
5775
|
+
es: "Cargando…",
|
|
5776
|
+
fi: "Ladataan…",
|
|
5777
|
+
fr: "Chargement…",
|
|
5778
|
+
it: "Caricamento…",
|
|
5779
|
+
nb: "Laster…",
|
|
5780
|
+
sv: "Laddar…",
|
|
5781
|
+
},
|
|
5782
|
+
search: {
|
|
5783
|
+
en: "Search",
|
|
5784
|
+
da: "Søg",
|
|
5785
|
+
de: "Suchen",
|
|
5786
|
+
es: "Buscar",
|
|
5787
|
+
fi: "Hae",
|
|
5788
|
+
fr: "Rechercher",
|
|
5789
|
+
it: "Cerca",
|
|
5790
|
+
nb: "Søk",
|
|
5791
|
+
sv: "Sök",
|
|
5792
|
+
},
|
|
5793
|
+
no_results: {
|
|
5794
|
+
en: "No results",
|
|
5795
|
+
da: "Ingen resultater",
|
|
5796
|
+
de: "Keine Ergebnisse",
|
|
5797
|
+
es: "Sin resultados",
|
|
5798
|
+
fi: "Ei tuloksia",
|
|
5799
|
+
fr: "Aucun résultat",
|
|
5800
|
+
it: "Nessun risultato",
|
|
5801
|
+
nb: "Ingen resultater",
|
|
5802
|
+
sv: "Inga resultat",
|
|
5803
|
+
},
|
|
5804
|
+
required: {
|
|
5805
|
+
en: "Required",
|
|
5806
|
+
da: "Påkrævet",
|
|
5807
|
+
de: "Erforderlich",
|
|
5808
|
+
es: "Obligatorio",
|
|
5809
|
+
fi: "Pakollinen",
|
|
5810
|
+
fr: "Obligatoire",
|
|
5811
|
+
it: "Obbligatorio",
|
|
5812
|
+
nb: "Obligatorisk",
|
|
5813
|
+
sv: "Obligatoriskt",
|
|
5814
|
+
},
|
|
5815
|
+
retry: {
|
|
5816
|
+
en: "Retry",
|
|
5817
|
+
da: "Prøv igen",
|
|
5818
|
+
de: "Erneut versuchen",
|
|
5819
|
+
es: "Reintentar",
|
|
5820
|
+
fi: "Yritä uudelleen",
|
|
5821
|
+
fr: "Réessayer",
|
|
5822
|
+
it: "Riprova",
|
|
5823
|
+
nb: "Prøv igjen",
|
|
5824
|
+
sv: "Försök igen",
|
|
5825
|
+
},
|
|
5826
|
+
add: {
|
|
5827
|
+
en: "Add",
|
|
5828
|
+
da: "Tilføj",
|
|
5829
|
+
de: "Hinzufügen",
|
|
5830
|
+
es: "Añadir",
|
|
5831
|
+
fi: "Lisää",
|
|
5832
|
+
fr: "Ajouter",
|
|
5833
|
+
it: "Aggiungi",
|
|
5834
|
+
nb: "Legg til",
|
|
5835
|
+
sv: "Lägg till",
|
|
5836
|
+
},
|
|
5837
|
+
remove: {
|
|
5838
|
+
en: "Remove",
|
|
5839
|
+
da: "Fjern",
|
|
5840
|
+
de: "Entfernen",
|
|
5841
|
+
es: "Quitar",
|
|
5842
|
+
fi: "Poista",
|
|
5843
|
+
fr: "Retirer",
|
|
5844
|
+
it: "Rimuovi",
|
|
5845
|
+
nb: "Fjern",
|
|
5846
|
+
sv: "Ta bort",
|
|
5847
|
+
},
|
|
5646
5848
|
});
|
|
5647
5849
|
|
|
5648
5850
|
// True when `key` is one of the predefined shared keys — the discriminator
|
|
@@ -7277,7 +7479,9 @@ const CONTRACT = deepFreeze({
|
|
|
7277
7479
|
// column is `missing`, as the Studio and preview binders already showed.
|
|
7278
7480
|
// 1.298.0 (sc-18635): additive — `localizedText(entry, locale, values)`
|
|
7279
7481
|
// reads a nine-language text table; `no` and `nn` read `nb`.
|
|
7280
|
-
|
|
7482
|
+
// 1.299.0: behaviour (sc-18751) — the components' default texts and the
|
|
7483
|
+
// shared keys ship all nine app languages, not English and Swedish only.
|
|
7484
|
+
version: "1.299.0",
|
|
7281
7485
|
sharedTranslationKeys: SHARED_TRANSLATION_KEYS,
|
|
7282
7486
|
hooks: HOOKS,
|
|
7283
7487
|
primitives: PRIMITIVES,
|
|
@@ -7887,5 +8091,6 @@ export {
|
|
|
7887
8091
|
sdkText,
|
|
7888
8092
|
fillSdkText,
|
|
7889
8093
|
localizedText,
|
|
8094
|
+
LANGUAGE_ALIASES,
|
|
7890
8095
|
formatDateForDisplay,
|
|
7891
8096
|
};
|