loon-bulma-react 2025.0.8 → 2025.0.10
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/index.cjs +3 -3
- package/dist/index.d.cts +87 -76
- package/dist/index.d.ts +87 -76
- package/dist/index.js +3 -3
- package/package.json +1 -1
- package/styles/_all.scss +1 -0
- package/styles/datalist.scss +27 -0
package/dist/index.d.cts
CHANGED
|
@@ -1285,12 +1285,26 @@ declare const Notification: {
|
|
|
1285
1285
|
Info(props: StrictOmit<NotificationProps, "color">): react_jsx_runtime.JSX.Element;
|
|
1286
1286
|
};
|
|
1287
1287
|
|
|
1288
|
+
type InputErrorProps = {
|
|
1289
|
+
/** current value */
|
|
1290
|
+
value: InputValueType;
|
|
1291
|
+
/** is deze input 'touched' (gefocused en weer geblurred (unfocused)) */
|
|
1292
|
+
touched: boolean;
|
|
1293
|
+
/** is deze input focused? */
|
|
1294
|
+
focused: boolean;
|
|
1295
|
+
/** is deze input required? */
|
|
1296
|
+
required: boolean;
|
|
1297
|
+
/** is deze input disabled? */
|
|
1298
|
+
disabled: boolean;
|
|
1299
|
+
/** is deze input readonly? */
|
|
1300
|
+
readonly: boolean;
|
|
1301
|
+
};
|
|
1288
1302
|
type InputValueType = string | number | readonly string[] | undefined;
|
|
1289
1303
|
type InputStylingPropsType = {
|
|
1290
|
-
/** grootte van de input (default = `m`, medium) */ size?: SizeProp;
|
|
1291
|
-
/** alignment van de input (default = `l`, left) */ alignment?: AlignmentProp;
|
|
1292
|
-
/** moet het label van de input verborgen worden? (screenreader only) (default = `false`) */ labelHidden?: boolean;
|
|
1293
|
-
/** label boven (`v`) of voor (`h`) de input, (default = `v`, vertical) */ direction?: DirectionProp;
|
|
1304
|
+
/** grootte van de input (default = `m`, medium) */ size?: SizeProp | undefined;
|
|
1305
|
+
/** alignment van de input (default = `l`, left) */ alignment?: AlignmentProp | undefined;
|
|
1306
|
+
/** moet het label van de input verborgen worden? (screenreader only) (default = `false`) */ labelHidden?: boolean | undefined;
|
|
1307
|
+
/** label boven (`v`) of voor (`h`) de input, (default = `v`, vertical) */ direction?: DirectionProp | undefined;
|
|
1294
1308
|
/** (optioneel) icon op de input */ icon?: IconProp | string | undefined | null;
|
|
1295
1309
|
infoData?: string | React$1.ReactNode | ((helptag?: string | undefined) => void) | undefined;
|
|
1296
1310
|
};
|
|
@@ -1299,29 +1313,29 @@ type InputPropsType<T = InputValueType> = {
|
|
|
1299
1313
|
value: string;
|
|
1300
1314
|
label: string;
|
|
1301
1315
|
}>;
|
|
1302
|
-
/** label bij de input. Als geen label, dan wordt de `name`-property gebruikt */ label?: string;
|
|
1316
|
+
/** label bij de input. Als geen label, dan wordt de `name`-property gebruikt */ label?: string | undefined;
|
|
1303
1317
|
/** Wordt er een rood sterretje getoond bij required inputs ? (default = `false`) */ showRequiredOnLabel?: boolean;
|
|
1304
|
-
/** foutmelding bij de input */ errorMessage?: string | ((
|
|
1305
|
-
/** info-melding bij de input */ infoMessage?: string | ((v: InputValueType) => string);
|
|
1318
|
+
/** foutmelding bij de input */ errorMessage?: string | ((s: InputErrorProps) => string) | undefined;
|
|
1319
|
+
/** info-melding bij de input */ infoMessage?: string | ((v: InputValueType) => string) | undefined;
|
|
1306
1320
|
/** helptag in Loon bij de input (`:HOOFDGROEP:SUBGROEP:`) */ helpTag?: string;
|
|
1307
1321
|
/** type input (default = `text`) */ type?: 'text' | 'password' | 'number' | 'email' | 'tel' | 'url' | 'range' | 'date' | 'datetime-local' | 'datetime' | 'month' | 'week' | 'time' | 'color' | 'search' | 'select' | 'file' | 'textarea';
|
|
1308
|
-
/** (optioneel) tooltip-title voor de input. Bij gebruik van `pattern`, kan je hier het gewenste formaat opgeven. */ title?: string;
|
|
1309
|
-
/** (optioneel) id voor de input. Als geen id, dan wordt de `name`-property gebruikt */ id?: string;
|
|
1322
|
+
/** (optioneel) tooltip-title voor de input. Bij gebruik van `pattern`, kan je hier het gewenste formaat opgeven. */ title?: string | undefined;
|
|
1323
|
+
/** (optioneel) id voor de input. Als geen id, dan wordt de `name`-property gebruikt */ id?: string | undefined;
|
|
1310
1324
|
/** name-property voor de input */ name: string;
|
|
1311
|
-
/** waarde voor de input */ value?: T;
|
|
1312
|
-
/** is deze input loading (default = false) */ loading?: boolean;
|
|
1313
|
-
/** gebruikt deze input de spellchecked (default = `false`) */ spellCheck?: boolean;
|
|
1314
|
-
/** is deze input required (default= `false`) */ required?: boolean;
|
|
1315
|
-
/** autocomplete voor deze input (default = `off`) */ autoComplete?: AutoCompleteProp;
|
|
1316
|
-
/** type toetsenbord (voor smartphones) voor deze input (default = `text`) */ keyboardType?: KeyboardTypeProp;
|
|
1317
|
-
/** placeholder in de input */ placeholder?: string;
|
|
1318
|
-
/** is deze input disabled 9default = `false`) */ disabled?: boolean;
|
|
1319
|
-
/** bij welk form hoort deze input? */ form?: string;
|
|
1320
|
-
/** patroon voor de inputs (string of regex). Geef met `title` een gewenst formaat op. */ pattern?: string;
|
|
1325
|
+
/** waarde voor de input */ value?: T | undefined;
|
|
1326
|
+
/** is deze input loading (default = false) */ loading?: boolean | undefined;
|
|
1327
|
+
/** gebruikt deze input de spellchecked (default = `false`) */ spellCheck?: boolean | undefined;
|
|
1328
|
+
/** is deze input required (default= `false`) */ required?: boolean | undefined;
|
|
1329
|
+
/** autocomplete voor deze input (default = `off`) */ autoComplete?: AutoCompleteProp | undefined;
|
|
1330
|
+
/** type toetsenbord (voor smartphones) voor deze input (default = `text`) */ keyboardType?: KeyboardTypeProp | undefined;
|
|
1331
|
+
/** placeholder in de input */ placeholder?: string | undefined;
|
|
1332
|
+
/** is deze input disabled 9default = `false`) */ disabled?: boolean | undefined;
|
|
1333
|
+
/** bij welk form hoort deze input? */ form?: string | undefined;
|
|
1334
|
+
/** patroon voor de inputs (string of regex). Geef met `title` een gewenst formaat op. */ pattern?: string | undefined;
|
|
1321
1335
|
/** Is deze input readonly (default = `false`). Bij `true` zie je alleen nog maar de content van de input */
|
|
1322
|
-
readonly?: boolean;
|
|
1323
|
-
/** moet deze input de focus krijgen? (default = `false`) */ autofocus?: boolean;
|
|
1324
|
-
/** (optionele) `ref` voor gebruik met `React.useRef<HTMLInputElement>` */ inputRef?: React$1.Ref<HTMLInputElement
|
|
1336
|
+
readonly?: boolean | undefined;
|
|
1337
|
+
/** moet deze input de focus krijgen? (default = `false`) */ autofocus?: boolean | undefined;
|
|
1338
|
+
/** (optionele) `ref` voor gebruik met `React.useRef<HTMLInputElement>` */ inputRef?: React$1.Ref<HTMLInputElement> | undefined;
|
|
1325
1339
|
/** max waarde of max lengte voor de input
|
|
1326
1340
|
* _(altijd hoger dan de `min`-prop)_
|
|
1327
1341
|
* @example // voor max waarde
|
|
@@ -1335,7 +1349,7 @@ type InputPropsType<T = InputValueType> = {
|
|
|
1335
1349
|
* @example //strings: voor max length, altijd 0 of hoger
|
|
1336
1350
|
* <Input type="text" max="100"/>
|
|
1337
1351
|
* <Input type="password" max="50"/> */
|
|
1338
|
-
max?: number | WeekInputString | MonthInputString | string;
|
|
1352
|
+
max?: number | WeekInputString | MonthInputString | string | undefined;
|
|
1339
1353
|
/** min waarde of min lengte voor de input
|
|
1340
1354
|
* _(altijd lager dan de `max`-prop)_
|
|
1341
1355
|
* @example <Input type="number" min="1"/>
|
|
@@ -1348,7 +1362,7 @@ type InputPropsType<T = InputValueType> = {
|
|
|
1348
1362
|
* @example //strings: voor max length, altijd 0 of hoger
|
|
1349
1363
|
* <Input type="text" min="100"/>
|
|
1350
1364
|
* <Input type="password" min="50"/> */
|
|
1351
|
-
min?: number | WeekInputString | MonthInputString | string;
|
|
1365
|
+
min?: number | WeekInputString | MonthInputString | string | undefined;
|
|
1352
1366
|
/** stapgrootte voor groter/kleiner aanpassingen
|
|
1353
1367
|
* | type| value | Example|
|
|
1354
1368
|
* |----------------|----------------|---------------------------------------------|
|
|
@@ -1359,28 +1373,28 @@ type InputPropsType<T = InputValueType> = {
|
|
|
1359
1373
|
* | week | `1` (week) | `<Input type="week" step="2"/>` |
|
|
1360
1374
|
* | time | `60` (seconds) | `<Input type="time" step="2"/>` |
|
|
1361
1375
|
* | datetime-local | `1` (second) | `<Input type="datetime-local" step="900"/>` | */
|
|
1362
|
-
step?: number;
|
|
1376
|
+
step?: number | undefined;
|
|
1363
1377
|
/** Voeg extra styles to aan deze input */
|
|
1364
|
-
styles?: React$1.CSSProperties;
|
|
1378
|
+
styles?: React$1.CSSProperties | undefined;
|
|
1365
1379
|
/** Voeg extra classes toe aan deze input */
|
|
1366
|
-
className?: string;
|
|
1367
|
-
optionListId?: string;
|
|
1380
|
+
className?: string | undefined;
|
|
1381
|
+
optionListId?: string | undefined;
|
|
1368
1382
|
/** callback voor unfocus (blur), zet OOK de input op `touched` */
|
|
1369
|
-
onBlur?: (e: React$1.FocusEvent<HTMLInputElement>) => void;
|
|
1383
|
+
onBlur?: (e: React$1.FocusEvent<HTMLInputElement>) => void | Promise<void> | undefined;
|
|
1370
1384
|
/** callback voor onChange. Voor de echte waarde, gebruik je `onValueChanged` */
|
|
1371
|
-
onChange?: (e: React$1.ChangeEvent<HTMLInputElement>) => void;
|
|
1385
|
+
onChange?: (e: React$1.ChangeEvent<HTMLInputElement>) => void | Promise<void> | undefined;
|
|
1372
1386
|
/** value-changed callback met de nieuwe waarde van de input. Kan direct met de `setX()` van `const [x, setX] = React.useState()` worden gebruikt
|
|
1373
1387
|
* @example
|
|
1374
1388
|
* const [x, setX] = React.useState('');
|
|
1375
1389
|
* return <Input value={x} onValueChange={setX} {...props} />
|
|
1376
1390
|
*/
|
|
1377
|
-
onValueChanged?: (e: T) => void;
|
|
1391
|
+
onValueChanged?: (e: T) => void | Promise<void> | undefined;
|
|
1378
1392
|
/** callback voor focus MET daarbij de helptag */
|
|
1379
|
-
onFocus?: (e: React$1.FocusEvent<HTMLInputElement>, helpTag?: string) => void;
|
|
1393
|
+
onFocus?: (e: React$1.FocusEvent<HTMLInputElement>, helpTag?: string) => void | Promise<void> | undefined;
|
|
1380
1394
|
/** callback voor typen */
|
|
1381
|
-
onKeyDown?: (e: React$1.KeyboardEvent<HTMLInputElement>) => void;
|
|
1395
|
+
onKeyDown?: (e: React$1.KeyboardEvent<HTMLInputElement>) => void | Promise<void> | undefined;
|
|
1382
1396
|
/** callback voor typen */
|
|
1383
|
-
onKeyUp?: (e: React$1.KeyboardEvent<HTMLInputElement>) => void;
|
|
1397
|
+
onKeyUp?: (e: React$1.KeyboardEvent<HTMLInputElement>) => void | Promise<void> | undefined;
|
|
1384
1398
|
};
|
|
1385
1399
|
/**
|
|
1386
1400
|
* Basis input component. Deze component heeft dezelfde properties als de gewone `<input ... />`-tag en de `<Input<T> ... />-tag`.
|
|
@@ -1423,7 +1437,7 @@ type InputPropsType<T = InputValueType> = {
|
|
|
1423
1437
|
* | type | `string` | type voor deze input (default = `text`)|
|
|
1424
1438
|
* | value | `string` | value voor deze input (default = `undefined`)|
|
|
1425
1439
|
*/
|
|
1426
|
-
declare function BaseInput<T extends InputValueType = string>({ alignment: alignmentProp, autoComplete, optionListId, autofocus, disabled, errorMessage, infoMessage, form, helpTag, id, inputRef: ref, keyboardType, max, min, name, pattern, placeholder, readonly, required, size: sizeProp, spellCheck, step, title, type, value, className: extraClasses, styles, onBlur, onChange, onFocus, onKeyDown, onKeyUp, onValueChanged, }: StrictOmit<InputPropsType<T>, 'optionList'> & StrictOmit<InputStylingPropsType, 'labelHidden' | 'direction' | 'icon'>): react_jsx_runtime.JSX.Element;
|
|
1440
|
+
declare function BaseInput<T extends InputValueType = string>({ alignment: alignmentProp, autoComplete, optionListId, autofocus, disabled, errorMessage: errorProp, infoMessage: infoProp, form, helpTag, id, inputRef: ref, keyboardType, max, min, name, pattern, placeholder, readonly, required, size: sizeProp, spellCheck, step, title, type, value, className: extraClasses, styles, onBlur, onChange, onFocus, onKeyDown, onKeyUp, onValueChanged, }: StrictOmit<InputPropsType<T>, 'optionList'> & StrictOmit<InputStylingPropsType, 'labelHidden' | 'direction' | 'icon'>): react_jsx_runtime.JSX.Element;
|
|
1427
1441
|
/**
|
|
1428
1442
|
* Input component. Deze component heeft dezelfde properties als de gewone `<input ... />`-tag en de `<BaseInput<T> ... />-tag`.
|
|
1429
1443
|
* Het verschil met de `BaseInput`-tag is dat deze compionent **wel** direction, label, of icon heeft.
|
|
@@ -1465,7 +1479,7 @@ declare function BaseInput<T extends InputValueType = string>({ alignment: align
|
|
|
1465
1479
|
* | type | `string` | type voor deze input (default = `text`)|
|
|
1466
1480
|
* | value | `string` | value voor deze input (default = `undefined`)|
|
|
1467
1481
|
*/
|
|
1468
|
-
declare function Input<T extends InputValueType = string>({ direction: directionProp, errorMessage, showRequiredOnLabel, icon, id, label, labelHidden, name, required, loading, size: sizeProp, value, infoData, helpTag, optionList, onBlur, onFocus, ...props }: StrictOmit<InputPropsType<T>, 'optionListId'> & InputStylingPropsType): react_jsx_runtime.JSX.Element;
|
|
1482
|
+
declare function Input<T extends InputValueType = string>({ direction: directionProp, errorMessage, infoMessage, showRequiredOnLabel, icon, id, label, labelHidden, name, required, loading, disabled, readonly, size: sizeProp, value, infoData, helpTag, optionList, onBlur, onFocus, ...props }: StrictOmit<InputPropsType<T>, 'optionListId'> & InputStylingPropsType): react_jsx_runtime.JSX.Element;
|
|
1469
1483
|
type InputContainerProps = {
|
|
1470
1484
|
label: string;
|
|
1471
1485
|
required: boolean;
|
|
@@ -1477,14 +1491,17 @@ type InputContainerProps = {
|
|
|
1477
1491
|
size: SizeProp;
|
|
1478
1492
|
direction: DirectionProp;
|
|
1479
1493
|
controlClassName?: string;
|
|
1480
|
-
setHovered?: (hovered: boolean) => void;
|
|
1481
1494
|
infoData?: React$1.ReactNode | undefined;
|
|
1495
|
+
setHovered?: (hovered: boolean) => void;
|
|
1482
1496
|
onMouseEnter?: (e: React$1.MouseEvent<HTMLDivElement>) => void;
|
|
1483
1497
|
onMouseLeave?: (e: React$1.MouseEvent<HTMLDivElement>) => void;
|
|
1484
1498
|
};
|
|
1485
1499
|
/** Een wrapper voor een input component, om te zorgen dat ze allemaal op dezelfde manier horizontaal of verticaal aligned worden. */
|
|
1486
1500
|
declare function InputContainer({ children, controlClassName, direction, showRequiredOnLabel, inputId, label, labelHidden, required, size, loading, infoData, setHovered, onMouseEnter, onMouseLeave, }: InputContainerProps): react_jsx_runtime.JSX.Element;
|
|
1487
1501
|
|
|
1502
|
+
type CBErrorProps = StrictOmit<InputErrorProps, 'value'> & {
|
|
1503
|
+
value: boolean;
|
|
1504
|
+
};
|
|
1488
1505
|
type CheckBoxInputProps = StrictOmit<InputPropsType<boolean>, 'value' | 'type' | 'step' | 'pattern' | 'errorMessage' | 'infoMessage' | 'min' | 'max' | 'pattern' | 'placeholder'> & StrictOmit<InputStylingPropsType, 'icon'> & {
|
|
1489
1506
|
/** is de input checked? */
|
|
1490
1507
|
value?: boolean;
|
|
@@ -1492,10 +1509,8 @@ type CheckBoxInputProps = StrictOmit<InputPropsType<boolean>, 'value' | 'type' |
|
|
|
1492
1509
|
label?: string | React$1.ReactNode;
|
|
1493
1510
|
/** kleur voor de checkbox. (default = `p`, primary) */
|
|
1494
1511
|
color?: ColorProp;
|
|
1495
|
-
/** foutmelding bij de input */
|
|
1496
|
-
|
|
1497
|
-
/** foutmelding bij de input */
|
|
1498
|
-
infoMessage?: string | ((c: boolean) => string);
|
|
1512
|
+
/** foutmelding bij de input */ errorMessage?: string | ((s: CBErrorProps) => string);
|
|
1513
|
+
/** info-melding bij de input */ infoMessage?: string | ((v: boolean) => string);
|
|
1499
1514
|
};
|
|
1500
1515
|
/**
|
|
1501
1516
|
* Een checkbox input met een container eromheen. Om een checkbox in te voegen zonder container, gebruik dan de `<CB ... />`-component. DEze component 'wrapt' deze `CB`-component.
|
|
@@ -1510,7 +1525,7 @@ type CheckBoxInputProps = StrictOmit<InputPropsType<boolean>, 'value' | 'type' |
|
|
|
1510
1525
|
* const [x, setX] = React.useState(false);
|
|
1511
1526
|
* <CheckBox name="test" label="test" value={x} onValueChanged={setX} direction='v'/>
|
|
1512
1527
|
*/
|
|
1513
|
-
declare function CheckBox({ id, label, name, size: sizeProp, direction: directionProp, required, showRequiredOnLabel, value,
|
|
1528
|
+
declare function CheckBox({ id, label, name, size: sizeProp, direction: directionProp, required, showRequiredOnLabel, value, labelHidden, helpTag, infoData, onValueChanged, onBlur, onFocus, ...props }: CheckBoxInputProps): react_jsx_runtime.JSX.Element;
|
|
1514
1529
|
/**
|
|
1515
1530
|
* Een checkbox input die nog helemaal zelf aan te passen is, dus zonder container eromheen. Om een checkbox in met wat meer styling te gebruiken, gebruik dan de `CheckBox` component.
|
|
1516
1531
|
* Dat is een wrapper om deze component heen. De properties `type`, `step`, `min`, `max`, `icon`, `pattern`, `placeholder` en `direction` zijn niet van toepassing op deze component.
|
|
@@ -1580,17 +1595,17 @@ type SelectInputProps<T extends number | string | string[]> = StrictOmit<InputPr
|
|
|
1580
1595
|
* const [x, setX] = React.useState('');
|
|
1581
1596
|
* return <Input value={x} onValueChange={setX} {...props} />
|
|
1582
1597
|
*/
|
|
1583
|
-
onValueChanged?: (e: T) => void
|
|
1598
|
+
onValueChanged?: (e: T) => void | Promise<void>;
|
|
1584
1599
|
/** callback voor unfocus (blur), zet OOK de input op `touched` */
|
|
1585
|
-
onBlur?: (e: React$1.FocusEvent<HTMLSelectElement>) => void
|
|
1600
|
+
onBlur?: (e: React$1.FocusEvent<HTMLSelectElement>) => void | Promise<void>;
|
|
1586
1601
|
/** callback voor onChange */
|
|
1587
|
-
onChange?: (e: React$1.ChangeEvent<HTMLSelectElement>) => void
|
|
1602
|
+
onChange?: (e: React$1.ChangeEvent<HTMLSelectElement>) => void | Promise<void>;
|
|
1588
1603
|
/** callback voor focus */
|
|
1589
|
-
onFocus?: (e: React$1.FocusEvent<HTMLSelectElement>, helpTag?: string) => void
|
|
1604
|
+
onFocus?: (e: React$1.FocusEvent<HTMLSelectElement>, helpTag?: string) => void | Promise<void>;
|
|
1590
1605
|
/** callback voor typen */
|
|
1591
|
-
onKeyDown?: (e: React$1.KeyboardEvent<HTMLSelectElement>) => void
|
|
1606
|
+
onKeyDown?: (e: React$1.KeyboardEvent<HTMLSelectElement>) => void | Promise<void>;
|
|
1592
1607
|
/** callback voor typen */
|
|
1593
|
-
onKeyUp?: (e: React$1.KeyboardEvent<HTMLSelectElement>) => void
|
|
1608
|
+
onKeyUp?: (e: React$1.KeyboardEvent<HTMLSelectElement>) => void | Promise<void>;
|
|
1594
1609
|
};
|
|
1595
1610
|
/**
|
|
1596
1611
|
* Select input component (single of multiple). Kan via de `options`-prop, maar ook via `children` worden opgebouwd. Dat gaat met `<Select.Option>` en `<Select.OptGroup>` kan je de opties opbouwen. Dat kan ook gewoon met `<option>` en `<optgroup>`.
|
|
@@ -1666,13 +1681,11 @@ type ComboBoxProps<T extends unknown = {}> = StrictOmit<InputPropsType<number |
|
|
|
1666
1681
|
*/
|
|
1667
1682
|
formatLabel?: (value: T) => string;
|
|
1668
1683
|
/** callback voor calue changes */
|
|
1669
|
-
onValueChanged?: (value: T) => void
|
|
1684
|
+
onValueChanged?: (value: T) => void | Promise<void>;
|
|
1670
1685
|
/** Als we typen in de combobox, hoe moet er gezocht worden? Default doorzoeken we de `JSON.stringify`-string van de objecten */
|
|
1671
1686
|
onSearch?: (searchTxt: string, value: T) => boolean;
|
|
1672
|
-
/**
|
|
1673
|
-
|
|
1674
|
-
/** Een info-message voor de combobox */
|
|
1675
|
-
infoMessage?: string | ((value: T) => string);
|
|
1687
|
+
/** foutmelding bij de input */ errorMessage?: string | ((s: InputErrorProps) => string);
|
|
1688
|
+
/** info-melding bij de input */ infoMessage?: string | ((v: InputValueType) => string);
|
|
1676
1689
|
};
|
|
1677
1690
|
/**
|
|
1678
1691
|
* Een ComboBox is een combi van een `<Select>` en een `<Input>`. Je kan een waarde uit een lijst kieze, maar deze ook intypen.
|
|
@@ -1708,13 +1721,11 @@ type MultiComboBoxProps<T extends unknown = {}> = StrictOmit<InputPropsType<numb
|
|
|
1708
1721
|
/** functie om de waarde in de combobox samen te stellen (als niet-geopend) */
|
|
1709
1722
|
formatValue?: (value: T[]) => string;
|
|
1710
1723
|
/** callback voor calue changes */
|
|
1711
|
-
onValueChanged?: (value: T[]) => void
|
|
1724
|
+
onValueChanged?: (value: T[]) => void | Promise<void>;
|
|
1712
1725
|
/** Als we typen in de combobox, hoe moet er gezocht worden? Default doorzoeken we de `JSON.stringify`-string van de objecten */
|
|
1713
|
-
onSearch?: (searchTxt: string, value: T) => boolean
|
|
1714
|
-
/**
|
|
1715
|
-
|
|
1716
|
-
/** Een info-message voor de combobox */
|
|
1717
|
-
infoMessage?: string | ((value: T[]) => string);
|
|
1726
|
+
onSearch?: (searchTxt: string, value: T) => boolean | Promise<void>;
|
|
1727
|
+
/** foutmelding bij de input */ errorMessage?: string | ((s: InputErrorProps) => string);
|
|
1728
|
+
/** info-melding bij de input */ infoMessage?: string | ((v: InputValueType) => string);
|
|
1718
1729
|
};
|
|
1719
1730
|
/**
|
|
1720
1731
|
* Een MultiComboBox is een combi van een `<Select>` en een `<Input>`. Je kan een waarde uit een lijst kiezen, maar deze ook zoeken door hem in te typen.
|
|
@@ -1836,21 +1847,21 @@ type RadioGroupProps<T extends RBValueType = string> = StrictOmit<InputStylingPr
|
|
|
1836
1847
|
/** foutmelding bij de input */ errorMessage?: string | ((v?: T) => string);
|
|
1837
1848
|
/** info-melding bij de input */ infoMessage?: string | ((v?: T) => string);
|
|
1838
1849
|
/** callback voor unfocus (blur), zet OOK de input op `touched` */
|
|
1839
|
-
onBlur?: (e: React$1.FocusEvent<HTMLInputElement>) => void
|
|
1850
|
+
onBlur?: (e: React$1.FocusEvent<HTMLInputElement>) => void | Promise<void>;
|
|
1840
1851
|
/** callback voor onChange */
|
|
1841
|
-
onChange?: (e: React$1.ChangeEvent<HTMLInputElement>) => void
|
|
1852
|
+
onChange?: (e: React$1.ChangeEvent<HTMLInputElement>) => void | Promise<void>;
|
|
1842
1853
|
/** value-changed callback met de nieuwe waarde van de input. Kan direct met de `setX()` van `const [x, setX] = React.useState()` worden gebruikt
|
|
1843
1854
|
* @example
|
|
1844
1855
|
* const [x, setX] = React.useState('');
|
|
1845
1856
|
* return <Input value={x} onValueChange={setX} {...props} />
|
|
1846
1857
|
*/
|
|
1847
|
-
onValueChanged?: (e: T) => void
|
|
1858
|
+
onValueChanged?: (e: T) => void | Promise<void>;
|
|
1848
1859
|
/** callback voor focus */
|
|
1849
|
-
onFocus?: (e: React$1.FocusEvent<HTMLInputElement>, helpTag?: string) => void
|
|
1860
|
+
onFocus?: (e: React$1.FocusEvent<HTMLInputElement>, helpTag?: string) => void | Promise<void>;
|
|
1850
1861
|
/** callback voor typen */
|
|
1851
|
-
onKeyDown?: (e: React$1.KeyboardEvent<HTMLInputElement>) => void
|
|
1862
|
+
onKeyDown?: (e: React$1.KeyboardEvent<HTMLInputElement>) => void | Promise<void>;
|
|
1852
1863
|
/** callback voor typen */
|
|
1853
|
-
onKeyUp?: (e: React$1.KeyboardEvent<HTMLInputElement>) => void
|
|
1864
|
+
onKeyUp?: (e: React$1.KeyboardEvent<HTMLInputElement>) => void | Promise<void>;
|
|
1854
1865
|
};
|
|
1855
1866
|
type RadioInputProps<T extends RBValueType = string> = StrictOmit<InputPropsType<number | string>, 'id' | 'label' | 'name' | 'type' | 'value' | 'onValueChanged' | 'step' | 'pattern' | 'errorMessage' | 'infoMessage' | 'min' | 'max' | 'placeholder' | 'showRequiredOnLabel'> & StrictOmit<InputStylingPropsType, 'labelHidden' | 'direction' | 'icon'> & {
|
|
1856
1867
|
/** label van de Radio Button. Als niet gedefinieerd, wordt de `name`-prop gebruikt */
|
|
@@ -1858,7 +1869,7 @@ type RadioInputProps<T extends RBValueType = string> = StrictOmit<InputPropsType
|
|
|
1858
1869
|
/** de waarde van de radiobutton */
|
|
1859
1870
|
value: T;
|
|
1860
1871
|
/** callback voor value changed */
|
|
1861
|
-
onValueChanged?(val: T): void
|
|
1872
|
+
onValueChanged?(val: T): void | Promise<void>;
|
|
1862
1873
|
/** id voor de container van de radio-button-items. */
|
|
1863
1874
|
id?: string;
|
|
1864
1875
|
/** worden meerdere radiobuttons gestapeld (v) of naast elkaar weergegeven (default = `h`) */
|
|
@@ -1928,7 +1939,7 @@ type TagsInputProps = StrictOmit<InputPropsType<string>, 'type' | 'step' | 'valu
|
|
|
1928
1939
|
/** lijst van kleuren om te gebruiken bij random colors */
|
|
1929
1940
|
randomColors?: Array<ColorProp | `#${string}`>;
|
|
1930
1941
|
/** value changed callback */
|
|
1931
|
-
onValueChanged?: (v: string[]) => void
|
|
1942
|
+
onValueChanged?: (v: string[]) => void | Promise<void>;
|
|
1932
1943
|
/** max length van de tag-tekst */
|
|
1933
1944
|
maxLength?: number;
|
|
1934
1945
|
/** min length van de tag-tekst */
|
|
@@ -1999,7 +2010,7 @@ type PasswordInputProps = StrictOmit<InputPropsType<string>, 'type' | 'step'> &
|
|
|
1999
2010
|
* @param revealPasswordMsg boodschap bij de checkbox. Default is `Toon wachtwoord`
|
|
2000
2011
|
* @param iconRevealed icon voor ww revealed. Default is `faEye`
|
|
2001
2012
|
*/
|
|
2002
|
-
declare function PasswordInput({ value, autoComplete, icon, name, id, label, required, showRequiredOnLabel, labelHidden, size: sizeProp, direction: directionProp, revealPasswordAllowed, revealPasswordMsg, iconRevealed, errorMessage, infoMessage, infoData, helpTag, onValueChanged, onBlur, onFocus, ...props }: PasswordInputProps): react_jsx_runtime.JSX.Element;
|
|
2013
|
+
declare function PasswordInput({ value, autoComplete, icon, name, id, label, required, showRequiredOnLabel, labelHidden, size: sizeProp, direction: directionProp, revealPasswordAllowed, disabled, readonly, revealPasswordMsg, iconRevealed, errorMessage, infoMessage, infoData, helpTag, onValueChanged, onBlur, onFocus, ...props }: PasswordInputProps): react_jsx_runtime.JSX.Element;
|
|
2003
2014
|
|
|
2004
2015
|
type TextEditorPropsType = {
|
|
2005
2016
|
content?: string;
|
|
@@ -3322,9 +3333,9 @@ type FileInputProps = StrictOmit<InputPropsType<string>, 'type' | 'step' | 'valu
|
|
|
3322
3333
|
*/
|
|
3323
3334
|
formatter?: (value: FileInputValue) => string;
|
|
3324
3335
|
/** callback voor value changes. Bevat het path naar de file(s) en de files in een array. */
|
|
3325
|
-
onValueChanged?: (value: FileInputValue) => void
|
|
3336
|
+
onValueChanged?: (value: FileInputValue) => void | Promise<void>;
|
|
3326
3337
|
/** callback voor value changes. **LET OP:** de files vindt je in `e.target.files` */
|
|
3327
|
-
onChange?: (e: React$1.ChangeEvent<HTMLInputElement>) => void
|
|
3338
|
+
onChange?: (e: React$1.ChangeEvent<HTMLInputElement>) => void | Promise<void>;
|
|
3328
3339
|
};
|
|
3329
3340
|
/**
|
|
3330
3341
|
* Een input voor het selecteren van een bestand. de `value`-prop is een object met daarin de Files en het fake path.
|
|
@@ -3347,13 +3358,13 @@ type FileInputProps = StrictOmit<InputPropsType<string>, 'type' | 'step' | 'valu
|
|
|
3347
3358
|
* **default:** toon de namen van alle geselecteerde bestanden, gescheiden door komma's. Als er geen bestanden zijn, dan de noFilesTxt tonen.
|
|
3348
3359
|
* @param onValueChanged callback voor value changes. Bevat het path naar de file(s) en de files in een array.
|
|
3349
3360
|
*/
|
|
3350
|
-
declare function FileInput({ labelHidden, multiple, placeholder, helpTag, errorMessage, infoMessage, label, disabled, keyboardType, title, name, required, showRequiredOnLabel, spellCheck, id, autoComplete, max, min, readonly, pattern, autofocus, form, inputRef: ref, onBlur, onChange, onFocus, onKeyDown, onKeyUp, onValueChanged, size: sizeProp, alignment: alignmentProp, direction: directionProp, value, icon, boxed, accept, capture, noFilesTxt, chooseFileTxt, infoData, formatter, }: FileInputProps): react_jsx_runtime.JSX.Element;
|
|
3361
|
+
declare function FileInput({ labelHidden, multiple, placeholder, helpTag, errorMessage: errorProp, infoMessage: infoProp, label, disabled, keyboardType, title, name, required, showRequiredOnLabel, spellCheck, id, autoComplete, max, min, readonly, pattern, autofocus, form, inputRef: ref, onBlur, onChange, onFocus, onKeyDown, onKeyUp, onValueChanged, size: sizeProp, alignment: alignmentProp, direction: directionProp, value, icon, boxed, accept, capture, noFilesTxt, chooseFileTxt, infoData, formatter, }: FileInputProps): react_jsx_runtime.JSX.Element;
|
|
3351
3362
|
|
|
3352
3363
|
type CurrencyInputProps = StrictOmit<InputPropsType<number>, 'keyboardType' | 'pattern' | 'value' | 'type' | 'onValueChanged' | 'errorMessage' | 'infoMessage'> & InputStylingPropsType & {
|
|
3353
3364
|
/** waarde van de input. Als number of als number-string-tuple (zoals waarde uit `onValueChanged`) */
|
|
3354
3365
|
value?: number;
|
|
3355
3366
|
/** foutmelding bij de input */
|
|
3356
|
-
errorMessage?: string | ((v:
|
|
3367
|
+
errorMessage?: string | ((v: InputErrorProps) => string);
|
|
3357
3368
|
/** speciale informatie-tekst bij de input */
|
|
3358
3369
|
infoMessage?: string | ((v: number) => string);
|
|
3359
3370
|
/** prefix voo het bedrag (default = `'€ '`) */
|
|
@@ -3371,7 +3382,7 @@ type CurrencyInputProps = StrictOmit<InputPropsType<number>, 'keyboardType' | 'p
|
|
|
3371
3382
|
* const [x, setX] = React.useState<[number, string]>([0, '0']);
|
|
3372
3383
|
* return <MyCurrencyInput value={x} onValueChange={setX} {...props} />
|
|
3373
3384
|
*/
|
|
3374
|
-
onValueChanged?: (value: number) => void
|
|
3385
|
+
onValueChanged?: (value: number) => void | Promise<void>;
|
|
3375
3386
|
};
|
|
3376
3387
|
/** Een input speciaal voor bedragen. Geeft standaard een eur-teken weer met daarachter het ingevoerde bedrag.
|
|
3377
3388
|
* Het bedrag wordt als number-string-tuple opgeslagen, zodat het ook met een `setX()` van `const [x, setX] = React.useState()` kan worden gebruikt.
|
|
@@ -4256,7 +4267,7 @@ type ButtonProps = {
|
|
|
4256
4267
|
* | type | `button, reset, submit` | `button` | type 'button' voor de button |
|
|
4257
4268
|
*/
|
|
4258
4269
|
declare const Button: {
|
|
4259
|
-
({ color: colorProp, size: sizeProp, loading, disabled, fullwidth, styling, type, isStatic, helpTag, onClick, onFocus, onMouseEnter, children: nodes, value,
|
|
4270
|
+
({ color: colorProp, size: sizeProp, loading, disabled, fullwidth, styling, type, isStatic, helpTag, onClick, onFocus, onMouseEnter, children: nodes, value, ...props }: ButtonProps): react_jsx_runtime.JSX.Element;
|
|
4260
4271
|
Static(props: StrictOmit<ButtonProps, "color" | "isStatic" | "onClick" | "onFocus" | "disabled" | "loading">): react_jsx_runtime.JSX.Element;
|
|
4261
4272
|
Primary(props: StrictOmit<ButtonProps, "color" | "isStatic">): react_jsx_runtime.JSX.Element;
|
|
4262
4273
|
Success(props: StrictOmit<ButtonProps, "color" | "isStatic">): react_jsx_runtime.JSX.Element;
|
|
@@ -4283,7 +4294,7 @@ type LinkButtonProps = {
|
|
|
4283
4294
|
* @returns een button die er uit ziet als een link
|
|
4284
4295
|
* @example <LinkButton onClick={handleClick}>Click me!</LinkButton>
|
|
4285
4296
|
*/
|
|
4286
|
-
declare function LinkButton({ fullwidth, children, color,
|
|
4297
|
+
declare function LinkButton({ fullwidth, children, color, onClick, ...props }: LinkButtonProps): react_jsx_runtime.JSX.Element;
|
|
4287
4298
|
type LinkProps = React$1.AnchorHTMLAttributes<HTMLAnchorElement> & {
|
|
4288
4299
|
color?: ColorProp;
|
|
4289
4300
|
/** link / URL */
|
|
@@ -4308,7 +4319,7 @@ type LinkProps = React$1.AnchorHTMLAttributes<HTMLAnchorElement> & {
|
|
|
4308
4319
|
* @returns een link
|
|
4309
4320
|
* @example <Link href="https://www.google.com">Google</Link>
|
|
4310
4321
|
*/
|
|
4311
|
-
declare function Link({ color, href, target, id, rel,
|
|
4322
|
+
declare function Link({ color, href, target, id, rel, children, ...props }: LinkProps): react_jsx_runtime.JSX.Element;
|
|
4312
4323
|
|
|
4313
4324
|
type CalendarType = 'm' | 'v' | 'w' | 'p';
|
|
4314
4325
|
type CalendarHours = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | (number & {});
|