{
  "$schema": "https://next.0build.dev/schema/component.v1.json",
  "accessibility": {
    "aria": [
      {
        "attributes": [
          {
            "name": "aria-expanded",
            "value": "${this.$open}"
          },
          {
            "name": "aria-haspopup",
            "value": "dialog"
          },
          {
            "name": "aria-label",
            "value": "${this.buttonLabel}"
          }
        ],
        "description": "Trigger: `aria-haspopup=\"dialog\"`, `aria-expanded`, labeled by `button-label`.",
        "part": "button"
      },
      {
        "attributes": [],
        "description": "Formatted date text; no ARIA attributes.",
        "part": "button-text"
      },
      {
        "attributes": [],
        "description": "Calendar grid (inherits the calendar accessibility model).",
        "part": "calendar"
      },
      {
        "attributes": [
          {
            "name": "aria-label",
            "value": "${ariaLabel}"
          },
          {
            "name": "role",
            "value": "dialog"
          }
        ],
        "description": "Picker panel: `role=\"dialog\"` labeled by `dialog-label`.",
        "part": "dropdown"
      },
      {
        "attributes": [],
        "description": "Root wrapper; no ARIA attributes.",
        "part": "host-inner"
      },
      {
        "attributes": [],
        "description": "Trigger icon; no ARIA attributes.",
        "part": "icon"
      },
      {
        "attributes": [],
        "description": "Time input; no static ARIA attributes.",
        "part": "time"
      },
      {
        "attributes": [],
        "description": "Time section; no ARIA attributes.",
        "part": "time-wrapper"
      }
    ],
    "notes": [
      "The calendar inside the dropdown keeps the full calendar keyboard model (arrows, PageUp/PageDown, Home/End).",
      "The submitted value is ISO (`YYYY-MM-DD`, with time when enabled); only the display is formatted."
    ]
  },
  "attributes": [
    {
      "default": "'MMMM DD, YYYY'",
      "description": "Display format for the trigger text (default `MMMM DD, YYYY`); the submitted value stays ISO.",
      "from": null,
      "name": "display-format",
      "property": "display-format",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "false",
      "description": "Adds time selection below the calendar.",
      "from": null,
      "name": "with-time",
      "property": "with-time",
      "reflect": false,
      "tokens": null,
      "type": "boolean",
      "values": null
    },
    {
      "default": "'12h'",
      "description": "Time notation when `with-time` is set: `12h` (default) or `24h`.",
      "from": null,
      "name": "clock",
      "property": "clock",
      "reflect": false,
      "tokens": null,
      "type": "'12h' | '24h'",
      "values": [
        "12h",
        "24h"
      ]
    },
    {
      "default": "false",
      "description": "Requires a time before the value commits (with `with-time`).",
      "from": null,
      "name": "require-time",
      "property": "require-time",
      "reflect": false,
      "tokens": null,
      "type": "boolean",
      "values": null
    },
    {
      "default": "false",
      "description": "Selects today's date on initialization when no `value` is given.",
      "from": "BaseCalendarMixin",
      "name": "today",
      "property": "today",
      "reflect": false,
      "tokens": null,
      "type": "boolean",
      "values": null
    },
    {
      "default": "false",
      "description": "Replaces the prev/next month buttons with a month select and a four-digit year input, each with its own stepper buttons.",
      "from": "BaseCalendarMixin",
      "name": "jumpable",
      "property": "jumpable",
      "reflect": false,
      "tokens": null,
      "type": "boolean",
      "values": null
    },
    {
      "default": "0",
      "description": "First day of the week, from 0 (Sunday) to 6 (Saturday).",
      "from": "BaseCalendarMixin",
      "name": "starts-with",
      "property": "starts-with",
      "reflect": false,
      "tokens": null,
      "type": "number",
      "values": null
    },
    {
      "default": "''",
      "description": "Comma-separated ISO dates (YYYY-MM-DD) that cannot be selected.",
      "from": "BaseCalendarMixin",
      "name": "disabled-dates",
      "property": "disabled-dates",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "''",
      "description": "Comma-separated ISO dates (YYYY-MM-DD) rendered with an indicator dot.",
      "from": "BaseCalendarMixin",
      "name": "marked-dates",
      "property": "marked-dates",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "new Date().toISOString().split('T')[0]",
      "description": "ISO date (YYYY-MM-DD) whose month is displayed; defaults to today in UTC.",
      "from": "BaseCalendarMixin",
      "name": "view-date",
      "property": "view-date",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "''",
      "description": "Earliest selectable date (ISO, inclusive).",
      "from": "BaseCalendarMixin",
      "name": "min",
      "property": "min",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "''",
      "description": "Latest selectable date (ISO, inclusive).",
      "from": "BaseCalendarMixin",
      "name": "max",
      "property": "max",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "'short'",
      "description": "Length of the weekday names in the header: `long`, `short`, or `narrow`.",
      "from": "BaseCalendarMixin",
      "name": "weekday-format",
      "property": "weekday-format",
      "reflect": false,
      "tokens": null,
      "type": "'long' | 'short' | 'narrow'",
      "values": [
        "long",
        "short",
        "narrow"
      ]
    },
    {
      "default": "'en-us'",
      "description": "BCP-47 locale for month names, weekday names, and day labels.",
      "from": "BaseCalendarMixin",
      "name": "lang",
      "property": "lang",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "false",
      "description": "Disables the control so it cannot be interacted with.",
      "from": "InputMixin",
      "name": "disabled",
      "property": "disabled",
      "reflect": false,
      "tokens": null,
      "type": "boolean",
      "values": null
    },
    {
      "default": "''",
      "description": "Associates the hidden form input with a form by id, even when the component sits outside that form.",
      "from": "InputMixin",
      "name": "form",
      "property": "form",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "''",
      "description": "Field name for the hidden form input; array values submit as `name[]`.",
      "from": "InputMixin",
      "name": "name",
      "property": "name",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "''",
      "description": "Placeholder text for the control's empty state.",
      "from": "InputMixin",
      "name": "placeholder",
      "property": "placeholder",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "false",
      "description": "Marks the control as required.",
      "from": "InputMixin",
      "name": "required",
      "property": "required",
      "reflect": false,
      "tokens": null,
      "type": "boolean",
      "values": null
    },
    {
      "default": "''",
      "description": "Initial value of the control, synchronized with the hidden form input.",
      "from": "InputMixin",
      "name": "value",
      "property": "value",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "''",
      "description": "Per-instance text overrides as `key: text` pairs, merged over the global `z-i18n` script and the built-in defaults.",
      "from": "Hwc",
      "name": "i18n",
      "property": "i18n",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "''",
      "description": "Floating UI placement options (for example `offset` and `shiftPadding`) parsed as `key: value` pairs.",
      "from": "Hwc",
      "name": "floating",
      "property": "floating",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "false",
      "description": "Skips re-rendering after the first render; an existing `data-host-inner` child is adopted as the rendered DOM.",
      "from": "Hwc",
      "name": "force-prevent-rerender",
      "property": "force-prevent-rerender",
      "reflect": false,
      "tokens": null,
      "type": "boolean",
      "values": null
    },
    {
      "default": "''",
      "description": "Selector or id of an external element or `<template>` whose inner content is cloned in place of an inline `template[data-fn=\"template\"]` child.",
      "from": "Hwc",
      "name": "template",
      "property": "template",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "''",
      "description": "Adds classes to named parts as `key: classes` pairs; a plain string targets the default part.",
      "from": "Base",
      "name": "cls",
      "property": "cls",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    },
    {
      "default": "''",
      "description": "Adds inline styles to named parts as `key: styles` pairs; a plain string targets the default part.",
      "from": "Base",
      "name": "stl",
      "property": "stl",
      "reflect": false,
      "tokens": null,
      "type": "string",
      "values": null
    }
  ],
  "category": "inputs",
  "children": [
    {
      "attributes": [
        {
          "description": "Marks the script as configuration (value: `config`).",
          "name": "data-fn",
          "required": true,
          "values": [
            "config"
          ]
        },
        {
          "description": "Re-parses the configuration when the script mutates.",
          "name": "data-reactive",
          "required": false,
          "type": "boolean"
        }
      ],
      "description": "JSON configuration script parsed by the base class (i18n, cls, stl, floating).",
      "element": "script",
      "id": "config",
      "required": false,
      "selector": "script[data-fn=\"config\"][type=\"application/json\"]"
    },
    {
      "attributes": [
        {
          "description": "Marks the select as the data source (value: `data-source`).",
          "name": "data-fn",
          "required": true,
          "values": [
            "data-source"
          ]
        },
        {
          "description": "Re-parses the options when the select mutates.",
          "name": "data-reactive",
          "required": false,
          "type": "boolean"
        }
      ],
      "children": [
        {
          "attributes": [
            {
              "description": "Group header text; also the default group key.",
              "name": "label",
              "required": true,
              "type": "string"
            },
            {
              "description": "Disables every option in the group.",
              "name": "disabled",
              "required": false,
              "type": "boolean"
            },
            {
              "description": "Overrides the group key used in the parsed data.",
              "name": "data-key",
              "required": false,
              "type": "string"
            },
            {
              "description": "Comma-separated keywords stored with the group's data.",
              "name": "data-keywords",
              "required": false,
              "type": "comma-separated string"
            }
          ],
          "children": [
            {
              "attributes": [
                {
                  "description": "Value carried by this option in the parsed data.",
                  "name": "value",
                  "required": false,
                  "type": "string"
                },
                {
                  "description": "Makes the option non-selectable.",
                  "name": "disabled",
                  "required": false,
                  "type": "boolean"
                },
                {
                  "description": "Marks the option as initially selected.",
                  "name": "selected",
                  "required": false,
                  "type": "boolean"
                },
                {
                  "description": "Extra search terms, comma-separated; searched alongside the label and value.",
                  "name": "data-keywords",
                  "required": false,
                  "type": "comma-separated string"
                }
              ],
              "description": "One option entry within the group.",
              "element": "option",
              "repeatable": true
            }
          ],
          "description": "Groups options under a label.",
          "element": "optgroup",
          "repeatable": true
        },
        {
          "attributes": [
            {
              "description": "Value carried by this option in the parsed data.",
              "name": "value",
              "required": false,
              "type": "string"
            },
            {
              "description": "Makes the option non-selectable.",
              "name": "disabled",
              "required": false,
              "type": "boolean"
            },
            {
              "description": "Marks the option as initially selected.",
              "name": "selected",
              "required": false,
              "type": "boolean"
            },
            {
              "description": "Extra search terms, comma-separated.",
              "name": "data-keywords",
              "required": false,
              "type": "comma-separated string"
            }
          ],
          "description": "One ungrouped option entry.",
          "element": "option",
          "repeatable": true
        }
      ],
      "description": "Hidden select parsed into grouped option data by the base class.",
      "element": "select",
      "id": "data-source",
      "required": false,
      "selector": "select[data-fn=\"data-source\"]"
    },
    {
      "attributes": [
        {
          "description": "Marks the template as an icon source (value: `icons`).",
          "name": "data-fn",
          "required": true,
          "values": [
            "icons"
          ]
        },
        {
          "description": "Re-parses the icons when the template mutates.",
          "name": "data-reactive",
          "required": false,
          "type": "boolean"
        }
      ],
      "children": [
        {
          "attributes": [
            {
              "description": "Icon key referenced by `$icons`.",
              "name": "data-key",
              "required": true,
              "type": "string"
            }
          ],
          "description": "One icon element.",
          "element": "*",
          "repeatable": true
        }
      ],
      "description": "Instance-level icon repository.",
      "element": "template",
      "id": "icons",
      "required": false,
      "selector": "template[data-fn=\"icons\"]"
    },
    {
      "attributes": [
        {
          "description": "Marks the template for deferred mounting (value: `template`).",
          "name": "data-fn",
          "required": true,
          "values": [
            "template"
          ]
        },
        {
          "description": "Re-parses the template when it mutates.",
          "name": "data-reactive",
          "required": false,
          "type": "boolean"
        }
      ],
      "description": "Deferred content template mounted by the base class.",
      "element": "template",
      "id": "template",
      "required": false,
      "selector": "template[data-fn=\"template\"]"
    }
  ],
  "cssClasses": [
    {
      "appliesTo": ".z-datepicker",
      "class": ".z-datepicker-dropdown",
      "description": "The date picker dropdown panel.",
      "role": "element"
    },
    {
      "appliesTo": ".z-datepicker",
      "class": ".z-datepicker-time",
      "description": "The time selection section under the calendar.",
      "role": "state"
    }
  ],
  "cssVars": [
    {
      "affects": [
        "margin-block-start",
        "padding"
      ],
      "default": "1rem",
      "description": "Spacing between the calendar and the time section.",
      "file": "src/css/kit-components/date.css",
      "kind": "base",
      "name": "--z-datepicker-spacing",
      "scope": ".z-datepicker-dropdown",
      "syntax": "<length>"
    }
  ],
  "dataHooks": [
    {
      "appliesTo": "descendant",
      "attribute": "data-host-inner",
      "description": "Marks the rendered inner wrapper so `force-prevent-rerender` can adopt server-rendered DOM without re-rendering.",
      "from": "Hwc",
      "role": "config",
      "values": []
    },
    {
      "appliesTo": "descendant",
      "attribute": "data-part",
      "description": "Marks the dropdown panel in adopted server-rendered DOM (`data-part=\"dropdown\"`).",
      "role": "marker",
      "values": [
        "dropdown"
      ]
    },
    {
      "appliesTo": "descendant",
      "attribute": "data-reactive",
      "description": "Opts the marked child (config script, data source, icons, or template) into live re-parsing when its DOM mutates.",
      "from": "Hwc",
      "role": "config",
      "values": []
    }
  ],
  "events": [
    {
      "bubbles": true,
      "cancelable": false,
      "description": "Fires when the committed date/time changes; `detail.value` carries the ISO value.",
      "detail": {
        "fields": [
          {
            "name": "value",
            "type": "string | string[]"
          }
        ],
        "type": "{ value: string | string[] }"
      },
      "from": "InputMixin",
      "name": "z-input-date:change"
    }
  ],
  "i18n": [
    {
      "default": "Select date",
      "description": "Accessible label of the trigger button.",
      "key": "button-label",
      "placeholders": [],
      "usedIn": []
    },
    {
      "default": "Date picker",
      "description": "Accessible label of the picker dropdown.",
      "key": "dialog-label",
      "placeholders": [],
      "usedIn": [
        "dropdown"
      ]
    },
    {
      "default": "Select a date",
      "description": "Trigger text when no date is selected.",
      "key": "placeholder",
      "placeholders": [],
      "usedIn": []
    },
    {
      "default": "Select a date and time",
      "description": "Trigger text when no date/time is selected and `with-time` is set.",
      "key": "placeholder-with-time",
      "placeholders": [],
      "usedIn": []
    },
    {
      "default": "selected",
      "description": "Suffix announced for the selected day.",
      "key": "selected",
      "placeholders": [],
      "usedIn": []
    }
  ],
  "icons": [
    {
      "builtin": true,
      "configuredBy": null,
      "description": "Default trigger icon.",
      "key": "calendar",
      "usedIn": [
        "icon"
      ]
    }
  ],
  "id": "input-date",
  "inherits": [
    "BaseCalendarMixin",
    "DropdownMixin",
    "InputMixin",
    "Hwc",
    "Base"
  ],
  "keyboard": [
    {
      "action": "Closes the picker dropdown.",
      "keys": [
        "Escape"
      ]
    }
  ],
  "kind": "hwc",
  "methods": [],
  "notes": [
    "Calendar attributes (`min`, `max`, `disabled-dates`, `marked-dates`, `jumpable`, `lang`, …) apply here through the shared calendar base.",
    "The dropdown positions with Floating UI; `floating` tunes offset/shift."
  ],
  "parts": {
    "defaultClsTarget": "button",
    "defaultStlTarget": "button",
    "items": [
      {
        "defaultCls": "",
        "description": "The trigger button showing the formatted date.",
        "foundIn": [
          "render"
        ],
        "key": "button",
        "supportsCls": true,
        "supportsStl": false
      },
      {
        "defaultCls": "",
        "description": "Text span inside the trigger.",
        "foundIn": [
          "render"
        ],
        "key": "button-text",
        "supportsCls": true,
        "supportsStl": true
      },
      {
        "defaultCls": "",
        "description": "The calendar grid inside the dropdown.",
        "foundIn": [
          "render"
        ],
        "key": "calendar",
        "supportsCls": true,
        "supportsStl": true
      },
      {
        "defaultCls": "z-dropdown z-datepicker-dropdown",
        "description": "The floating picker panel (default `z-dropdown z-datepicker-dropdown`).",
        "foundIn": [
          "$cls",
          "render"
        ],
        "key": "dropdown",
        "supportsCls": true,
        "supportsStl": true
      },
      {
        "defaultCls": "",
        "description": "Rendered root wrapper.",
        "foundIn": [
          "render"
        ],
        "key": "host-inner",
        "supportsCls": true,
        "supportsStl": false
      },
      {
        "defaultCls": "",
        "description": "Trigger icon slot (calendar icon).",
        "foundIn": [
          "render"
        ],
        "key": "icon",
        "supportsCls": true,
        "supportsStl": true
      },
      {
        "defaultCls": "",
        "description": "The time input inside the time section.",
        "foundIn": [
          "render"
        ],
        "key": "time",
        "supportsCls": true,
        "supportsStl": true
      },
      {
        "defaultCls": "z-datepicker-time",
        "description": "Time selection section (default `z-datepicker-time`).",
        "foundIn": [
          "$cls",
          "render"
        ],
        "key": "time-wrapper",
        "supportsCls": true,
        "supportsStl": true
      }
    ]
  },
  "recipes": [],
  "related": [
    "calendar",
    "input-time"
  ],
  "schemaVersion": 1,
  "sources": {
    "css": [
      "src/css/kit-components/date.css"
    ],
    "cssSelectors": [
      ".z-datepicker",
      ".z-datepicker-*"
    ],
    "ts": "src/js/hwc/components/input-date.ts"
  },
  "summary": "Date picker combining a trigger button with the calendar dropdown, optional time selection, and formatted display values.",
  "tag": "z-input-date",
  "title": "Date Input"
}
