@webority/ui-react 0.6.4 → 0.6.6
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.
|
@@ -16,15 +16,25 @@
|
|
|
16
16
|
* the caller supplies the node; a glossary-backed app wraps its lookup here).
|
|
17
17
|
* @param {string} [props.helpLabel="More information"] aria-label for the info-tip button.
|
|
18
18
|
* @param {string} [props.type="text"]
|
|
19
|
+
* @param {"sm"|"md"|"lg"} [props.size="md"] Control size — sm/lg opt out of the shared height.
|
|
19
20
|
* @param {string} [props.leftIcon] Icon name
|
|
20
21
|
* @param {string} [props.rightIcon] Icon name
|
|
21
22
|
* @param {() => void} [props.onRightIconClick]
|
|
23
|
+
* @param {string} [props.rightIconLabel] Accessible name for the right-icon button. Defaults to
|
|
24
|
+
* the icon name, which is a poor label but not an absent one.
|
|
22
25
|
* @param {string} [props.unit]
|
|
23
26
|
* @param {string} [props.id]
|
|
24
27
|
* @param {string} [props.name]
|
|
25
28
|
* @param {string} [props.className]
|
|
26
29
|
* @param {string} [props.fieldClassName]
|
|
27
30
|
* @param {boolean} [props.disabled=false]
|
|
31
|
+
* @param {boolean} [props.clearable=false] Show an ✕ button while the field has a value.
|
|
32
|
+
* @param {boolean} [props.showCount=false] Show a live `count / maxLength` under the field.
|
|
33
|
+
* @param {number} [props.maxLength] Character cap; the count turns red as it is approached.
|
|
34
|
+
* @param {import('react').ReactNode} [props.prefix] A bordered box before the input (e.g. ₹, https://).
|
|
35
|
+
* @param {import('react').ReactNode} [props.suffix] A bordered box after the input (e.g. .00, .com).
|
|
36
|
+
* @param {boolean} [props.floatingLabel=false] Label sits inside as a placeholder, then slides up
|
|
37
|
+
* on focus/fill. Opt-in variant; standalone only (no icon/unit/prefix in the same field).
|
|
28
38
|
* @param {import('react').Ref<HTMLInputElement>} [ref]
|
|
29
39
|
*/
|
|
30
40
|
declare const AppInput: import("react").ForwardRefExoticComponent<import("react").RefAttributes<any>>;
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
* @param {string} [props.id]
|
|
15
15
|
* @param {string} [props.name]
|
|
16
16
|
* @param {number} [props.rows=4]
|
|
17
|
+
* @param {boolean} [props.autoGrow=false] Grow the height to fit the content as the user types.
|
|
17
18
|
* @param {string} [props.className]
|
|
18
19
|
* @param {string} [props.fieldClassName]
|
|
19
20
|
* @param {import('react').Ref<HTMLTextAreaElement>} [ref]
|
|
@@ -5,9 +5,21 @@
|
|
|
5
5
|
* @param {string} component the component's public name, for the message
|
|
6
6
|
* @param {object} rest the undeclared props it collected
|
|
7
7
|
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
8
|
+
* ABSENCE OF A WARNING IS NOT PROOF OF CORRECTNESS.
|
|
9
|
+
*
|
|
10
|
+
* A wrong prop whose name happens to be a real HTML attribute cannot be told apart from a
|
|
11
|
+
* deliberate pass-through, so it stays silent. That is not one prop — the allowlist below
|
|
12
|
+
* contains `name`, `title`, `type`, `value`, `width`, `height` and more, so `<ActionIcon
|
|
13
|
+
* name="eye">` (meaning `icon`) and `<AppFoo title="…">` (meaning `label`) both pass
|
|
14
|
+
* unremarked. Silence means "nothing recognisably wrong", never "checked and correct".
|
|
15
|
+
*
|
|
16
|
+
* It also only sees components that MOUNT. A wrong prop inside a modal nobody opened, or a
|
|
17
|
+
* row-action menu on an empty list, produces no warning at all in a dev session — a
|
|
18
|
+
* consumer found five such cases only by checking statically against the shipped types.
|
|
19
|
+
*
|
|
20
|
+
* What it does catch reliably is the shape that has actually bitten: a prop name that is
|
|
21
|
+
* neither the component's API nor a valid attribute — `body`, `icon`, `iconRight`,
|
|
22
|
+
* `iconSize`, `variant` on a component that takes `tone`, `w`/`h`/`r` for
|
|
23
|
+
* `width`/`height`/`radius`, `invalid` for `error`.
|
|
12
24
|
*/
|
|
13
25
|
export default function warnUnknownProps(component: string, rest: object): void;
|