@openwebf/react-cupertino-ui 0.3.19 → 0.3.21

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.d.mts CHANGED
@@ -2246,6 +2246,19 @@ interface FlutterCupertinoCheckboxProps {
2246
2246
  * Semantic label announced by screen readers (not visible in the UI).
2247
2247
  */
2248
2248
  semanticLabel?: string;
2249
+ /**
2250
+ * Fired when the checkbox value changes.
2251
+ * detail = checked state as a boolean.
2252
+ */
2253
+ onChange?: (event: CustomEvent<boolean>) => void;
2254
+ /**
2255
+ * Fired when the checkbox value changes, including tristate transitions.
2256
+ * detail = 'checked' | 'unchecked' | 'mixed'.
2257
+ *
2258
+ * Use this event when you need to distinguish the mixed state,
2259
+ * instead of relying on null.
2260
+ */
2261
+ onStatechange?: (event: CustomEvent<"checked" | "unchecked" | "mixed">) => void;
2249
2262
  /**
2250
2263
  * HTML id attribute
2251
2264
  */
package/dist/index.d.ts CHANGED
@@ -2246,6 +2246,19 @@ interface FlutterCupertinoCheckboxProps {
2246
2246
  * Semantic label announced by screen readers (not visible in the UI).
2247
2247
  */
2248
2248
  semanticLabel?: string;
2249
+ /**
2250
+ * Fired when the checkbox value changes.
2251
+ * detail = checked state as a boolean.
2252
+ */
2253
+ onChange?: (event: CustomEvent<boolean>) => void;
2254
+ /**
2255
+ * Fired when the checkbox value changes, including tristate transitions.
2256
+ * detail = 'checked' | 'unchecked' | 'mixed'.
2257
+ *
2258
+ * Use this event when you need to distinguish the mixed state,
2259
+ * instead of relying on null.
2260
+ */
2261
+ onStatechange?: (event: CustomEvent<"checked" | "unchecked" | "mixed">) => void;
2249
2262
  /**
2250
2263
  * HTML id attribute
2251
2264
  */
package/dist/index.js CHANGED
@@ -449,7 +449,22 @@ var FlutterCupertinoCheckbox = (0, import_react_core_ui11.createWebFComponent)({
449
449
  semanticLabel: "semantic-label"
450
450
  },
451
451
  // Event handlers
452
- events: [],
452
+ events: [
453
+ {
454
+ propName: "onChange",
455
+ eventName: "change",
456
+ handler: (callback) => (event) => {
457
+ callback(event);
458
+ }
459
+ },
460
+ {
461
+ propName: "onStatechange",
462
+ eventName: "statechange",
463
+ handler: (callback) => (event) => {
464
+ callback(event);
465
+ }
466
+ }
467
+ ],
453
468
  // Default prop values
454
469
  defaultProps: {
455
470
  // Add default values here