{"_id":"@bentoproject/date-countdown","_rev":"244-9b04d28c93002c53f6edfd79996bc0d4","name":"@bentoproject/date-countdown","dist-tags":{"nightly":"1.2305241828.0","latest":"1.2305051745.1"},"versions":{"1.2110261518.0":{"name":"@bentoproject/date-countdown","version":"1.2110261518.0","description":"AMP HTML amp-date-countdown Component","author":{"name":"The AMP HTML Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":"./web-component","./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"e4bbe5c706c18a2c817265b40388ca4d4771613a","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2110261518.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-KQ/OTtyPxF12+o5zG955LhwyioJXMBGZMOrzfLOhx+dON55xNk+37HynJrgd+jCbG6LpOOJh6w0PXKo/U4j5wQ==","shasum":"4a2ee7c8dc33811e24c8e2491961af1c28c4746c","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2110261518.0.tgz","fileCount":27,"unpackedSize":1876409,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC30wDseiedeTgNI2gbXloeakNLQmtPjZOyiA2TppULagIgYymqPhIXkd4xyJ1no16e4nvspV9u4Ru2BTFQYkfYR6Q="}]},"_npmUser":{"name":"ampprojectbot","email":"bot@amp.dev"},"directories":{},"maintainers":[{"name":"ampprojectbot","email":"bot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2110261518.0_1635445139782_0.3582973473383748"},"_hasShrinkwrap":false},"1.2110252343.0":{"name":"@bentoproject/date-countdown","version":"1.2110252343.0","description":"Bento date-countdown Component","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":"./web-component","./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nThe Bento Date Countdown component displays a countdown sequence to a specified date. The Bento Date Countdown extension provides a list of time parameters. Refer to the [returned time parameters section](#returned-time-parameters) below for more information on the available time parameters.\n\n## Usage\n\n<!--\n### Web Component\n\nTODO(https://go.amp.dev/issue/36619): Restore this section. We don't include it because we don't support <template> in Bento Web Components yet.\n\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n### Preact/React Component\n\nThe examples below demonstrates use of the `<BentoDateCountdown>` as a functional component usable with the Preact or React libraries.\n\n#### Example: Import via npm\n\nInstall via npm:\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n#### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n#### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n#### Props\n\n##### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a\nstandard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n##### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n##### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n##### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n##### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n##### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption.\nSee the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\n(dateParams: DateParams) => JSXInternal.Element\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n### Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n#### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"57e62ecc0e24bc2cd64467dba9d0f9836eea0182","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2110252343.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-5Us0Aowqagkm3gJjjuypPynKpVYBinV75OL9nRKmXtfabQwfhScQR88JcYj6hYG4EsZ9R+RiO+epBCmxYCf1eQ==","shasum":"15c0d3c9ce62f0e794c1491bd0a0f993e159b4fc","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2110252343.0.tgz","fileCount":27,"unpackedSize":1876395,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFsIbtNUCuUUqgH3ALIcMU8PoYGZQQUEj4QlTT9pHoXEAiAmtuYp60PQIyQ0GOAZd6GjdKQ561jSCepiLYolWzoe5A=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"ampprojectbot","email":"bot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2110252343.0_1635457668173_0.9290502646319576"},"_hasShrinkwrap":false},"1.2110281959.0":{"name":"@bentoproject/date-countdown","version":"1.2110281959.0","description":"Bento date-countdown Component","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":"./web-component","./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nThe Bento Date Countdown component displays a countdown sequence to a specified date. The Bento Date Countdown extension provides a list of time parameters. Refer to the [returned time parameters section](#returned-time-parameters) below for more information on the available time parameters.\n\n## Usage\n\n<!--\n### Web Component\n\nTODO(https://go.amp.dev/issue/36619): Restore this section. We don't include it because we don't support <template> in Bento Web Components yet.\n\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n### Preact/React Component\n\nThe examples below demonstrates use of the `<BentoDateCountdown>` as a functional component usable with the Preact or React libraries.\n\n#### Example: Import via npm\n\nInstall via npm:\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n#### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n#### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n#### Props\n\n##### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a\nstandard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n##### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n##### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n##### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n##### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n##### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption.\nSee the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\n(dateParams: DateParams) => JSXInternal.Element\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n### Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n#### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"55fa3e004e2aeece5faf9a68717228077c215a13","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2110281959.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-bF1wUIold6YYRAHE3tY/peQG8/KWXzeEbuqFqIpHbdbUwR8e+UYvW/SDZX0N+7EAQLcxWcI5TLwAi9tDE/BmSg==","shasum":"d1f0737fcf08c4ce68c23a32e6982a3897e31a7a","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2110281959.0.tgz","fileCount":27,"unpackedSize":1876395,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGkmh8ngO8URBPa6yBf4PUsqr5GYiO81GJLuIlP2UsSKAiEAq8uDi47FwLzNFqW3FAgzGWgNHezxROjlIDry1RhHSAg="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"ampprojectbot","email":"bot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2110281959.0_1635508311400_0.5986600295942255"},"_hasShrinkwrap":false},"1.2110290545.0":{"name":"@bentoproject/date-countdown","version":"1.2110290545.0","description":"Bento date-countdown Component","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":"./web-component","./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nThe Bento Date Countdown component displays a countdown sequence to a specified date. The Bento Date Countdown extension provides a list of time parameters. Refer to the [returned time parameters section](#returned-time-parameters) below for more information on the available time parameters.\n\n## Usage\n\n<!--\n### Web Component\n\nTODO(https://go.amp.dev/issue/36619): Restore this section. We don't include it because we don't support <template> in Bento Web Components yet.\n\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n### Preact/React Component\n\nThe examples below demonstrates use of the `<BentoDateCountdown>` as a functional component usable with the Preact or React libraries.\n\n#### Example: Import via npm\n\nInstall via npm:\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n#### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n#### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n#### Props\n\n##### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a\nstandard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n##### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n##### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n##### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n##### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n##### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption.\nSee the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\n(dateParams: DateParams) => JSXInternal.Element\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n### Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n#### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"1cc07336e186d25fc5fbfb2e8f7e12c4a5c79fe9","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2110290545.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-Gblemwg3ghDPa+L48/c1wxFw1GyoQlbkLwPggxVfSpVSLoxsMhgPum3zMmcz8rUKz6kNxt/OCd9bI05dE2fw8g==","shasum":"4cf27add2ffd4a4daea25724727a9ea6b4f22874","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2110290545.0.tgz","fileCount":27,"unpackedSize":1876395,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGSLh5g/InQBwXhgQ4XsRdyN13zlReX0BF+eOEfRodBvAiEA0Rvn9fDfUz9a/vrSejF0a4Oiaz+mnR4e1icYhgH4EX4="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"ampprojectbot","email":"bot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2110290545.0_1635592862116_0.34857456079908333"},"_hasShrinkwrap":false},"1.2111011823.0":{"name":"@bentoproject/date-countdown","version":"1.2111011823.0","description":"The Bento Date Countdown component displays a countdown sequence to a specified date.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nThe Bento Date Countdown component displays a countdown sequence to a specified date. The Bento Date Countdown extension provides a list of time parameters. Refer to the [returned time parameters section](#returned-time-parameters) below for more information on the available time parameters.\n\n## Usage\n\n<!--\n### Web Component\n\nTODO(https://go.amp.dev/issue/36619): Restore this section. We don't include it because we don't support <template> in Bento Web Components yet.\n\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n### Preact/React Component\n\nThe examples below demonstrates use of the `<BentoDateCountdown>` as a functional component usable with the Preact or React libraries.\n\n#### Example: Import via npm\n\nInstall via npm:\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n#### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n#### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n#### Props\n\n##### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a\nstandard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n##### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n##### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n##### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n##### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n##### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption.\nSee the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\n(dateParams: DateParams) => JSXInternal.Element\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n### Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n#### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"7bd4192edeb4ded8e78291b094118653b1a78939","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111011823.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-J56o4b+wSAR5iP9p8XgYHIg6paFejvZ64UAHW7Uo5eHBqqgsewqciZwzo6n9DsHhU9qJajn/7NdfsfxxdvdNuQ==","shasum":"2f5a725cfed46af5a122edf0722bbfa55e923c11","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111011823.0.tgz","fileCount":27,"unpackedSize":1876533,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFEr4n1GuH5b84foMLHmxB2Tb+fmFZbsnEGq6On3wn4qAiASoj6Z+0GNy2nSx6hk77xNG/N6Zcf3g92JCdRZF4Skmw=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111011823.0_1635852314971_0.6718865635103768"},"_hasShrinkwrap":false},"1.2110152252.3":{"name":"@bentoproject/date-countdown","version":"1.2110152252.3","description":"The Bento Date Countdown component displays a countdown sequence to a specified date.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"7a44c3f3047d8b5f5bcbcf5a86c4c1cb30184bdc","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2110152252.3","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-OnWMgMSOGv5nOqO+XCUeP2wFcHAb7g20tmuS01Y/QsXb4dyf8nFBpFQi05CXjaix26ZIR+RsNnv2ICS050GSKg==","shasum":"ef894246e73fc846fa64f17bb8488b3db7093378","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2110152252.3.tgz","fileCount":27,"unpackedSize":1876533,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGn5+kxmzOTQ9yKMBDCJtl+L84fGurTGEK4YeTfYLJc7AiBs9dvVXT1xKlHfws5dq3WdfrtzlchXbfjOI6FIk58zkg=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2110152252.3_1635890631402_0.36261351465809777"},"_hasShrinkwrap":false},"1.2110212130.2":{"name":"@bentoproject/date-countdown","version":"1.2110212130.2","description":"The Bento Date Countdown component displays a countdown sequence to a specified date.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"7a44c3f3047d8b5f5bcbcf5a86c4c1cb30184bdc","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2110212130.2","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-CReJjs6UU/XgDqxztOWXloTR5W2dt4v+iAYmnqNzCDpf2r1rKXVYw5C8co0NvhTndGew2y3HWYc01Cyz0kQLeQ==","shasum":"a464c11804b0033209e40e7f7f75ca0ef4bb3251","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2110212130.2.tgz","fileCount":27,"unpackedSize":1876533,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEgDbUdixmUroIgyXyee80LP21sS/MILPuqhmXH1U2xjAiEAo/65xlRSiMfqyN2msQ3qigC4I3M/EWaL5WCjLlnC/Wc="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2110212130.2_1635891254565_0.5770402921960398"},"_hasShrinkwrap":false},"1.2111022043.0":{"name":"@bentoproject/date-countdown","version":"1.2111022043.0","description":"The Bento Date Countdown component displays a countdown sequence to a specified date.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nThe Bento Date Countdown component displays a countdown sequence to a specified date. The Bento Date Countdown extension provides a list of time parameters. Refer to the [returned time parameters section](#returned-time-parameters) below for more information on the available time parameters.\n\n## Usage\n\n<!--\n### Web Component\n\nTODO(https://go.amp.dev/issue/36619): Restore this section. We don't include it because we don't support <template> in Bento Web Components yet.\n\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n### Preact/React Component\n\nThe examples below demonstrates use of the `<BentoDateCountdown>` as a functional component usable with the Preact or React libraries.\n\n#### Example: Import via npm\n\nInstall via npm:\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n#### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n#### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n#### Props\n\n##### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a\nstandard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n##### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n##### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n##### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n##### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n##### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption.\nSee the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\n(dateParams: DateParams) => JSXInternal.Element\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n### Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n#### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"f4d548031e8e20aaea8ade649d3394d56518b769","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111022043.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-3fQE8WM1DcJQfXXyxOW7X6JWaun7yLsPine5/KGbYBVjiNAPXR3IzPy27r0Eph66gxYVwN/+ikTPTGec3NaxPA==","shasum":"87a55f5ae1b7f5e01549ae14e8b9d43f7387942b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111022043.0.tgz","fileCount":27,"unpackedSize":1876533,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIG24fq3MKZKMuNlii6TV8ogP8CFQSaE2Pdb/X6bsEfPGAiBb13P2VeKIQPsosU9muSPYNl+Lmo+vSqnNLY0tUSCZLQ=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111022043.0_1635938506297_0.10782011204748088"},"_hasShrinkwrap":false},"1.2111180040.0":{"name":"@bentoproject/date-countdown","version":"1.2111180040.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"f53cd87e15233c147123f81aad5da820c5581752","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111180040.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-929qmh1MGuMRci9gr6p8f6zyu7EkXgP+/pbSyVRaWaIKlpUe1yIHAbg3sxjGVFuLEKq0BqpEZsyM2DOlniNnPw==","shasum":"74bd7f45b48c5c5a0d9425097238027716162eb7","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111180040.0.tgz","fileCount":27,"unpackedSize":1754671,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhlsUICRA9TVsSAnZWagAASLoQAIeEAisV5eF2SkJD7Fk3\nIkdM5BQHB+5FGf9wQP9sMD7e96/3jD5XK7o9uncw1axu9Zoml9eaFz1+Syvt\nVOEuP5vu1PIWA0WEys0gBs8QsFnwFI7A2Yx5msVYJV79X43fPaPpKePplJWx\nTlPDSXzn9ybINu3VKzKSLlBnqBh8vyOouUVAuZFxFwUym4pW3p5QpR2KlD6x\njorwK0NNkg4rQ5l+lxDgnZOQIeuJH/iF5j0EJyNgx73xa241mzqh0UETYzQI\nb4Ci219GFe/fbT7oZhcNS9ov4muijFQrtSinuFxts+USo13f7bdF4VfZrwhj\nrCwwjoVo+lcsQ/C9dkY1yXaYzDbpioHMYIpw4tONQNHz/23nuytIEFLO0/T5\nkidmHNJWXlps+gsbFvVefa4dzqU5ozNrTZvDecq1PxQyRKoTMh3FjyeqUWHv\nVFre0FCFb4alAzNffhJm9705HYYEbp5Mdko5cDhaKHNs14d028cSrMjeldW3\nIKFprPLeUcYR2kmKn/qcvJNlaCTGxnFT4OM0Po1DXYhr31tVjKHXSDI8xePG\nq56rtDxqrDgrB4KIniMpj/dguizQoNq+KTwCHRME+qkjpNQkXdzcVnLD5GvL\nzXDDI8ZPMjxrvpDnO9iqEemdAYN82HZWhYteIwEZOVux2gOlFHcnHAZfSCbg\nCoEv\r\n=Zvle\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCS2bu6yXT1aPiHUS/CPeC0C7K2HKiAVXJAl4LLfLTTuAIgXl49WIHlg9sYt+bd4Smv3Kljg5jwHVujZpZvfdfX+go="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111180040.0_1637270792153_0.2060913683629646"},"_hasShrinkwrap":false},"1.2111060251.3":{"name":"@bentoproject/date-countdown","version":"1.2111060251.3","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"f53cd87e15233c147123f81aad5da820c5581752","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111060251.3","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-LhR595+/kk3NwUgtLDo4vsfxvPmMOD4Z1Em9rMp1UV18tXATUedspPHocqY+3i6H8iVqIddrc4YS/orABBntXg==","shasum":"c11512cec935f478dcf8e2a06a71d505e3ca77b1","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111060251.3.tgz","fileCount":27,"unpackedSize":1754671,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhlsiRCRA9TVsSAnZWagAAH0UP/iaZSQJ7CZR+B2Sw4DEv\ncYzycmjr7OUb079gAvXrF5WSeGdwok8G5fuFCBmyZxflo46QZ7okQhvu/7p1\nTr4EljdBKfX3TUiSbvXM4Kj5q66ObR7paj/4MQ5zy5qNOowmF8w+YJeo4xei\nu0Dx/3GE3bn9lRUmwJPvtCjAcbcolk/MQnxSk/bLWamLYyaTN4RLS8uldXxw\n+9wj7dwYKKDPFL2dgtd4ZjzkkbXDruPyQNUWnemTCsXl4sK1v30id+V6t+u/\ntCcvsJFDDzwwS/boLcpylWv9gTWSQcBO2F/3Q8NbrLPq18kVNCR+wCGCMAmC\n6xLps1j+zJUgIe4YdpDcwJUtUNwa0jvmFRzrhuYVVOqHYbUlr2M/5q6BPcVS\ntQoC520Su2DGLKWYL3nXVZAvQUbu0+pu/mv/uhmiT80NJ+VBpUJ5HSCkNe1q\nnhewXDb9nm2PetusIQXYV/mtmsv5jGqZMXWCKElyWfntLJ2TJnSsw6nNbKHp\n9d0qLrwedPYBsoB3AJmtx1NyK5yGSXPyo7hvO+4ePFEKR1e03t38t1xGrXbr\nq/oFJNqUPX+hVafILn0lhLIHf6sKELBAqEaYURFoU3ZZ2dELHAOD30vvIzjP\nbjKWJCMCpvghhcpywyGaDEAyDq0/mxRYwlj5DisWv6VvnkxPI0NDK5QaYr/I\nvTJ8\r\n=Zww3\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDrayzhAtGSCxU4WUQlPb5FU6td9o9t4fB12OcgUpvkhgIgM2PxLlvEQBWdSwmnkCgdfZKSDhBon4oG1XVy5gCBC7U="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111060251.3_1637271696952_0.8059615007055598"},"_hasShrinkwrap":false},"1.2111182332.0":{"name":"@bentoproject/date-countdown","version":"1.2111182332.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"34ebd943d9b16506b7a515b38941fdd8357bd288","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111182332.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-wj5XgsixFxX2uNrRkJzah/5aBlVi1c6FNOofRCKoxhUtRuGU0R0X7iQE+U1s89IGnmm5+NAf/9SmVyZhch81sw==","shasum":"f109944e1e2ea9829d7da8cdb22c791e4296439e","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111182332.0.tgz","fileCount":27,"unpackedSize":1767319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhl5eSCRA9TVsSAnZWagAAJbMP/A4ttAgb0lCrLelO21XM\nyZ99HlvLPVgsawyi6/mFUUf4RKaxnU2XwdRT0GBCx2pMcymJKFK2WacLQPVj\nPLFvmI8E/BpXyMJBaGYjNMa6tNA+fxS24j5g7vOm3w2lfYNjedKIKtv2xR+g\n07dfuCEW4RmFKZHWIYqKwaNXiynaUeLrH2RT974+MIwj5svucCoEy/iMg7Qg\nmjpVgkskpQhoiplR6H6fYhcEhvx3YUvbTPwx2VIS+gxsR0I0bIRSnGyE29DP\nYmtVfswwBiQmmug+Bs+3cuPuWj8EUw3eYD1VkSFERwfdClnmQ+PPgMXqADQJ\nZnECiknkCeAMEglzmaEjCCsL+Ugr/Vkyq/6zXJIbuKf4hyvQBttI/haDIL5K\n8ndJWytnZ2XpjVzrJJ7I5zHumJMOwCYc2NCwZoY2GabbThu9oX2NE2lkRw0o\nT+h0KrVdvEvg11EYlkkpI2XDHUgh3PsCklAsxlhDbDd3FazBY7ICYAD3Tr9d\nS3EcVL2dvv37JijXDuYO0Gilm0eJN3xvok2whhigIPPqElbOSHBVIP+e6N5K\nQc+1iWZLlzpOnq+80FdAtruGHgD9592sLIBtykUkKyk/YO+Wmrf5TFxKkLXM\nd5LL2pmEEK4x2n0ikWvncrym9YVJWQoHJ/3K/NaOXVdoWb95S8oIxl2B66FH\nI99c\r\n=Alm2\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCkInROOnqVSRCQTaSSoL4tijA7uzQrpiUnosh46s7LcwIgVmTzo8theMr0ai5xbqFJp/+stUjnHwfmnt9gdZZQ2w4="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111182332.0_1637324689882_0.22554346958968852"},"_hasShrinkwrap":false},"1.2111060251.9":{"name":"@bentoproject/date-countdown","version":"1.2111060251.9","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"04e44a3695f8db307eda69f753e10665cfa70fa1","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111060251.9","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-8zFUWEh9MgLZ5i1KX5Eb9eeFZmBv5OLLFUOpcKwPoLF6lzr7c+69WF3uGVGZziUVnXLBQK0+XY4JVfmQj4NRdw==","shasum":"f4586d754fcaf970fda5819b8e268914e2278010","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111060251.9.tgz","fileCount":27,"unpackedSize":1767319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhl9E2CRA9TVsSAnZWagAAc38P/R7kNxdyOzThuLsZB7da\nG8ezmFuvl4CGqwpXd+wriExwfcatjBszuUbZYyJm/Bb2wm+tHbbo//7mnie4\nkyqlK0+YgzbB+vin3pBPHgfmkIPQCjYrqVmOKhtEIlWTcuaKD9y3f73L6BSE\nJup046InKIq8v5asoKUxJ3xvwFjA5LR1ptrAz+bM6Yv+6aV4GmD+IhgNGzB2\nbwHN+WHaGSaiSHDv8aYti9sKKBQf3P154bKqTrwgEUdJhUNA5Bxn44whEaHe\nZrcWlnXWtv/3kEyhD+3IK4cH8kUDBjVlyTt2ClJFE+MxaoqCSI/GvyfzXzlz\nUto4vLGF4fogXgWFnKnUtmobJ+3u4k5PQ7EYeVtQAhsF1DI9+htuBDABb3YE\n9vylwI1UPG7P6pYx214ya0a4D5OaQzWces6jV96iz/Ou2xokEy/PjXZtnh7n\nKvfr/48rqKiSdCfjyK2q9EF542WitLnI2XGRmphsYWqr4fY/8Jy9YQEXyBR4\n0DwOMj16+IeO0N6bbXPbPLSHuo/2CVkUDxq2xjbFUXz0OnqMpwFBsvgF6aiD\n3F+QNPf7tHgwavXGQlj0tehSYIKRe079TSFFcMXUmlaXxPpVSuCaOK/nYovw\nCmSGeOIYTNTTq3FV7uIV5SVgBOEyCO/n+IWKrctJWVi1RACOXIc5ExW5DHHe\nBi/s\r\n=wYKi\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIB6wDUJ1vTMDgiuc3QpI+FZOg553xMpXv3g6nO6P5NehAiEA8CVepHhR2TaHkIaL6Uu/0EPGQS6q+o7YHqn6+NQGMr4="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111060251.9_1637339446486_0.746025594218471"},"_hasShrinkwrap":false},"1.2111191951.0":{"name":"@bentoproject/date-countdown","version":"1.2111191951.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"22d6da19b9e01e75e6b67f54cd425c465822fe8c","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111191951.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-rVhOnhT3uuSDPwZYEvbVQStWcz5QazE2DruOwQ62OAvbw7Eo/Ha2LbxSIQtUMsQZ5QFfa7Axyki2Uz3eiKuyIg==","shasum":"ebc1231aef6cbb5bd3cf79eb0a48ee246d58474b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111191951.0.tgz","fileCount":27,"unpackedSize":1767319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhmOinCRA9TVsSAnZWagAAO+sP/2SundpClWYD4SDe+OLf\nyzo+TO22JG8+4IqJqdHFSzR9RyaymPxCJn/ucZ37Kdj9fmFb0G3zzirOo19w\ncfM5sy6IrHJzzWKpcBSXBj1+3q7avKCYikFoQeawWNldv29tZR0u+pLwI0bH\nz88oQ6+glJrcsZ6B9aTKb6bjyWXIeb0dMD7oBG72V+iagvLtbsQNKi/29E36\nDnQRHIX2vkVmZfebZ8BRTIV/00Tx4DV7bja+xVpx5Ce4pYhJCAoIWOXmrFqU\nla7/MALI7ZIKbAsPOC0ppvkoxhUDwj2SieM/mnNlgjhfjH7OeBjLH+/Te5Pp\npMq++CrDMEHr7XGaRwewmeiF1xZHG0xBu1L8P77SMxPEkTZq7fsMoQ3ZT6Jo\nY179zQpS2n8el0jRy005ZKYqGVYaEQs8t7NEp0hKwrgWHrolXZHO9uqnVWrJ\ndhaQq3ScGT1BuHKwpyS7X+R9zr6pf1LcF4fPNXpSYXqOEEZzIEDbDkfqxDhu\neIyRm4hMDz0oaiqSBEsMXmkW8pbjO3m1WiwK9EmK+ovnXD/xIgIWkbxu1jTF\no1ZFoHvZl1chAL+Cl/1CTMWEjJDAlybCzMTUdk686WWGr6gzyXFMY+yHdbVw\n5Fp5BnsjY/q93ZOKfqN66G2e6rW1IQY9GmrkqwX5ziOKyH/+rstQ7UOLzS82\nK2F6\r\n=bV+r\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCcz/kY+2MNo7gu6JcJiYzX6PhKSzSE+I0OGW1ygtwrBQIhAIdgJNzDABBTwIqAd8kv5aumyvcFo6wXFj2DEaboLEK5"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111191951.0_1637410983441_0.1557467175675109"},"_hasShrinkwrap":false},"1.2111230244.0":{"name":"@bentoproject/date-countdown","version":"1.2111230244.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"d906c0bae3e05aebd88696b9659414f63c1ca45a","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111230244.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-fY25C1NJtQMErZOLV3cbxUpYf6+Ih7VfzKvaWxBuoMJzSwvbRR16zlJxtdrH7mBVY47HRdX84ckVljqw8SNT2Q==","shasum":"6bd9a1721ed5811c0bdb5762acbd7fd0b92f310c","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111230244.0.tgz","fileCount":27,"unpackedSize":1767319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhnN10CRA9TVsSAnZWagAAujAP/RFt1LdSpKolmYCgi9m4\nHuTHGu+TATSJDUOVuY7QpgmoEH/NAY4qPKp7oml5oEWN9mOkkuHd0P+a5hEJ\nvk4U7nCzmP4NruflM9db+bXOeBIfw9a4QaiDnfPPTr8lyE3QPqjI4oSuL32N\nLReYmbrquy4ua/QD8r0ktPqydwxzT4DW4//eC4KZVB+TY+ZWj63WsVYgfK4A\nbamDOHyPqeTebcSeepiKcfozumNN8koBKA45bkio0ARuD7LtJFz6AOo/NQ3+\nP0FiRDO+7Bd2DeqE1la4JIsE5DGboUDb6zSrN8WAKgruY0LkyV0F4PjMfU6+\n/HsO87vcj+VXcM1uYpkYM5kTA0HLlX/8Eaxv4auI0HJoblh5yfy9DiGx7Edx\nQ0nwcwpUXAgr+HBeiaAWzO5wyy4/S4pA2k42YaEYfaC/tnY/ADqqQ9e8vsgO\nHMmq4RAdE5QCfeP/UO4UUDW8kuKNP8IrDvyTlhg8Ss2bWHELAvBSaIW40KIZ\nPTfEq46SyiI/pHF/JYNkkjzzGifiG5fZVheekpsPAkSTEetzjGz1/ojJpIT1\n2s82EWxWwXro6Eu0nfTA1wKCU6/D3CmkV9Uh9xWFiHh0WXiIubPnWYCrwq2l\nqVOTPUAkBCYwPDwK+7wGAde3BXqn+5MqcUqAosa4hMek4h12sytbW1bWvWcZ\nr7H3\r\n=X9OL\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDq5JE4KBNq0wlvIkQ22oAM1k5i3g1l72M2HVyCvpyV1QIgD0mRDoBBwnnM8JR9R6g9k87DCVgWmpN4ulqArWXYHJA="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111230244.0_1637670259832_0.8444787523433332"},"_hasShrinkwrap":false},"1.2111230636.0":{"name":"@bentoproject/date-countdown","version":"1.2111230636.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"46e8f482bf5e3008ef07e950034d194c48317990","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111230636.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-qaQn/Ne2w7rqluhgp4VvpIecKc4BlxR6Q8o2bCoLj/B3UTLSFHLv47/v08YtRvsipMeCV4yUrFNzZ/4kIp4YRA==","shasum":"0d7449333cea5d01b0515004139ae0b2391d2ac9","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111230636.0.tgz","fileCount":27,"unpackedSize":1767319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhni6xCRA9TVsSAnZWagAA9IMP/iz19OEQbWgC+XsOPzxl\ng+SioE7eIdRKHSfopWV8WRyP4tD66qLWrx3ZN4YXuTrG7SqsivyG1j+EezKT\nq3VXcUBcSYwri5bNKFEuMbgIEYSfNxlK8rxvi8DX0PpSIQoeIL08W1iGnUFO\nU31yOMBkLyvgy+KKFOoKjGpBhlawsbaIz4CQL7Yrr1nNh9lx8PVXx3V4aah+\n/jOqe9pSZpMmgOxKbGXEzZ5eNhcGlimOvWpxFqlpCtJNMgbkgEVXu7ElmIzf\niL2iWRpDX4MdsnIVnysUcvZaS60VFmcc09ljganpBJTMAXurVVwjJBB8IS9H\nOdZYrxzx5phTcuRdtuzLfx9eLcjY5GXK+yYNSni4+qVn+czrvY7IMHG/oNX5\nkMoxUC2IJqVbCT8n9tWuztDqEn4Blshbj9KQlxJZnmsa/Rs00t9vzkn3AIWF\nlqEAqS8xRWOJ+nFKNk5plT9Nzgo1Qv3PvJLeZixX7MBTHd7oAIgpgJBIqx42\ntygdXEuEU1jRHMeuJiQ3WO/IGZiZwWak1dnl8XZ9gd+URL1oTeghaErFW6Fx\nzxT5FOMlrKKWyXS3GrvAkA/OvAv+A96KU8GDF1K19Eyxo0hJTftJswJiRaVM\nBkfxBayipvEBKVH0R3ER3IORS0a+qsLRTEr8ovl11EzbY3RtiAhcw/FkHlbA\nKs4H\r\n=w7fP\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIA51+p7lWB2Sju0PADS0JnPvrcl6KcqyHw5Ke/KenAxhAiAlfb7pLBfAK+7MYjqzM3KHBa1VLolB3iQfktspLoEoCQ=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111230636.0_1637756593117_0.0016820420261030034"},"_hasShrinkwrap":false},"1.2111242025.0":{"name":"@bentoproject/date-countdown","version":"1.2111242025.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"b78e8781ff3976b3bff1ba881cf66dd2609b5c07","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111242025.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-xyqLgKu7D/R/FO5jP+bwg3EpRCAPbapoHbIG1Q2a1zfKk2nX8Ihn3zDy563KSCPlzPpxYfG9ADeaBBPbYH1EgA==","shasum":"a4dd6480f019bc34a9e4c46b2f3d22a6ff993573","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111242025.0.tgz","fileCount":27,"unpackedSize":1767319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhn4SJCRA9TVsSAnZWagAA0qAP/jcBD36WRNQODK/8F2uj\ngnROWrXwu6ZQC7QDx3t0sAApZPsrgI3i6qyTrfhgcQmo6x8bWWAwI19RkHBE\nlYkJErvfdA/o+nH+e36ZZQr/x7Sh7JP3pezJzplIvNSBbsuwffgNe1KEBJ5q\nq9UCU7c8W5Z6yKmLUkZZPINqGWWjudWKJpT7eaAr9ZTLl7NasrC4R1e8mA80\nNna/iMEj7ISdjgnjGFvtJj5tjfyL/cDUZzS2SxmU22nhhx1cS/7NE9HYQNGa\noEnp9mQAyQ2tHDJ/0oaoMxuaCXhB9gAwYNyfYgUXresCUx/FBIdF/pynKzF5\n4WC8qRR4Vg5SunR3T1GyzB/Dg4DLskTxIQbsw0sI1uGCZBsiWSYLT/Vn7MYY\nbjmDh4tFDGz58IT5GUy2APxrtEAGK5peIJlEfLaKR6gefe0jSOszlvG+aUKU\ny6cdRIByDvcmXvgSR860kDxLJgWMzOrJ4bbbqVkpF/2orLKE2r5ZbXTQhhCW\nc943vkfqPToIT6sxENqvPr6tgAnYu6FtKOLArJB/BThW+w6LUwH14P8BxFxh\nZDVrAfuUvvldfZjasWwx9WYcP8tm7fdcAw6l9A81axsK5ypf/lo1WoXR7Ehn\nBdynNYSHHCrU1tGfAtpRY0pjgvOLfcUM0TqTTJX/iOC7VuDCsu7+ddEtHZNa\nAMdj\r\n=SUjE\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD+PbZ9qsc8RmDE1ovxloRxTLItsixPZUL7afQQDdA1awIgTEruK/K1YXpSoj932JFfg9lbB4pxam0ws1TuqhCgOo0="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111242025.0_1637844104873_0.3221949625214997"},"_hasShrinkwrap":false},"1.2111292120.0":{"name":"@bentoproject/date-countdown","version":"1.2111292120.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"e938f7c9446e2d1eb0f0f865c0f1ff42a4be76c5","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111292120.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-kFkTgMZAwZklKG4cD1PGVIojP8QUyRcK7bR7/Y2mgRxtux/J4SpfxnUkw9lLdqdimSxYiqTMU8xpMMSl5y49XQ==","shasum":"44bb576d44a02fcffe0825f5e5c7b72c110b9886","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111292120.0.tgz","fileCount":27,"unpackedSize":1767319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhphu4CRA9TVsSAnZWagAAqV4QAJcZEvroz2rkE5rxrPCE\nP7neE/13rzXmxOLCM3cdIlFFRsmrhBR6VfYbA3JY4JBZH5ZLVuCx50rpPrT0\ng+/t9G+vlAmJhYNZgpDsGJWhBx/77TNBecViXr29WrZMiCqzTTLtWLEv2FYk\nQjowku8K3JTVgoxyGsuYPeumrQcbifGlyoEvcaiBtEp56LYcSyU+/ranYUFW\nxfcWH2P13qrEPwHCH+Wy+xoN08qyOOksQMqeY5nOoe525z6as21CgxBmAcI0\ncJ4JqOvtIMILmfDRqNCH5hRGALzQtcPLAike6maDEFmks3o1miN5RXvt+GzP\nZ/dCV4VQKmq2vemVlOXyAMPfQIWzwUJLJqHzUFL7GmsDA+Wd9GlSy1YC3dxe\niWm+CpyLr266qE+IXqsARAqyUmLRLO/h5sJjSfkiltJ0KW4E6rt3lXaPUADk\nxGxmoP5nPosdGJYhDcDakobFuEWLMdhV87ckzN7xFp/gLfckOQG4DMRY7vJC\nB3L2wSqaUuJYRMWPXZEjztrwGjX4+6f455Y+s1G2/VTSFs+hcHmki4+aHn/o\nwGvVnmHunxsTDKWG5+oeoZKyYVy5hXZVWTLBs5OLLbzlXs6rPQq2JtwCmLpG\n5Tq0hFC8s/tZZzlWkzvblXFM9H5STNVgcX/AKO96ArnkdZ2SCknxUPOa5CQ8\nQTgx\r\n=JJo3\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHBfYrOIFsSF8jp5ptdaTaSDHhaTw/C2JjR3Ardr4qxfAiBOMYppY+9h+Yh0ZgsEDCAyOHGSpyWqMwieMSQhFJeBng=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111292120.0_1638276024672_0.3772963206041742"},"_hasShrinkwrap":false},"1.2111152338.2":{"name":"@bentoproject/date-countdown","version":"1.2111152338.2","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"27e204ed206cf75fae0a37d8f110b5fedb45fa7e","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111152338.2","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-A63/p4bV+NqZkaOveFD24x7GAhEvgSh5/KjTLE15JSbvks+u5wHbXauzP5oXyRien7WfbxRjJ61TYBckT1lOGw==","shasum":"259480b0d40330dba232fc50a0bc9bd5e63be256","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111152338.2.tgz","fileCount":27,"unpackedSize":1767319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhpmVDCRA9TVsSAnZWagAAgPQP/2eN6sP9V2ljLO2ZzLxD\n33464Mn3mSgGvrXYozRBhEiH2/NmwOnhxJkWfqHttyx/207mnK7yHIbmMnkJ\nRCz0oYPU1wkeVpM9IaO7PR2C/DQQkdwL5JWdZLzjXp70oBEHINIgbdneIBgz\n7X+FRZybpWWk59DYA/QL7fy+Dzjkl8x6FT+BfTzKw/yXuLfx5TwKDhQPreIM\n9pIjBPvFQ9I8xiTbzeWt7LZvljdL7BcCsKB4SwZX0l2VcrQrwdnD28z1Yme0\nd4BhMZhS1hAmq3bRWJgnuTRlSFqDZPvplpZMF7qBVQNZYhCcrDkJUuKBj7a0\nQUDxhUzgVkdlTg+yHgwYSnGKGT25yPm4MXvw9yPcJU+Nm3BYwlfpx6P3UWAD\nL+WC2HBqgMcg6kc6lmldPWWCaILTX+n/6GmgK66QJkoa/LXId5UfunLjCDag\ncI8OiNHHm6+A0Qo/MiIPOmp6xCxTJ51/EEGz7w1xjLf3ShDlz30VOSLnPzqi\nIF4pnzm6+xOsFfUx8VcbNm/e6OoLJEp/t5Vd6CAnDBPulg9Ax9QZWgd2F4rh\neX/j0emOzI1yBLE/mgNhOtZ6/TiRTTlgZVvwf1nYYAURgHodSy38WWjxaKZ3\n/hiUDu5bwc4U3/sdqOuIwfyEZfym/MMA7fmxImGs5uMv7aWWiZasscYW69zJ\n664+\r\n=NIkn\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDoiDPKzs/KJiea38lTyevfdJUfKZHfbF43301t7PGj6wIhAPR2oPPs2NPmDEIz0z5mHPf/VMj7hNCPnqT3K2nbEkBM"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111152338.2_1638294851305_0.9852526864791824"},"_hasShrinkwrap":false},"1.2112010058.0":{"name":"@bentoproject/date-countdown","version":"1.2112010058.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"6d1060a3a4288fb99047cc700661d589bc9e2a01","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112010058.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-IKegm3Z3UpZGQzZ1ngFJwbUZ9pkhmYI+C8QSgbsguoQSZ58R+0DtPp1lBuWC+NchaUWSuFj95FlCgCNzAGy7lA==","shasum":"9e03ca2ed6f9187e4f87a6f6ac22de0bd9df700f","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112010058.0.tgz","fileCount":27,"unpackedSize":1767591,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhp2gvCRA9TVsSAnZWagAAQvsP/0uieChQ2bFgl5lbx4jN\nFf7Ox1vK9WQ0eKedTHigJHekD3+CTIr/gO7n9JtYmAGT1SySlThTf0bERJ/q\n2J8moK2liAHaX4rFapllH/vD1eZwfZ8l7c+0jONHF2njXesqdTdl5JBI+hZm\nBjYmG3gtI9ur/VCaZOUh9gCcT7cHPlKHVPmlrSf6w6MzVlwYkDoa1P1+v3jJ\ngXKdjCWoTD9jAe3+9PRbJijnz8EYCi9M0DEJkvrmqUgFmCY54Dvle8eCIKvB\ngbR+uCW3Ii5IGl/gG5y+YJkQ3c0TXoCjYw4QnHgxJ1QVW2dAvLOmEhfaNoDn\nj3jl8tOVIicMvo+n6Nno1rjqfhGgY6F3Ioh/SEiZ5sz7kv05FubtpepnwRI4\nSAQK/VTGUd7x70uVWZ+w4zzP74bDOHb5QxeBumpB97iXX2sczhkcMWua6Qc0\n/ybOOWusj8X1mkqW34WGIhsOPhr1FlZCQdCtw2MewfqdjXLftlrTwUk/hW8q\nLyuIKNNo3GwTpd1PS3lmDZgC5V/9X1AHLH/pPKS/sCLJQh0KmHf2S9lbRvJT\nHjrL8qYTGUxG0XKjaIqBd6t02r325RmWZtHYvtRjJ9Iic7o7Ig3I7zOpiCSv\n0ymQGwlT1B4DZVqjMjE+ZvZ1EMgeq2vTzdiF+2xQq9caPsUozYA9tnVWC6rh\nWNoo\r\n=rYdo\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCdViWcRe+3crUtWV/j9dF7rjVWlWik/YyiNH2MYFjsXwIhALSVznKa7JeaBhZ8Qk87mM3J2/+t2D+8oDXlzOoILqhb"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112010058.0_1638361135328_0.23834380997067584"},"_hasShrinkwrap":false},"1.2112012300.0":{"name":"@bentoproject/date-countdown","version":"1.2112012300.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"4ecf84d856583465c1ab59847234535fed16d55a","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112012300.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-+eM9SeVpjk6h5m9UYuVgON9AHo0XkCutz96EfZK4srtzbYf5KSQMN2LXTPtnnrtYaqdw2ERNeSophc1+neJWmg==","shasum":"d6bbf88183441381c20e88a74ce069d0ffac420c","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112012300.0.tgz","fileCount":27,"unpackedSize":1767591,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhqLxMCRA9TVsSAnZWagAATLwP/2cttonA5c3POcfNy10E\n5PtxQnZIqhD0/YwmLE85o0i0Z7yulg8hfdziwuXDiKBQGp0qNi014jq9Vm0R\nM3hLCtLA/wZ+Ghvksner6ghd454Sc7RrzIj5mvgL1bihEd68kDY9/WJJJwEl\nbX5AV8KnTF33EejrF57YLfgBbg/jvTbovs+vYHKerKBbK3NMlUhHWFrhpY62\n/942w0qHkOuvwKLXV12fiwzuLo1CwR2Rt9aD+7Br3e5BtUlCBkOrdTQOJo0L\nIBbSvIujaG09zJidjN8NIQRnQ+Z/3qMkVfd0sqDQwwipn0wn6bgFSBHUN1T+\n1kBYll0WClrTvlPPmP+coAekHCfNFtG+cJEvX37R/nyEqrLvdGTLTlaTB8aQ\nkEsAwYOiMS0b4j1f5/RHaAlJq2gXvBZp5yfKZP+T/b4DXGCIKalhpZJxbfxM\ng+eAGib+hdIxS5GUcBUZdyfU7ONg/oFYy+NN0JIaU6MDu4S6hAPkmEaj16qx\nvw0fcVP5Hz25Zz9B3UTMevx+NhsowgmDXxhznHtYWj+n9HR/wPqTPGJtGr5c\nsKDExJlnOGy2DxrAteNodgAnI7hDwy8solWd9weXnm43w6RKJodtuu9apDPZ\nBrDS3854hZYqjrvtEXH/+LExaLdyJmOqz8aaRdkoSoZZu1t6uc+ZU26FStLA\n74PU\r\n=+qh7\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHzzwYuMeGnYZPc98sIWRmR8mezk863uqrSFdXe9hmUbAiEA07zlEFnKZh1ovlT6n6m5WnEcz/8ozxqSHaAb8obYElk="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112012300.0_1638448203836_0.9669074204119854"},"_hasShrinkwrap":false},"1.2112021656.0":{"name":"@bentoproject/date-countdown","version":"1.2112021656.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"4a66d3f7120b51959ea01867aa68d516d5e0dc36","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112021656.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-H23COT1znyvryuCkecuIoUSUhsYYciHlmPZA6r2hr/yoQpoj3dc+kIFxzoPNGiIIMAMmIWipi/ienb7c7GimyA==","shasum":"4bcca2a90b07cc16fac22c1e07366b35065a744b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112021656.0.tgz","fileCount":27,"unpackedSize":1767591,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhqgvgCRA9TVsSAnZWagAAM/QQAIenuSa8W1WHAnVlfrN6\ny7sB7hxwD0qlj7P5o1Pp96ia8NG/e4wu5vpUOCPgOlLr3vSK9gIi0Pg1vYvj\ngZviz8P4zWJhBMrzzRuRXjVVgP5txskmItWExzHzDwQC2EGsuftE/JP0215Q\nTWX4/UXh2yRCWPAFdISUbELr3IAuGixlQmJNmjqX1+HKmiqUOkP6aNtfgj5v\n5hwTjx3BBJwnrA5wxSXnQudyyXbbM7WV3gefrdUAcHthfX0lJQmSausxnRzb\nr/N28Qh6055gLO+VaDT+i+YhEkz0SCHOHG1WFpQPyJ1t/iMabH02IgrfwJiA\nNdig7CihJsX31rs40u9+R5Nn/DuBSUu2F9oF/OM0/fFOBcdmwhyyUjTcBSGT\n8ThviABXrArTOOi8b415GmVJnz2gUGhtOfmgONkx77FNG5wzs4W8NANVg24h\nkI3qSNQ5i3auWG84Gl/sxxKqK0eH8XtT63OTaAJKCxrfJ/+fpnD6iz2Ql/1J\nc9dBS4MJB9zohPdJ2r97sAOrYeVH5Ljhadq+l0IXuLdx3NDZvSTDjNUESHnC\ns6cXugYPqFqQkGF9XaINJeZAfUCu3sgz9AIAeHhC9hP9uzP36fb28h8VwEHg\nuPcYM44nxHbQm3u7uw+DsJ5mmzmfK0UdW/t7BikQlx5aQEJZsrLjC49AFRZ9\n+CrK\r\n=n7fb\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBw2HVoVRoiw2EUllvLowzJg1G6cJQDfSXW96ZUTQtbsAiEA4KBl5mgIFoKeFY/koaJNuq6h/Ia5gN5yYEOOEoVzqU0="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112021656.0_1638534111951_0.008051540936852897"},"_hasShrinkwrap":false},"1.2112032204.0":{"name":"@bentoproject/date-countdown","version":"1.2112032204.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"80ca53e97f8ac619b78398d429e0031f40cf68c0","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112032204.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-pUDZGFgdy5dJd87wm98ygc0fQd2IzBWqjausrAUCKtPmaY4Rdqmkk3DFAZAK6JJWa3a1JX0qGRe51oTyXtIHMg==","shasum":"2ff7f423388185708ce8737119a4326a90083162","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112032204.0.tgz","fileCount":27,"unpackedSize":1756381,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhq10LCRA9TVsSAnZWagAAUkUQAJ9mCEKZf3F8KOYJfpwY\nI0EorCrcy/MWuTSsj3+phZYXcfaeEvjeXFE/xmEunn5tqUG3Wpis1YRwOMga\n69YTsXpz11qJGR5Mkz/t2Hi54sw1jrtXjchk/jeawk2G/MvHAXEfelZGzt4X\nvGiOiFNsw+AG+Y2xT9ZVFA9FS2yJbWe98oRjyq6KErG0B3usZnbcwSWN06Is\niWk6sbhQ2jFQ5aN20u+lXE8yTfoUZxfwAMCrbs7QEr9hgs3BRv3JCfRQXG0Y\nMIZdicNsRplnRjGEDB82EqvH/XhJ3sf0kF44mvpg2IQnR+2cqsYa6fB3G7wn\nGmC6SA9oLrhV1+r8yPqVq4LOZwmalQGSOIFY9OkEWsi6Xs8nnsyTifwDoNnj\n2K5LiEoRAwj4vt/Kj3/UzDuM9JM7fDKRMn4kfWDKckzeBGz8MJf+uLiEzkv+\n52uE6KLrbSvnTqBoOfP/hOCSLvavtX7/gQyIC21sZzddDMhXVmD1vXQb7JUd\n1CVzK91QLZgzq5uHq+mB88WJZb34w2tOyaF7oEEw6SmlIrJmYBvmqhZRvz2y\nV45Nyr4cUx1THfjEy8wdbMgo+VaD+AKqBgRZ3ResRGF2oX2IlfpUnQ7ZKxGI\n540tmjyyaXiYvnGdT5CVOHuXaGL3HY1i6uXZW2K7Ek2k7wpuUngpFM1LjgFG\nw9P8\r\n=UDww\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAbsvgvh20QwVMXWrEWay/C6bevKwcdVqwVycRwKb5JeAiEAkHCWGuqDqGQ7r3z16Jh2q97PLEWaYc/tkQU14uqH3Eo="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112032204.0_1638620427314_0.30702502767154205"},"_hasShrinkwrap":false},"1.2112062322.0":{"name":"@bentoproject/date-countdown","version":"1.2112062322.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"cddcce65024c209c9420ce0567f525aef4fc971f","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112062322.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-LrSD9s3y+Scgs5qX6UfhToTD8dRMetXLwHCMaSW1weSWCniyVaGS2/cyOn9HMD4vubbmXR0eXWTe5KKJoWfIxA==","shasum":"dadf93060acc16608642889ed89201384213553d","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112062322.0.tgz","fileCount":27,"unpackedSize":1758489,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhr1MjCRA9TVsSAnZWagAAYPwP/jnPUKF3tVDB9sFVZZjx\nt6IAx1rAunm3S+XMeesX/JPcmWAV36i8oGwDl+720vmP9CI07wNAOlJw1AP4\nJikWDuPEunfflvkVeZBFEN0fRZ6shGg+nV5IykeD3nftpFnhAavQnfZodha1\nHQnxck+MKMv3eYqmNEFOZoT8MiOvRJBSslv1dPFqO4GBC4hH3dVfkz6yAycy\nK5LSr7/g+I0/9V9VKbShkwMObHf2mTL15RcYbQ0egKx2aEklDyzjIJHWlyPZ\nFCCvYqwQ+4YTvjM7Uyq9zrIij2p4rhUgzPx0M4tGB1b3DKL4TcigsOnM15H9\nxDg10c/Maq3yr7/YksF5KjzmhpkzfLo49tE6OL4xqRq0E+tSXsQ84nDecHfN\n5KZkp9ZJX/jiJtH6D0J4CvQhihwJvSiDu5BmdV9hjusqZmwF4tpS6uqlf/Ly\nl/w2I4OSVz1ixcS++K41OuReU8OKmtVmCelwKbWWREJHXyVXQbE+dWWWKQ/Z\ntU+C2g4LsGg/Wl1eRjzjKfuJjktteCTULLjioqbGyzyQ1bIjGXdcMUDuE6uZ\nCJLMIE/VG+OvXdx0MGbrPxVMjTAR6i/M/nL1VW+JbtFdg+ThPabExt7Oy5ct\nVas/Cj0apELWErr1Oqvp1qXqVEgKhIW8QaUBUp1ClA0QIPB4U4j7oBbp58r/\np4y2\r\n=WVRi\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDus4m4NtRRQTsFRujxAm2xw2eKVkUEGN5NqAyUO3aa8AiAwI+cx7IIuO0k2kcTHHO67bJeopSX9RJu7PcELC3Wp1Q=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112062322.0_1638880035503_0.7512935536170324"},"_hasShrinkwrap":false},"1.2112062322.2":{"name":"@bentoproject/date-countdown","version":"1.2112062322.2","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"3e8072d191c8771ac14d19f2122bba93b872265b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112062322.2","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-mE29DV79Wyp/DBr0MF4/gERsrbowr/FdW6wj2iNEYTKIpsTjII52FfZpbYp+AhUNoWw5zoIBSjlxWYNZI+UnAQ==","shasum":"39986b00d320e294001ce38fb70a43c47a6af6a5","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112062322.2.tgz","fileCount":27,"unpackedSize":1758489,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhr+AYCRA9TVsSAnZWagAA2QkQAJTfnQHA9dhGkphUrAiy\noK95uNDppOMgqtBgkmmGjG0D32eM0zk/sPc/Wp8uGoL0iLnH2PU0vFMwF4jy\n9xlgq2x22eSKm19kLh+XXQI8xKs307WwlxUHxHLDNGWoPUs8oakmCqGMD4A6\nNw+ahhrP3IjxhsFJdzL9qXrxOZThqE93tCpO6QdaJL3dpJQBpw8/7Siww6Z9\n2tyL9wyj/FXoVqQ31xLxLADQNdYlHfhsFRn3O0Bfvkr9v73yLjpLQeIuCTJP\nCzMvTeC2oanua/ToaU283IVAms/7saNqnOLFFJwUvwYaT2AaT3/DHAltZBE9\nIxuOSGIxbg7yqvl05ubuDEsnjjSBogMSwoFjSfqZR+vzF8l/ewM3Lk+ETDFO\n3VgZk78/XT4e1KHlZJNwAAfXeqW3809TimcOnASzTk6rERO2fbfrxqesTvuB\nKaSD4iPLI0JgHEMBWA6jrcsUqRGCIjjMbpSpmPu02IaWjcxAS9d7FQM1All/\nP4JuS7zI4E1A/au7p4BGJG8rIbnBtNA/MwHPzPEk9k+Oqg4A0I1D9rtw5DNE\nuPl32r3icr87J7Y7gnXIt8aJI9kuo34ZKZej32lvDcxGGW23tv7rb4fZmLS4\nhXmW8wn/xcB1LurqyaqdeCe+sVkXUTaCRA0lw5/hS4sZQMbrbiJeRA8BLCsU\nFmZl\r\n=gXLH\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICrbKU6Pkvtsq30GIG6uJIircarHvp2uzB0dVNQcuSqdAiA++/QRapqkrtKa0Bu9OBvfSHYlgu9yaLRLLllx5Ko5ag=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112062322.2_1638916120086_0.3233067094514168"},"_hasShrinkwrap":false},"1.2112080230.0":{"name":"@bentoproject/date-countdown","version":"1.2112080230.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"6d03180e136b7ae380fb9d5d3d6fd8c0d5b28e04","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112080230.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-M3PEYvKYmaog8wFW51HITITaKUJq+lMgSXDG4DmlOM/lomchyAOyUWl8BzVvT9jlf9MEe0UbQUGuabCSpr9oLg==","shasum":"1a645896747174ba31c7c2936db6571ead35959b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112080230.0.tgz","fileCount":27,"unpackedSize":1758489,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhsLFdCRA9TVsSAnZWagAAVA4QAIEheDxdsrESmHi5ebuV\ngtLPvRjuqucCLkw+T8Ds2mmkLVjU3Jtwv0IsZ04f3xP5NNddflJRGRceWPtI\nLhesPBhc3lgttMICOXghJdxiQ2yBUeVnkdC6dtvvLxnkW9igysR2C8RF8gt2\nXosp0ZzVZl2ANTWdk/AETeQexzJo/c4+nsm6GtjGNGT/uoNNocs22V9bSOGn\nizvbYyeQWCXjy5+m1KdnaglJN7/xjjY+jDeA2cK5icwAZiZPBOMrVKOvqLR3\nxnE0fnQI/wR0NekuwsJAFaoBCHK8JNo+3//ZlFZ5een/b5M0ppVK535JUgxt\n5QeaiTYcr3yZigsw7jQoLjihOxi0MKaf+zkmM8/vKbnd+Pxn5p61uUkAOqQZ\nHKx7F/yM+qTb57cbICrYngVts1Ym+xATWaO4WmIQGZ0GJ2Fhxm5n7ZZLfhbS\nKyCkJcnVrG5pcG1evsfenk3ttaTA5+NvIJvM+Zzu5wn7YRjBUXIAMnwcaxoW\nea3MVQs5lJGy+PDOObDib6eVdsFk7Gwz4aWdECktG6fRD/6kfOshGPGTF0A3\nJWFuquGo79HGrBIUsWh6waRCFVCce6trQSTYbZkP9gkRyuQnkG/sr4E7Rnzb\naAoa7w7ZinhdRiW42+TdsMNB++iZzrwDjYk8bCuXQ4K39sreZwnQbQSdp14d\nOlg2\r\n=4ntg\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIH9KW+O7nNdfR7b7jLvZVNvB6QMeeZnRxA/wId1qfFNEAiEAlXogk1Z4UGWalu3uZcxOYkcD132Wv3HHU+w07rteMQQ="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112080230.0_1638969693419_0.1857722450892818"},"_hasShrinkwrap":false},"1.2112080230.1":{"name":"@bentoproject/date-countdown","version":"1.2112080230.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"6268ef31f81697778937a9d77d4ccda3a561f39f","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112080230.1","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-uUt220IdB71BDW5Dzw+hp9sRkGSmG1+RRLHy4+BDQOjXiX2P3D42omOFi3OTrP2+vYi03w3oPu7yas2xZ89Lwg==","shasum":"53d59c1dbb0cbcbadbaf9ef853f60b4227f8c4c0","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112080230.1.tgz","fileCount":27,"unpackedSize":1758507,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhsNX6CRA9TVsSAnZWagAALAQP/2Dfu4uznNZq5Oi0PubB\ndwLgoFJn4aIh3MZ+0x4VZdX8cDFcHVGRRxK7c7Vfw6DtAIPXaDYdWbpA7KvF\nzZKbBJVmHm04esfB2aQqvZRxw0n1hb+C7Qp5q6XZcpziOSooFAF1WteScyDq\nFt1NOf0RRq5TLJO1MISoIj8tGClTn1nMUvIl0yQPYzMkREVdSZ23VQyMmOQM\nfWlkokgw6bM50CS2Z58I8ei2tZ11cv0z8WSjDtXK3hcEmAJcf7mt0xl5KhZi\n5+HghLoRVi10iaCFFt2JssvzdcOpo9IeZ+ue9z4qct/Q+7OJsEWffo7d3FMQ\nTfPmX/PNM1mHRYRnI5WZmeJ494eAAd4WD+M47Ex6F8O34llNzJgXOwuh6EQA\nErUsXRPcpBTHq40j5ZY7jMpcGxje+kzMHgzAjursccA5hSU7RYKYJYHKolGU\n0MR8HgMHq/k8fBlQMBKsOplTP7+IBZ98gnUXLsGeLBLXivmHtAa4C+1mknKp\nG/rV9fzmhM7pu2AxT5j5cXUR5tUeYNkIObPhrCbJIr74lyBqpj5DeerY+SM1\nFV2/Bhaz6VWNyLaZEC8YI5lKaCK0+wDRbpChuXzSwueVGkbUCZjfeBt5SSgG\nBdjaQ/k+MolccWPZ7xjluHZgrxzZ2/1yhB661WuQ7ZJN+t82t47slay3KLcL\ntfph\r\n=GNN3\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBIU5zubYZH73msCv2VaBEMFQmgPQrcGu4i9fyhYQLGtAiBgDZEp15FgdPB7Xd5IK12o6kkcZKAGq9HbxkrPg5xHHQ=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112080230.1_1638979066476_0.9034395902179995"},"_hasShrinkwrap":false},"1.2112082232.0":{"name":"@bentoproject/date-countdown","version":"1.2112082232.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"b7b1a9f9f7f0773645f4fbcb9a550233900046a0","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112082232.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-Fe+MFG+NzKzvwsMM2SeqNTynpmwpznUznbHrQLWNbHzrjtSeBOECn+3EV+dbiWMLJfswACYWimjc3Ffmi+uTuA==","shasum":"47be2c6b03cf17f7dcbdfe32513b39a7ca9131c0","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112082232.0.tgz","fileCount":27,"unpackedSize":1758507,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhsfpcCRA9TVsSAnZWagAATc0P/ibALigDNs4uErxyOSdr\nBqzMF/Va/7453sPjQFicf0e8umMm9yE3LHxhlGQlhhqqu0EusF8C/e/PfTP6\n0srSjnxhAjF9kFjpw8xLGFr8bjxIwPdJ18qoGFdRi26F+SKx/r6I3pGbIWLs\nQ35RW8dER6xgFrfztQUCjjlJvrAE2X3DfuRYIpVtfHS/N7qoNr6LSvPcPzAY\naXotzGxK6xpMlY6r8xH27ep/SEBms6FUhmiJSJMeIupyUHFeA/nmSP7+rES9\nFeDhMprGFzk9hQ5MQd2KXs/a1zF4e/PXHKR1syZ9yKDisq/OBSmZhvWKogMb\na7AXjPwOh4XsF7yJgo0P4M0tPFYMFpdPETvNcc8Rgpoc1RZsRzaDp5Q5clQF\n1Opdoxaepp88bylRZLC1suJzDyFjoiszuqUlca4Dema2dMF+9FE//tDowzLO\n/l8Zfs9GjM2ll0jIq8+RtgSh23+S36vwQ5uGmwsDcjddluUbjaL63fzzPFxc\n88y93NS5y51Lp7SyqBuSeObnMY19ybvZpV/Jmkzi+kdycvw32Ov3+VkVHJ+T\no3M6GKeT/z5s4UL56NhIA7I77hJhchcrHR3Vx9eYvfylRfC7hDjD+GutJXjK\nTLsi2vGe1lYgdRnktoVTK5F40ZKWHI2Ea4+QDis5Hfr8gLzIiYUSQTEcmFVs\na20p\r\n=H8oe\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEtcfNIY1AhucWIaR1OsDmbdtL0ngrM6Pu4flWO122+BAiEA3LyWThrtPbjb50UWhUv53Clne69qugqbMmOc8ODRBGA="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112082232.0_1639053916566_0.14965329609388922"},"_hasShrinkwrap":false},"1.2111242025.1":{"name":"@bentoproject/date-countdown","version":"1.2111242025.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"b65dbd2c132f8cee302c477f3a52cb864a79663a","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2111242025.1","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-3hzBD/2oh6MeEoNzlmIJ/6O7rqoqkumXr7YiA6darzJ3oRgl5Rf1uQFIXdu6W5u62SfEb3x9KCeJkjRkNd12ug==","shasum":"236702e311c515adb1273904e4631f09189ba9e5","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2111242025.1.tgz","fileCount":27,"unpackedSize":1723295,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhspscCRA9TVsSAnZWagAAPccP/2UTDf1oUR9s0R1qsSlU\n6k0i5kh/sUhuLPf/bV0KsDwmILsc5HiiA5hMJweJY+iNjkTY3kcBGCLhLhjN\niHfaxoOQIeCnea8SbHR/Tke5qXqHI4Usf5RAMNh8y+5JMyYSx04cxhVIXyFB\nTSKquTRcI5SBqMr4wBfp4IWmI258hFYoGouWw+Wsga0uYs9GVA1VH+SAjySI\nsxltn72t06pRZW42oL+WahbscFk5NxI1TjKqIltNkiVLMHWHPHYPFvMp8J3J\n84Nk6aqNoWadTHlO8WRmVyt+pEfa1prliAQyI5M2clITX/7IHnT5Vmyg371v\nV2Qx7UPI06q7dgdl+QwxmxQVnNQQc0md2PfiXbuF5YgEO45mtv4xM0TgwViR\nj83Cdi1chRGBuT/e2w5xzTx/SUtrWcZneeR2iJQXUoH8VMS4RhRnzuCSGz59\nu3Gk6VQSv3YkyiQLjFrbMehawz4oWAOb74bjarqoo1Wl7qnL0CcV9sR5V0uV\n2HP/d15aJ4SEh50Dn0BYoy2vEoNcrQWH6Duf749cdha5OWPvqCYR0PqUwLDp\ngChzTZIgQWTuhoqOUz2unrahv+Q5zRumHg5JcTne/TuWqLYj6k23kR47amkG\nd7rLlqcNPFDR0D/dnjoHz1ZmbzkElMC4Ybhaj2VJcNPdeFkMEKqi9ME0h8qS\nLVke\r\n=8Nw2\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCNossdkqsCWRuRlaeB9QeeoqeeQNtwGbhRnyM1jBl62wIgE72hm0C5OFj9yUc21JDrURPiX1oeeTg8h2jRsc4gnbM="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2111242025.1_1639095068032_0.2849618399340803"},"_hasShrinkwrap":false},"1.2112091956.0":{"name":"@bentoproject/date-countdown","version":"1.2112091956.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"b65dbd2c132f8cee302c477f3a52cb864a79663a","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112091956.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-IbezGHjp6lw4mk5Ld7+RJ+P2xf53wSqyQLoembYwquWh8mdBThRWbbMEAmKFVWCEKyYKoW66db5/S2GgFGC7Qw==","shasum":"8251280db9f2448441025a97798b6785bb0575e3","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112091956.0.tgz","fileCount":27,"unpackedSize":1723295,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhs0wECRA9TVsSAnZWagAAXDEP/1zQFT7PxG/gIicg9jXx\n1oUhR4Ie4iWxQi13e4HwpeDcj31/TLHQlC20XwdZo48yTUxYzDG9wZ2+3izE\noFMTbs4+qI6qpNR9qJzkCzHpZe7uERbmydMD4Y/lIT2yMg5qQwyaIM62BoNw\nMIk/9zHhVZd/BQ/IFzfoWYKEystfyN50ybZcRZ4t5BMu+mJv78ThPcaipn5m\nkO1pmkrnM95lXP1aK+KjPPys9yfwdCvL4VSMNXpHByUEodQjC6UyzI4f9VNi\n31pJGL4oK88ABYKzgHzxrSWBaeQjJmSZ4TtIzb2AjYxr0qMcgLXajVpV0VYv\njmW6Ouj3tuoMWRaCzhzW6ekQoYiAx5s18m5UTEr7Zi4TXAB1AJFWjtvSuYTz\noIVFY7s2eNH/BX5t+/3MQ5TNg9YNxHjkJMnLmRo/Bxnh2fagSiQLpQoLaY0X\n6tMB1xkuTCAjgHno7ZUaRiZvSJbsgNpyPFKO2VP2/c2muL/miZZbv01mOlwD\nCX1punN9SRYe0nftzGIKOkpPaEUIngrCxu5W1oWLupyiVenR/gCh/GEZJRvq\n2sVTBf50XThhYQjtwTmw2HgddG+SAao/BLeu8MrL6YrUtZi0g78Ye0XpqZsP\nKdt/lUlyy88U+9WxTaxkWPGSlHijq2UdUJGveTUt5Dk/28+gslB9JJ3wXVUh\n2dWS\r\n=EKnE\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEMCID1wj3VMvLsa6rcg0iIc9U61ALOGehcPKkuQuHhX/uA5Ah8EAmzVCD/74gBkn6PYlQffLol1JhTQ4GuvKBUBddUL"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112091956.0_1639140356162_0.2984991539573296"},"_hasShrinkwrap":false},"1.2112102136.0":{"name":"@bentoproject/date-countdown","version":"1.2112102136.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"07236921f8e25ede71217e1921f8aac93c30ab6b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112102136.0","_nodeVersion":"16.13.0","_npmVersion":"8.1.0","dist":{"integrity":"sha512-OqhVlbK8Os4akWauoYISPIe1o6xCKifOpVDKv2Kx1840aI4yCDbkljLgsq5DaHhEPOOznrB3wYhQ18PluQqIiA==","shasum":"3173ee4c413aee042b25b5fd91c1e7a8c1a699d5","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112102136.0.tgz","fileCount":27,"unpackedSize":1722629,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhtJoECRA9TVsSAnZWagAAgbIP/3UGS8+PnojEA7JR83h5\nV+oYvEyo1cLrW1ZI28Z+7vknme71fbfEzWyLScTUnCgjrzwFSjc8A3eUv3LO\nOTSJ4WPziHM110+ARMG/fdVXu1vAloAa+kPB7TAcnXKxmWMNGzCH9ej3qFAW\nJapSuIxqIeH1K8Do+tkbPdgQRTTpXcMiuFRioRWtn4mv3CU6KpLEWpY0rZFf\n+IGq18HDDJhmiYTH0N5rByIZCyShHVJNXEvjfmhZVvu/yYhhbRiR2lngF59C\nH/isA6zpjWMN7vrZ/Va8y0ceZvLiS1TwnQst2kIk9sIVnkBXMUSZM6iSDGS0\nuEnrPNjmRrgno9f4O7dbsOT3WIZWM80BeQ0frYBVvufhEkbezmDx7NUPLd0I\ny02JvThevVOcON09PNt8jyv1RFQvC+T7InNV3hjLgV/3XgVglfvyRgShqy/p\nHvN7uHtEjt+0zh0Ydo0ikpN3/tAVO6nvdGcufUmNn+GAWnLtl4IRWI4DdMOd\nLlnN+S5Zx6SLLpS++mKzLEvxNAHzA1uQg+6N43i2TkY8io26mGKmW4k1fBQT\n2VyKzLmttvqhxts+G81oSI8R8XNvxlPLZs3MYsxSkauWqrLgZkckwNpIoqiK\nc+kHcDS4brbskqgb+8Y6Du6RVTykOmwA5iYR82rCOmR7YcugNzPVyU5TqaRm\n7vw/\r\n=Lb15\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCBJ9bLlHLvXk0weWUFzLJap8TB0r4zyuNpmpO8b8fQoAIhAKN1K36fX53XF6Kg1MLrwlNyxFpZWEKOH1U4MGllEvZ6"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112102136.0_1639225859845_0.8188125347593584"},"_hasShrinkwrap":false},"1.2112132331.0":{"name":"@bentoproject/date-countdown","version":"1.2112132331.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"cf62ae1d6a12b70dfb6a7bd8ce66ed5bc6e30d1b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112132331.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-6vqkJLlfjFFzNwa9NBvjK4rwqGZYif1BCv0V6hSKEGUrU5A89miS+bvW9qHpbGIWRRunFUEfrYXHK/w7WTRQoQ==","shasum":"07075e87bb8bb1d8ab4de3340bce3e442becbec2","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112132331.0.tgz","fileCount":27,"unpackedSize":1719791,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhuJUWCRA9TVsSAnZWagAAVCMP/jYVa/axB0B/+czPRF0r\nztf5GnCRKoLuSuw0EmJR6dwl3QfAnHYc+Wk8Gc7lgnOU+aFZ0LKEsdNm7ZqG\noFe8mTeykv/+Pg/mx6Hw8wPpPQIjoasimoVgHZ+eT0waazUC70WSuHhC9MkT\nc8ZI5K+6nrWYdSd3OOuau7duWeWnJprHXq6h+0Qvk0p0sWHTL/cPPvtNupDA\nkRApV73v1kxwvE/QDiWzaVFF0PoYOoJxErpNEDU+jP2fgJAcGRcd4lRDelLi\nkXWiX/Ebvasl8qJye1KzdU5Q7XO9uzEjjQEt7EpNrz97jguNMaP1K6N5ULHN\nRGeciE7LVszWsMaSizR1R8iYlP3mwv8au1T8RGOcRXYIXZZTDBWt4WdMoECO\nthbZWfVYGCOj8RkmrsPWBUeLqWrtlgpLTggrGR2eXfmeh67DpGb4ipK1/nTG\nTPj0o1lVy8K1fX54Lb7k0CDN55Ij4l3FLwh/gVDbXglY5mWMEkOUkFnP8Him\n5wSaKHBqzzZjzC50EK/WAyrw87vVmo7ebTYeZoDSmIu5OxzYVLeSLWdgZiyh\njDmmecFFo7IPffTF1iGp+CW9nfSQ8cAFd4f1w0wfAuqORBD6eGTHktvjtOSU\n3jJosg/67rDM1JfEhS5IkwUZ5qw9iKwCSaHQNs1TUwFRXzAqZ9kL4ysh+l1F\nlROa\r\n=oN7r\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAOn8A/97VQh/2tw6KdGeEhpyHATGQ+dlBSzXBKKtWrAAiEA3jWtp6qEVqwQL3gqetJ+Ov6P9b63gJzHfddo3CVO56o="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112132331.0_1639486742272_0.5263409373640981"},"_hasShrinkwrap":false},"1.2112160003.0":{"name":"@bentoproject/date-countdown","version":"1.2112160003.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"2bfd164830b15f49d7d86cf73821410a039d9039","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112160003.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-6Gp7Z2fUzJt1Pt75RDTE/qAywTLYc1WJPR608qbR8xC/jMjPdKRKeCqDfJpn9ftZ9i67nyvfssBFhHsuTeXSvQ==","shasum":"2a2e5f69e445d8ed17e0314b63d29bda6e891d47","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112160003.0.tgz","fileCount":27,"unpackedSize":1719791,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhuy7ACRA9TVsSAnZWagAAEg4QAIn0cRbWCxSoSUiovMnD\njfvK72FqDcn4k4pdmPZr2K7NTPZNQnqr1O5H7EjTuCdVvCtzN/oMzA0GZvXb\nDw7wRndz5KU6k0niMXfLsZaAMb/i4LwdwaAjrwqOscp6YPJxKRmRjYtRhi4K\n05poEn3E4QhlmQYEkRwXiKwXkofBSzRaLoQettc0TkUbYQJ4pPAqowD3xx6k\nDNu3aU2KoTG6hsFEcRlH3b3auIVeKd9aODjG/o1pt96/Ehc+n2Ok5fIdKxt5\nEMihaFGVM3aLpY19F6yk/oRXzvqI83Q/nYhDDGbTQ/t2dLE63uNjBUJV+8ex\nzah92HT8k6TWgBbbeYxnCZfduPe4cN9rN4UeLH9FZTA7huAoslk9rmeVHxSj\nwRSgdfcLoPg3DhCaGYwiKRO94dC3lu1/V8YLqewr5icatV3xrxpb7HurU1Da\nRykzCGIEg4dMtItrlfyitVdf7ngksmW+BC2s3UAclWqQ4113Awqth3QAYlrK\nJ2nBECKi1VyPKVxZ9HEskXx973N6C1vhlKuheOwL/UhX4EdssMDt6LJuV2sg\nvtdbrsMP/hh2EI7AnKFnOWnRnmuk0tXC9HSKmze3NbbCYA/Fg2OJNKjxI4kG\noQO7GbvavvzcBoiltP686eCbhQZDZncEES6DtheXvsbTnCtJqYjpVJrm9tU8\n8ngF\r\n=x2R0\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCRQM7pIHq08jllm81INu/S2FbLOChQnVWA5T3dQfryyAIgDuzEIQhwUueqWKgZYEKYLkf5ibmvXa45wTKORAmW2Ew="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112160003.0_1639657152712_0.04088338926007773"},"_hasShrinkwrap":false},"1.2112162055.0":{"name":"@bentoproject/date-countdown","version":"1.2112162055.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"e3242ec094a87348831cbdd342f5187068444994","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112162055.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-lRPhjpl4Utk9UmKXvCxhKrdJY+aIl+wCA7qBshdbnr2Rekpc0lCEWL5OHiwCj21h5j38tk8cVdx2DPbQ5YOL/Q==","shasum":"1d972f8094a14ec92b49f057a4b6dcd2779b550a","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112162055.0.tgz","fileCount":27,"unpackedSize":1719695,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhvH/eCRA9TVsSAnZWagAAPAYP/RgRxBZyafRWxcSGmbNQ\n8n3yDl6TEKjouak+5q+su7xdvuDWwj44YP6TTyjwpTFfKrZXWNgV775oFuEx\nqo0iDuZa5yaXJwVxUq1LLrAJcNkeQ4j8Ot/3BUOhk11ffInb9sCfX4tFrgQ1\nHoBGQbFWxlaqFGHNfQuq6symBfzxDG2lE7iBHdKPgkovDx3PQHEijahrEzX4\nq05mRoLqslpYOPvXae32ySqqO4sUnISvuWWqYaBuUNRg1OgshS2us7rhugWN\nU3Ky2Y+1i5M1TIHUuDIVoEsQw6lsUqHm6JzJNjMBcZDcWxRq71R4YIE1TFi7\ntowf/aHG5bDIcUS+8Yn/5VfMdQhJHp8Dqv4Pt+JJNZiakmrcRpxZKIu98uUr\nTC6gAComazJw5R74k969HpZtVF5LbALF4q8fh8ffrk0SRpPRBQfzAwgB4GMS\nOcAOCC1OCpqNud9mzb6MA/xTGlfIAofMFAtg/GxFELWhkmDDpDVYeSiPBDAm\nh4csVUsGdkfkUB56emTCbIFmP1OND4GiarY2Xd2WLUHWIZgjKGKNTnVaKy1e\neHKauOSBVTy2lJnh28+EdBqNPsEdjR66CxSJ8nRDkm2PglgALG4+S2NJdd0m\n5IR9BNe3HK6z8At5BTqIqVWazJ+6ceWvlSCxCJpxcPnC9/oEmCWWbE3DEfjq\nlvLI\r\n=TCSN\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBvKoj0BGQ9QnWWBJ+hUs6Rnnd7yaRugm1vYR8C36QwIAiAVw9cL//MJWI9mvj+9K0CezDt7LUuSPf4dGW+WbAc+2g=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112162055.0_1639743454302_0.293932520077719"},"_hasShrinkwrap":false},"1.2112170012.0":{"name":"@bentoproject/date-countdown","version":"1.2112170012.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"38e50237c04e29792bd0ccfdc13308940a873817","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112170012.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-FbIQwrfAzjheNW288aF25d4nxL/bXSDDTCo0HFGXL7d8hHuC/FrVgPA4IJ9lF8D1G462ppK/krFjQM6WkVb50A==","shasum":"e1ab1a325a0dd720062b6ac7ac92759442b1222b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112170012.0.tgz","fileCount":27,"unpackedSize":1719695,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhvdF0CRA9TVsSAnZWagAA+zYP/A5iT4JPn2mOlxPbAWCB\nc5RWiJL4fmdHfrQpjd2m+/Q9sfcujOntyPovNUNTiMh+sEz6UbvXakimCC1r\nyYAzJzl+Wu9GwL5wsu15JBog2cwZlyJjm0q3vUqYbhfyptn6kUXLk3qnxXvK\n5FPs6B5Sk7y6aigKNYftKVT497toW9278bNzQAvP8CH7KYGzer7/cWa0Ch1s\n2+X9np/5i6wGGyeSyVHyU3Gkd6XqI+jHun6wKwGXXpR6A9ZveG/F4BjjiTp2\n2Ah7wL353BMgt37Y2qUGHADnR1BgUt/OdQyEURwxK5gxytOvA6a7kj9NzohA\nZlZMq4JH4J96/XxwHHDmlTDFSnkiQTYgTmWzgE+CdNPnWlUv7/kINP8dwxvR\nG7XbcaZT5OnpFEHDlPv/5rfTDZ1j864gbosWcareB5NyzWZW98ISU/xKv8mK\nzhLufKHBJL9CwKbbxoK3hrINojg2KqU2w9LEqibOFoaW6pTpEUa+fHSFvlwY\nZNeAyscbaRAUuY3ICymFNoHlNqltifrNi+5+iiV3JECMtNU8uOecayR3f/EU\n6s8MUuOHpHcDLKlK2YOtxL5VOXmnedcnZ89tlJwC17a4/f8tvl0s5rJCqmVy\nE2ylsSpltrEKtkh8Swg4ac/pepyAVRS6kdDuCEH9GdqHuHI85xTQc0Wu358e\nzPPz\r\n=KKEO\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCn6vVg/Bf87Eza1+4Fe/pIQ1FN8U0ipQfRC5qGhnc1eAIhAOj2C2LyXGDwAaGKnxKIamEZYLPjt2XXp+NTM3uITeKW"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112170012.0_1639829875826_0.6314924992308586"},"_hasShrinkwrap":false},"1.2112201724.0":{"name":"@bentoproject/date-countdown","version":"1.2112201724.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"a8be9d1eaab4dcebc8c170c9911acf0c8a5e73c1","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112201724.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-LB18tzw2d5sUbQXNWq9aGoAE8fnUeXs/Xtq9B1pAjtT/w0Qs45imgDPwQ/aHOUMIibX8ILhmraBBLWu+Kcpqcg==","shasum":"bb491498b1c9a8f3656c92a655eb3a3099ce21dc","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112201724.0.tgz","fileCount":27,"unpackedSize":1719695,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhwcavCRA9TVsSAnZWagAA8VwP/3DkTDEnNqmLHRPKRHgu\nt7+btI+iu+t6dZf3/YG3Fhzo2YOaxaTZokSoy8RR4BLS6j+ADXKa5fomGO23\nLrIhJpbjyCGnwEZjivH47yORWivxfRK1Wymci+jboS3cfGGvl6dY1f7yeeyT\naKuMa4q4lumSq+s21FeHW65AoZ1L+0z0RCjCacHuf5gErUX9Av63kG1Z+ypA\n+hKzNSTI/jeS5FBfBrl2uXMczoqK6tG0DdDTgKlsUxSsDJOz8aZFBKm5MzuK\nPGZ/YE2Sncxdx+aqpRlUEjL7ScUH6PQ3hD7kGoU+wrmiKo0hvYySKYfXVd4E\nzZaxzF3++sOpTgk4vcQaPYntAWWOfm74aFF5dYJ/D6De26I8pkNNGS0mwATv\n62yJvBXG9t/PVeQMP43A2P7JjzxR62gBlQ+l2IE797z7ANsVnFaDVeOCFh5T\nc9Vj60iksq+/V38XBYEziV/rIYN0fCX06oSy1qzEoMf+6x/eiEikokwLot0d\nzqJOGy2WCsprIPU5gnMaBXOvtoYOA7Qz9pF9EnVwFgptJncw2AZeHHrZwylz\ngSCQvVjkVDwUPFrN492XDInp7fY6IeFMA1nVyEaOioFY52ip7zO3BbuevmfN\n6drcuAj/aJ61/240bm+asCT0AWZvFv/sCyqc6jfmd0H/iZ+KI2T5Uz8OWPL4\nGFPm\r\n=MpUL\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC6+hYT0CvUs0+LidSXnbGQORfdQ6rc9ltJjPL5XiUdwgIgIiCuL+NIuyvRuDeZFJ8d/Y3rtBJEPkXoHt956SazhRY="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112201724.0_1640089263526_0.7544016749374678"},"_hasShrinkwrap":false},"1.2112212349.0":{"name":"@bentoproject/date-countdown","version":"1.2112212349.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"a6b6a6c259283b2cfcfb474966602c2ada072484","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112212349.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-zlx+A64mX/KpWs7N+urubjjjFWUU7I4w/w+VLTJY9VIezV0HeFKea+1jnGH5O8ygFv2UPQXo8MY8Yfhwe+FwzA==","shasum":"9e400c14dc4a7ceea72e914391b4c94a2d0dc077","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112212349.0.tgz","fileCount":27,"unpackedSize":1719695,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhwxi2CRA9TVsSAnZWagAAxhQP/jobldWikSz1g5WxOO9m\nbqN9xF9rWAiTE/xNzffuE1ZuhDC/xy3f2AvdHGltB/ploHmbXgViEKU6bnrK\nIxBurYe1L834hxHjLAYF/TSqH6sk/2FCsKrGeYfNzPACWfYNl61+E9ry09ls\nFo0/NZS4ngz0wUgO0Gn03IUf9Xru2LyJNFDufhcNuKnSb3sv9W4Tb/ArogR1\nBgnV9Aab0j7vJunqYaAG3YsK3w1AOTgpelcCe/vlo370nXelxTwrS/aR5dmS\n/BCffgx1aGDB/EHPQJB77UavaTZktg1cO8R8sbHz32jgy4lFLPSqRRtc9dZZ\nzr5odv1R8B7up5jOFD5fP63FxjntDgN9vVDsalAaTmKC7l+rQcmi4+ywZmxW\nbahcfUu2L4DK+zj4h6Q4kkDacndIQr/WpRR6kDXL2vpOQQPb75eo/wG2+4Yv\nruIMegJClBG3yH7naczsZojwVMxRWCJHX7FFSh7Afb49/ZUFIW/N2FS0v4+Q\nb8M56Ttftu0VDIEdYGHCSh190XFWEo1oapCnVFqlCNNlDicmxrInrT0rxvV8\nkNN7jXrk9YZTIPBzyaWTCSroY1NuqAQO5yKMaTCQNrXHQVOHjfJRZI4TDLD3\nR+Ftnem5F6se9vSb104iOQyS3Nl0xiO3sKqYiREBh36iL/XKKLZrzSUj3NGL\nv/zg\r\n=BBII\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCID6hf11VOPYw10gIYPI/ImbXOjsut8jzdoLVFiUvVyKbAiAPxUlljkte5deB0bDROFu3tIdsVy31n/xMwKvloWsd7w=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112212349.0_1640175798236_0.44804908872332816"},"_hasShrinkwrap":false},"1.2112221739.0":{"name":"@bentoproject/date-countdown","version":"1.2112221739.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"5d282652a97695e5ec57a655f76c0cb6d40de066","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112221739.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-UOd79KXh+bmFp44wkPyNg6Uhqm6+uHauR5aMrqNMPjXRhRWy30+u3MwR+clxHIxsjzrAjGNOVLyEowXZeBD83w==","shasum":"0502937d872026f743538494978a69e91ec76ee0","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112221739.0.tgz","fileCount":27,"unpackedSize":1719695,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhxGkqCRA9TVsSAnZWagAAA+sP/37WiGsG4sMsywjqNjzq\nXS7oPlWnOfqrUc5BIeJZJ03qTcPTwjqUd8LE712a9UTf98dlS9QWx1q414aJ\nMNmqWfjDD2aC6mUV1k63BaqiaNCpQwweVXt8ciqH0/2yYbelc+m0x6FGnEc1\n1JwdofVkY5QtAMI0oi3lOtYJaS/pDTufwokE1K0l20cjNyYSg6JpdcuvTkz7\nZ0OxEuWd8YMXVBg951uIceNI/btRp8YOmY2WMXAAaMc7y5YQ/nG4vdLRgbFG\nfDeHVKJjZE99zgNq9ZxrIGQMzqMUzaaYwLcyitmR3dKy5X7ez6A0SfJQaskl\nunaY4GbfEi3W4KERy6bo6F/ZgtX47t1Vg1JBfCO1JaQhTzmR5KcfDCndkarl\nVPJaEsUtScVcBOW9anTS9xTRoOCtJE6NkVAnadtRnSdQps7nFCegLrHokC9v\nLsqh2uKL1A6tIPg46tFLV99+H73HQQ7UFAgvVPE14r58NtXjPnyH+57ffM8S\nGPYtIG3/S8neg4LIV1w+Hg9DbejiuW8KKwxqStDgGbmn+Eau/nnRgrPgHrIj\ncUIgBv+k4y9CmqhiWBe2dmuvsL+pjpmQy+8F6dspzlVMNrKaF0u+DJH4rCLM\ncvzgtb0isDbOJxVtFVuyrJioqpZSdBNlUMYCEcWPBlM1ea/dKAkGFMmoe0Xa\n0kcq\r\n=j3On\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD0U0mKWPc3En7ECiMLBtquPf1adkEPrcTEYj2cESG30gIgU5oaCF9J8yGADRGr4Qswqt87omEZtqKsUonWxdjEPQ0="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112221739.0_1640261930593_0.08044448441128327"},"_hasShrinkwrap":false},"1.2112231523.0":{"name":"@bentoproject/date-countdown","version":"1.2112231523.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"3d06e61b6949affa49fa2c89bd550777f0fc8c3a","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112231523.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-YFhJdYnMVUfgevKVCUwvzn8zgwatmhfa1CTEjZ/U/RM6eTpTQmrr9QYub51m3V7c/TmpmVHLRxk/qP7k/qBxnw==","shasum":"dfa692e2e8f397c5b403394c51fe8650ec10e7a5","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112231523.0.tgz","fileCount":27,"unpackedSize":1719695,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJhxbrsCRA9TVsSAnZWagAA5XEP/0tITU/5J1fN/sa/VsK6\n8AM17jLkLau86RZMPisRrvbTB5eGQR7dAAkoNgD1nWeA6EQsI3GKtYg797gf\nGIX81r7r1I9AhXVGXoMucQ8+GSy2sxRarZal8hO/wtMZb1KAr/f504cXRytW\nP3wdO4oopeH59+PI2lmkFlLzPoCiqUmIatXHDoRM+YACQl+3XqXgbWs2QiZc\nuBlYXlnGk50J8J7vNhaR8G2DeJN4UxYC6+KfZ5Z5Vv05Jm1Og/kxt2d2omsN\nSRkC4oij2yo8VxmC1TeLm1vuRQ9p7FwLoSRZ/ht/q5cCcvLg5fSFgP4H59GX\nVNiSsqwqpCQMA53DK9ptKYbi7D7x6w6Pk792UePXyj7RZ9R0k713jUIibpNH\ntHuz+avGNJrrxE2UeC2czOPouAwLgvcd6cjUIBV2e+yoYEz1qLsMA6zkeT6/\ns6t2kL+XsvKgqR6YOAlo/gccK4SVlmVvppCLoKlkZuglWJwlCAcfCHLayyuu\n9SPm7390ZYPxlKZGZvSPopDon2VERpSxZAXnD37LNSnROU21gTqIr2rtsycX\nAJhHOkgwNrGFLbLa+nzDRLFvzKGTCum7ry0XcOSQ8bmQ/XTJDGuacqVRn5NJ\nArGWIByYb1JNquxjfYB46z8KLgV9eZKs63Lpvd7diTrIFTZ/X8rx4NcMWyr0\n5HwQ\r\n=7j6z\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHzygfQswJZJR8pJiIbmzLeeQCv/43cbNY6NdJi5ItVoAiEA7EXUQnAu6/HKuWWTqbcwIwLfHP8NlVQM67MzOC74OUw="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112231523.0_1640348396057_0.861433673858202"},"_hasShrinkwrap":false},"1.2201042109.0":{"name":"@bentoproject/date-countdown","version":"1.2201042109.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"9526fe41f7489e55b2e2a8bf52d6b0e4367e19e8","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201042109.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-IFf8hLPrxHes6clSN9hSrfHbYCdMyQIBcRDC1qC/jgFDGCTO1/dNnoH8Hcl0cuG23517QyktWt8FBMBmg3qRrg==","shasum":"cb3899e8c3e61b46f451abbf242c14ef65504dcb","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201042109.0.tgz","fileCount":27,"unpackedSize":1692491,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh1Y94CRA9TVsSAnZWagAAm6QP/RrEhVYftIwQmb+SoNzD\nyF6aXVVlM10garDbs9e1zQwWO5Ididom1vuHjaTqSvXuVEGvDv7z1uknfAaa\n8u/n3bYpFCXY3eFnu3KlDv5c8YxSABuL8DvxWEYIh3b5NMu6OXJmuNHQzz5Q\ngc6esT+jN5qQnviFf76btpzuchwEOoPqeJQVAESwcCurN8dEK+yQWI8rSia+\nul7amtFqS5jGjmE8UmDutAjfUV2+CzBDLDWYDLf9Lo/DgpYlZYP2FAXwQUMw\nWvbF833AeJG9lDynj5VKbV9KOXcuYjXfN1vD8ATno1xAK4pdCimPm4GCSe7c\ngCn9L33zT1IYS3DlVmS3TKfXRGiLUaohneifINIyv8VJUP9QE0QrgsikroZo\nLAp8R2VAnmM1e0yoZTT/uZVhyFjMUYx4J7nPLUeb50RlT5KyacgpUL7v8EBs\n5E1furYNoSYNZaz3jpbjbdYpb+3NwMvYNPtxi9iyJdVDX/KqohMlyACtCzPJ\nsAaAR4DnCEVWg9IAflSfjNfSikesrPzSD+99Q49uHFF2jvI9kgN7VPCompLp\ndpzGl/ZqS4EGfqzH0MZb6DC2KUqFN/VIl9I50c8CZ2cyV1gsEPNbtn6OWXrm\nHGU0+36mm5UR+i6X33xvliPI/2vhhNnGBKk9vpASJ4u9AzM2zZ7puapLg/XS\n836h\r\n=BsR4\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCctINmSjl9vRNLjGf3cpH9hc5Peo7f94FAY1cM1GpE8gIgAucljFxFdpoZBMgLgJ/Q/foK8dyevcHiYYzFlhu203g="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201042109.0_1641385847849_0.5364368724590878"},"_hasShrinkwrap":false},"1.2201052144.0":{"name":"@bentoproject/date-countdown","version":"1.2201052144.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"09cb7c2c04a007089967ccf35accd80cfaff0c83","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201052144.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-9U0IfPa1AFvAFWe7Nma7+foLwgRIm0utxPrsaxJDxM/KHAbcREZfnQYpk7SKP5XBRZKc91epIEwa+mOZITldRQ==","shasum":"4c217d630f7cfcebe31d5482c6c4a6a34090d1ae","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201052144.0.tgz","fileCount":27,"unpackedSize":1692491,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh1uNdCRA9TVsSAnZWagAAbmkP/RkfzJGexz0OK/lsFnR6\nkOyCPgCJ2+TkDsIY7J/aE6sz5FctGgt+P+l39eJF7zFui3v4fuvfjxXnC2IP\nU81GGzo/+zCyKgSeDkMEhyulj5ng6yBjU514uaOabupjqM7qw2boF0U2hGNP\nf0xJe+74+D31MEay5oVrnp6T/zeVX86fetP/bZasvsh5IQJe0lK/Cd4dN2YN\n0jcdcW7o72SYWcqbTj2NIy+nd0TTzcBtgqkiyHF5BuLcbGqGqfztgLoKuWa2\no4fsMcF61i/iFHGd4RtmwdikNy325YnzYZtzta9VwO+4ESviB1beV+z/zR7E\nR7JaKyxBQaFWLxC15ewZS+cLQg0XKuDI4GoMPsh7ea8jJ/2mag1/L/oITmf4\nVtlcQ5pdQdblHRFkTZh/DhRvXyREMv+y+OCWx7p5mhmfNiyfmeI80P+Pf56S\nP3p94cGHd6zAC64W3ITfmn2+okNTUo+hJTRNHyc80x4HK/asDmg6RQ3ivr37\ni8IU91Pc/L0ZDlfDIhYEvjKQK+Gv8lUHf2rtQCA4VCbWzhsY3hYhP98mqhnQ\nv4ElUwlSeRaUzAV9gTdToKE6Z5hwYZgsBkam59fwRWUvu4DRLrvSfh61FM7G\nCpMhME+mDukfLdU7ynvpuD1jYPnl/iIwJTV6Fv3XsKcDb+4mTBiiaQ4Fo2OM\n0ujF\r\n=vOy9\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCr9KOBtYRSiShufwwufv7NToaVysG6vmLjRqJlFqnHywIgWIDW9ngOVKgdw+/XSNr2OrbTqxSUr+q+BRQSU8Q+k/s="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201052144.0_1641472860774_0.000998623368612117"},"_hasShrinkwrap":false},"1.2201061922.0":{"name":"@bentoproject/date-countdown","version":"1.2201061922.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"737b882748278c09f4270720744c1618e36be6ba","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201061922.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-yMWFSvyIX4cHVPeqANjgjWB85CZFajpE4nm408VvWz5POGgoxY18vw2+EvV5nf0cS658HDJV8+lv1XaYN2nfng==","shasum":"3112ef3b3cd016e12e8d567e20633d21820a76bb","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201061922.0.tgz","fileCount":27,"unpackedSize":884104,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh2DLACRA9TVsSAnZWagAAPzcP/im1u4oeGzt1rp8eEuPA\n2lV3YU0RPF0V+HioXgkUVHRNHMIaV6ZdXm+Qhr8AzAq5bjDVKI4BqUA7UTzo\nH/sNABHCLuhxTJfy69mNBmBIm2ztNEQjkhTwN+GDcz7se/aeUGaCM9aJse22\nzqvwUDiX3kWdLrQ49fo5YCdKiEvW+2bzG4J/xuPEpZ0/IOyrtYz6BeVieQJo\nzGTAyD2joU97YESR28LgPJjF4REGT1HEdMrZvz18OgPFjpbpFm5pmkKhayA9\nzPSke6vzW1yUykeYT2phVtVxRcZaQRY5cdPnkuU97c97DV14W2K6ZtbV9cYc\npy4XBHoL6/UKSj5YM9PCSKdyhys16qJKzmc7aa9iII68cTKvWsFXdbU78gPM\nyfWHlyMK7I6WpyBW7moY+WI18Kdzf73FWo8otWYpMl9Hq8kAECZ5HoSReEqB\nGiV3eE7AidpC0D4ReY0gemlONruPSM73aNa2NdoFonqc5HT7mSZzOxST2Xj5\nikQNJ3LcS0Rww3tnDshxDzRvbjUV9E9II17Dx1Ewk90/xCpnA4FO/Y/UKf2S\nyNxRHe+Lar3Ik19NUpdjMWbg645eny1BR0y+Zsj7FoQK7G4MRDAn58k1c65V\nhojlBQcD9CGOh8+595m/cZvpPbPvHyx/cJM6xdYaXb155q6iX1dch0qqBjqE\nuSiC\r\n=bC6N\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIA9JJ95UZQXaXw7/ha5QSANzp9H4LOxlgxBga8WT6hthAiEA51q5mG2Zwd//G/1RvSTk3sZ+K+8A/flhEwyS/ZEy+wg="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201061922.0_1641558720562_0.24133443478644345"},"_hasShrinkwrap":false},"1.2201071715.0":{"name":"@bentoproject/date-countdown","version":"1.2201071715.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"e40a24fdddceb1c635f67571d9cf513c7e58800e","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201071715.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-v/oYTc/W8ZZlXC8nutFZOUTUfM2gByB3KC5PpP0VhKH2h/bRCyMjp7zdaZUCUujg88dvElUdf3U8sQ5R3FX2Fw==","shasum":"0221953b404499e9b46d9ce91c28766981718c00","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201071715.0.tgz","fileCount":27,"unpackedSize":884104,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh2YHgCRA9TVsSAnZWagAA7u4P/A1gx5S+JuUI9AXWl1TU\nfnGncawcz29TPcFioI8Oz7NI7wb0LamaDsvxU17IBl9bo3KjAdbuijA7/VA5\npXRkTuixwAA4DeD2rct7DVgwFaRwyFpubFqL+NQtkebees7rT7Ju3EuEmaj6\nSd6zsO0atfToPkfQLebJrnWoTcby3wIZOT78Y/JIf2MDxIMkO9NROpokREcO\nw/1DT3PDYiuxQlQsOODA1GWB03qIvGjSPIIopMcnDXd39vBftRmib5XXRjDo\nZtUk7j8vmRVoq/fsDLrQlStaARsAvDYCcNohOhf0tdTAOGuB3S1lEeQM2sld\niM/iHxo01P/V7RJgsNaVUN78xy1tFoEQzhba/zx9gmS+y+5oH1+wiTIbMd7h\n5lmCA6wrIrg5lvLiw8VHwVJ0d568jQRvGpG690rZEhlfIY2Ece2rQT8Slp19\nF399UnSGCNWLDSyWoaelOPoRdG9DN4KK0d+gQ/AqLZ37G3mm+mhsC2Qtem04\npDcPkPTSg6ADOJhtM/bg8owTV1qCW2N56Eiiwv0sGBrtAqqZMYdwoQU6tsoK\nGzaAPAEtEclwQVCc6UZnqoxbUW2VsQT1uvl2StgyHJXpj18iWaCMQu3OrVLH\nEKWXzw3PEe3IX5e3AmQDDy0mcSopPUn1DtkniXvcZHTyRKkTLz+qcTm96D2N\nE1LC\r\n=TVJ7\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDZPSHfgLAWRtyaQnNCV1jdL3nX6+9b2MA9Io59hKZZKAIgD58b8dIMH3km5b0UwX/9pPPdW768QeFB+GbbS4nZhis="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201071715.0_1641644511995_0.7846194629967571"},"_hasShrinkwrap":false},"1.2201101902.0":{"name":"@bentoproject/date-countdown","version":"1.2201101902.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"f0b7ffe685c60b51cfbab92bada4e0c87e0377a1","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201101902.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-JW3TBedTZlmaDMYdUbYxlh/OQyVkSBMsBKV+UKAFJICw9OaY2fHfmJdKkRmQvkRIOJJq6jAexz4fNV/yeS1QxA==","shasum":"2c9db5f726ceebc25cda1156162abe0dcf87c792","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201101902.0.tgz","fileCount":27,"unpackedSize":884104,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh3XgwCRA9TVsSAnZWagAAkZgP/3ASryxKnubTugjVe07Q\nVQX4hgnHVyIUg/wA5/n+i2bJN4u0Mo0XpMKCAO/H2XQnbJ0JKwTfoxTN7y2y\nWKlfF/FWrbRWHWPvOI+qRi4+pzC9lw8E2M9PYi9xHZCH3Y5/lrQu6WwtO64X\nByiJJZV2mPSalV3KXto7Kxh81TJlBttpMMLeMxhcuxVMICVJjzqjQNeQdZ+y\nCnO/Slg6X1UbgcKQF9EzNznEROY2WeVEgHzz4dl6ro+NWdxQ0hy1mHx5zqiR\n0cvBOaXbTfhf7PxSPWovv3Kf8vAaokZ4oyE9KAtDWhLLybnrKxoWEYSlYk8u\nW7I+hiiUk7Sj+yKcQDvFQE5/S21+H+NwW+nffpOqQtdwE91X5zJ37qUkvqNV\nbvPybSWv5Z6C6FRqlhXBOtGYEgkS1Y9ek0zfmW90NRz0ZLjtV+R72sQj+8bE\niUUaOvV/5lXZu9Z3NZnG4ae48NQ1FOl1uQNuLHWp+H4vVcyXjsGjO/nMaoE/\n4EDRQEUhXcmgHVdRENTndKDYssGcu0ddD8QwoqtyRQ14Y0Ql2CCquA1kaE4X\nDkJumWwD3PoNq2rKxx3WIisgEe3/1KcoU95FCYui+N/FcDBo9qsbj9+AunKX\nZlFeMcH8XMrbD487n2Rrg/nBCotWlxEeboaGzzpnxBAp2Pgo1AMQ1W/ahMWm\nvnWC\r\n=/1Rh\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHh7PWb38/QesJ3Xcb227+3pudKFBVbJebm+KqbIDdNQAiEA/Az7S25Pvbo/7ux0CrKOQiv1HiePnU3ZemNZSUadYd4="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201101902.0_1641904176150_0.9984321580273077"},"_hasShrinkwrap":false},"1.2112231523.1":{"name":"@bentoproject/date-countdown","version":"1.2112231523.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"1ba2e6854831868cfbd5aecf8a74b09bb0fbc2ce","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112231523.1","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-h19VY1/inqY5iMStCee9gYuaPS6KYyeykbG43aYCxTkUPFnxVqoJqQT4cDG5nG5PVUQyFPYaYEulNWzkBnKlcw==","shasum":"36ef9ef55a4314416380058e9c33e9b08dc38ce2","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112231523.1.tgz","fileCount":27,"unpackedSize":884104,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh3dmhCRA9TVsSAnZWagAA1/4P+QDwXaV5O3wXYWZVABE/\nRQe0rnUycs2ZDd84aE6k+TVRsGjt7+ae4GMuVJU5/ND74m/65sjXZhGsRnUG\nKJ0YtfvSGgHUDs8bzm2HTCBpv76O9bS1u7H5Xi8Cfp4JxVWPiuVob6b7SQ5D\nXs2+mXP4hRB7tlg+rX9SwYEomSo/vhaxCKJB1s36DpX49G/k+roP9hKwZvK6\naMqiqfPYcyJm2gqxwGyg77ZgxUl81AyVQ3b94yw+piTnzY0ZOJXCXJ+Z70Zt\nS20gaHss70NK+tUhPWijMf1VvqJoIHFkdbpcY61ZCLjUTazkTeQTD6ZcvwVw\ncRWAL4jHRSNJ5KFaJzZBFdBJHABU98Wm6tjgazv8qFBpEMI50V6HElRscGr+\nl8ssacVFyQ9/9uD6/IbHxYXHgHRr28Zqxhx6gCYoV0ri8y5qCri9A4/2GDxI\nXGVlWI8QfP3gfsR2KIKgyLW6U9BXMpQ1rMnh8y1Qw9Fp8v7UN6hLymViZVqx\nwof8GQBSDFWbk+Wp9t1RCasx49Vpd/Zb4BUtBavxXgkxrsaLGzrHthCe8t90\njjPAAERWJNlw7ihcLc6EKgvsXpF4b0BGBLImy05f8DJoAzmSeTT+lu8uZCkp\niBXe9eWfktrJb5Z58B+diuRsZpwbpEWmE3X8NUret5zy26B2hm3c4AxDBjXq\nlGUh\r\n=16mj\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD+ZIgFvjFNtQIjGiiiF0Hyf06CRnxQ9a28dM8yrBUp8AIhAIGrQrUWs9ydMzmcTRMY83sS5hdw0rssRH2JblWuG6TB"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112231523.1_1641929121205_0.03698896881346636"},"_hasShrinkwrap":false},"1.2201120015.0":{"name":"@bentoproject/date-countdown","version":"1.2201120015.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"c592aa0f3999a8b6109a8a31a07cae6a83115d8e","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201120015.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-EYSMFRTrZpxqW64HMyy2wdueu1ZDuxfPeVFRv5s1r1mhv55StjQZuPPJ2YGRzSVPcCZiUXXEaXBNLYnlOinCWg==","shasum":"8c9afe7b71835ffb2fcd7af1e8850e246e5f3c44","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201120015.0.tgz","fileCount":27,"unpackedSize":867692,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh3snsCRA9TVsSAnZWagAAyu0P/RjenWeUXWbbsSUQUv3L\ndePpsGnuKLhKy85Pkr6ipEDVt6b6EQnCXq2Nv2YcnIq8Vu6GB6gmhMfHnEWG\nzA01aAkVx4cLf3mAEXuKp3WLuKCrp6U3mXv4j7v56sgWrNvROYJ5q8hcQkIR\nN2gwwpM8ZnDknou2zfyTkh0Li1Q1P1w08GZ9wNT21JAYUT9LnFIbby9Zm2FJ\n2A37PjtTh71trzRGtBP8iYzJxxrzUBx2fqgGFCxtvGxiBjWnEedj/dWhGzmu\nJxkzjNOO4Se+BHwetjp4sRoCu9vZ1eW6+Rg4Sjm2w1S0I8TyDqhZpYGtiJY3\nZC5dXke9QGOBw6YLDrpvdYD5L/hoD6+ROcDN6VsLtLbjovYN4mlDffWfNbQm\nauxfHKK+uu6AXCAsNe2/biOeXsXVlo2DXRMX6xRH62x1qDar0XHs99PgkuQb\nPvp6RiN22vhVyMMIumfDeJMoGgKjtgyENgnuxcF9KClOyBbtjBv9aR6LGpKM\nggD0sqr9ViDSzByJs0JAkhzau2gmhWP20TpBIKlMJefhWvx0jGaBwj6YEQ/F\n15tWkAcPGt8eksRRML8NuY99THmDV21gtpHT0RLeQRgJ73eQx0lpHvnoAAC5\nb7pe7eEr+6EE6AkLuRpIZc167yobDMIPLsyBGjpqSVWjInD0X5s7c0nOFRVs\nEIub\r\n=Tkny\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCf7fxHLoNi8+l9JmFqoHN7rOy+5cB4r+NQleb28hdVlQIhAO03b6epaKI+cPYXkmnW6faCIlQkaBh/ldu8bJXEcUhS"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201120015.0_1641990636001_0.20625270592488776"},"_hasShrinkwrap":false},"1.2112231523.2":{"name":"@bentoproject/date-countdown","version":"1.2112231523.2","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"036fd40f8ecb160f2d6c65688c6ff4765a670bf8","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2112231523.2","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-/Jmc/MExPMPrGE15IDzrYQVFB3FykljMl10raU3vP+ONakzUrR4+R4lv+G2pnBRR6QRGmjKqNsR61QBxOLwPsw==","shasum":"d9c944f9c7ecb29624772319b3e3dc3bf88e5e0d","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2112231523.2.tgz","fileCount":27,"unpackedSize":855337,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh31iYCRA9TVsSAnZWagAAaV0P/0Wf0x8aSI2NIq6k5nNc\nKIEUY7n9RKp6YSi8NB0EWrkoTPyqqDPGARa9LxK0oT8Iel4+N2RzxFeBhJBd\nYK+qumEt9rsvEa7Bj/k0unQAkWVQK7EXElJxpauJba2MowWpBd7tS1nxaafW\naTR3bIpAQ4Mf59VfBWTX4wLeDJi3fkUk3agx0nVgm3HE1c7o8EYxPp0yQumP\n+JEpFelAYyYkqEaMV8i4YqmwHuHbDS1PhnuzNfnl121GkOBwV66Ug5BA2Wup\nNofHSuPOwt0aczVkUbuIasYvFJ3EvtTYB8XB9IBdFtv9+pjOSNqVRGHoyGLp\nAbNwAXP76C/lHDWJZ3RTNgqdBTNhKzH5fuuTsZN26/juUdO9uB4aT5mHM03R\nvWu3PIsVezqaGdzMTY6rw6ilFxOubq6ZqHLPkuk48dvrborgn13hhez4+jl7\nsi5TBoXrtql2RBtaoFaB86afNpOCaWUsJOaXNr8sCo2uPuGifdUd5q1K3cT5\nC+ZL3DwY08h2rC6NSOEwzQ2LDLEgEKehxBitFDiTbk+ocFZbjNgdT4k9H3vT\nHfwXx0m7fC6gVct9jkoxNWDPkDZ8VYp/SffrZ6xB3n/WLOzT1jGG3jJl9O6v\ncLe1s8dkXvw0sjKx9e+6lx0mTS9eoK00x//mnlcPHFYz06nD3Sik02J7+1Yb\n1Dv5\r\n=HvkZ\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCID7soSRlfTJ9zNWkBUs8659av62oljMGPJaL/+xPSJThAiEA/+g3N+WENVcdcQ6GMvajONWoWWL4JBHGwEdMUaYZfJ8="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2112231523.2_1642027160554_0.899253963688986"},"_hasShrinkwrap":false},"1.2201122239.0":{"name":"@bentoproject/date-countdown","version":"1.2201122239.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"c04895bc1c2e1d0b7b874427b9bf1cec2b4b9f72","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201122239.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-tYd0x8HBN9RWbjaiUBITtDTh5OEJYLHnuJs/0+o1Ic/N86XnESg/4IDyyyFgxR1z5A1eLBRGVewOnxTyjYmqng==","shasum":"a8c943f8ee668f7f18d408525fe3f993bf946627","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201122239.0.tgz","fileCount":27,"unpackedSize":855337,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh4CJZCRA9TVsSAnZWagAAVpYQAIay8hWgNZ89OTWMMFu5\nQh2T/2gThZIi0tJDNOLsmYcDuOTY3e6LUNj5S9rA+CUPJQ5OodidJLIYB/VV\nC/2oCgq9pOvZGYhTKCRG5ZyrZgijRk9l3McQoG964S+XwMMzzuX6VSDViEH0\nr/xnFlUbBB3IbPuDc133DKe7IM/rvamXRHE4DpaLenplQ5MbtEK0LsMQFynF\nlX9yYVqU9ilp4JoFE1Iq9qIQU3wxcGS7u8boyMxDnaFRRW+qCcKfi73Df8HM\ns2nYvqp2O/mTSwlU1JyEdnuT0SJaZgtH7NDuIIGHzYR1RH79+zdnPeUZoGAo\nW0m/jtUMUBKW0vzWyxSkdEq4duCwHd3Nirw0tOstlIx1uptF46nzVoWpCwX/\ng6WAyfJboox1N09hKdFX3efSfOlk0Wm+NXBN78x36HRohbYGhL67Al6N6ult\nWBbBeLvUlJac8/whqo4qPtBZuJWJBGTmOKr5j4HNaJExnLRt27wqEZ1dxBES\npR0EBPDqy9bpe29w0KNtb8y9F7WWAafVsL4sYny7XajhhG0IsqijcGD0firg\nnbw8uL50cBozWVDjOjudYWzzwPmnzFH03LcCa+yhlos+Gzr53Y5WSVcG5bNS\nI/uzeRsXQi64lcjHK2oEVVUh+2oq/C+dZUGFyhaOVS5RMcRgrRyjMPSJGc3A\ncV6n\r\n=FQAk\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIC0h9zGwBg9KL0UrGfZZP8y1JetPeReL8yNjd/x8i04tAiBYsbAZDYAwJScBg+sM/Z6PhcPCResJCI2s2aXG+WlgjQ=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201122239.0_1642078809007_0.3428635430099083"},"_hasShrinkwrap":false},"1.2201131702.0":{"name":"@bentoproject/date-countdown","version":"1.2201131702.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"e9b16ad7a5cee398ceaabf6ba7990488624e098b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201131702.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-2hwGLktybQot8EgWqbgoJYxvx1SQqmeBHEcobrrzmgzlsK15CP0WAVqcetx334bTPnlX8L4oMz9gUoS6s7UmzQ==","shasum":"adc0aa9c727961756ba344b45ab74ccc431875ab","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201131702.0.tgz","fileCount":27,"unpackedSize":858155,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh4XS1CRA9TVsSAnZWagAAw6MP/AyW2J1vWyqCAcHMYqOe\n9e47nwX5N/1z4U03HgNjevgouxrz5S95o01VdM2aEidTVtYwAIS9QKTdFs/T\n1lghROtXnjnjhhrWROSma/0y/W59LlGNFjqYmA5s/118oFjYMheea85tocvL\nJXCP+7qP+oTMWg63L05Obrbv6Sx5a3Uc+KhwQmUdL805cRg0RcZKUovubV02\nrHGpgWTc2yLnAdTGXhLi6s7U3ZnQQunTUZgaxXJFueptkhppnCM7pFg2ak9b\nC+nFvjYSexl2049LMBrpNUPQve8YliPn3nnEPaOCY6TCWeWka30v+x4BNaDf\nFRuTT7tqGlfM8xIGlv48aeZYZrTldpdHnkKQ/BAaarxcqJtbIeI159crFvjT\ncnk3ZKuwcV+SiL8X0PyVLpqu5fzU0x4i6xB8TiuOMTzdv0+0fWJz/ynO12PX\nL7dfX2NHUPoKqOGbnEshzUZwX0AjvJOUa1548miDTXhG0OiBuhDLlr6XC+0f\n6kqkJeDw9Wg0QX/w26WNMSjCDU9d0t25AGwzTEOCNCY4BIklR9jWli5W9TFs\nMuD7GeFM04dQrcLlcMvyCJhRN4MpZJ3rmb8rx5gQLUMc0BXbw32GksBeAu+A\ncEWNwScksMEUgusODAu7dP03zHmAVLdnEojO0TC5epdcHHuapGln9RMoAZBw\nn4Ew\r\n=xrZo\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC9WUqGfAlXRzypSe70/D+3XSgyrv1kQ4Zq1z6fbE1wggIgJUFaw/+UpOJr50XNw0NNaQIOnQgEJXy05SaABsVgtkA="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201131702.0_1642165429464_0.903958739311177"},"_hasShrinkwrap":false},"1.2201141909.0":{"name":"@bentoproject/date-countdown","version":"1.2201141909.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"96bebbc98d1f79b185c5ff6c58442ddc2092547d","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201141909.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-uOBu3SDemBpWhpotmGZQQz7AxdncSpJFvHSgV8a4gV4ACbYLPGjU5iUJllkoG7R1fKx/ME+iOWYYvA9XFv63NQ==","shasum":"a5b56d94c7477ddce78286c2ff8e6a98df5e4c8e","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201141909.0.tgz","fileCount":27,"unpackedSize":854500,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh4rxCCRA9TVsSAnZWagAAZtoQAKAplNchwd5LdTu15dHo\nEOAhfWEOvLZLEH3crIuBTIfTx++TgufWtm+/pMAr09BBwHXi1VgehcYUcavZ\ngZdcHtwwfO5ehINm9zN4NQno2sE99Ll/gi4mVRya5pGK0O/SM1C7aa0PopFm\nT7LKxwj1+KCNZEk/JWqY3idtBNTdY4ZbO77FidwaJr0vml3pDJHpvlPe0VSd\ngKERx4VHIS+rBDK0P2c4rR8501o7DYyHDgrn7A2TGDzWUcQ7naOzaVYP932l\no27KY4GlM6tA9fEOBzFQL0Qu/J/mXBl+mWd4/aTddhJFERSZ3LiCPsM6/YVO\nrEn+1rDtLjbU7aK7Oaz2xy5x3KCCXoqDvSyEh8y9sQXn1oqqK3sxO03NU3mM\negnOvWKIpCEojglbT9BciqEWz1D4d3QvU1DqrAZIjjshJWzcCYj0jdMu0rtO\nGN8s/zrbHSnI5cBzyqicKIqoa0O49JOikOViwK7zG9eCfytAfBnuetuGIXUb\nzq+q7XONBp2bk3ivn6gJQOriv1S3tPf4Zg9TBY6SXkgKUQV6Z6W6l+NRa+m7\nnlblni6Krl22Z0kHebKCezM7AnSgWwAjiFP30KTYJMQDA3jdcqciddvOlRhq\nS04wG32srjb4thyfOoTX4GId0ThpY9AGS8jXLk840JHWut/4urpaJqC4TNbj\nUgpf\r\n=mYNw\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDnBIP/HrkYIquy9q1q73z9GvDaq1fDOUMPTvGPhgRJmQIhAJJNd1/Mj0lk15sfMJ9rT1TMYeN1mVWVggzKpkccKPy7"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201141909.0_1642249282814_0.8452852781548945"},"_hasShrinkwrap":false},"1.2201141909.1":{"name":"@bentoproject/date-countdown","version":"1.2201141909.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"6474ad58b0a7e1997cf1472b09ba21af402b09fd","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201141909.1","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-IEkIgvTCLzZLyyI9vAFmv+2H5CwVfSiDN4MatKW5sPiQcbCSRgKF+7DNZ1IPdSDu360jCm0/+NBhbE/kW++0Tw==","shasum":"01a37e24589fab6627e66b83ecf6649f8f2c9058","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201141909.1.tgz","fileCount":27,"unpackedSize":843937,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh8FRTCRA9TVsSAnZWagAA8igP/0IZiI+m+ePIsHEiOEn2\nLOvC08OuhnO5Rd4hpylU/SOpo+7aOACcUEO8gSmEkms0UCeuHw/EcCat9zAA\nQZzTqceKeLNS4wyqGMLFj4CNABkeWvk0YWSDLVp4wOXNRGdobwxDwioQtIK4\nQ8qZAfY/IS/LmTbZVE7o95ZQVmSHsI9IFexTMuxGb9zaQtlCn6K6q3Fr0aPZ\nsGAFrbQErTcAE/XkuztoMLvIbBFhA5M0jItuh85aLkoyzO/vtsG1B+C+g0Rw\n0pzJ3Vk7BhO6WdO9KZ5NopnlH1gasFarlZUhWBO0Au1fTXcUii2LiJyStlbW\nEBXw/fisvPMKnitExNWjFaBqFjq1D7voH45xq0WMJe6tIqZkxwc+sU40b0Y+\nBCR9PGYiJwN1q6kv+/mcYjini4fMJ/S4D5LASG58GzZN/WN1brTactFGDD/N\n1uofP84rkkoXH5hHscQjZAKUG9euuOfTiaG9KOSop9pmXj3G6XhO1P8mf5Q7\nBTt3NYE5h/Lea7ZN8HzKTcF67jNgoaSl+QrZeL1Df115k0KXY2QbWA2mLTOR\nUhDab5og+t0PFJCDX4O1QkEacw+QI4B33fO4F8DLFZ5/8OrpGmqyTW9I2TnF\nR1OHbMz1MVfSaND+t38QsBKOdXTAE8aLbxq4WF005SGm3huNAa2TdvMFiSGG\n1Ip/\r\n=w3ey\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBGU8ay8nkQxEpMGrUFKt0RHKmfHVKcAPwXpc6JuDL0SAiEAp6D+mvoOeznW7jdfw4WGl98roJI6a3n7/ysnKPuc3aA="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201141909.1_1643140178687_0.11084414446268465"},"_hasShrinkwrap":false},"1.2201141909.3":{"name":"@bentoproject/date-countdown","version":"1.2201141909.3","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"1edf4ae1e7a533868a19fad5b3b4da9917432bdc","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201141909.3","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-4vrTTqkmPCGf/8A3pZKcAD7VUbdLBdrqwiulcvC/Xh3kJIM9b1MLA97+5T8i8IzTWFrcGNceY9gyxY/8PqwIjA==","shasum":"222fd997c1cdd4972176fd4d36a474e4aecffd3e","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201141909.3.tgz","fileCount":27,"unpackedSize":846326,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh8bX/CRA9TVsSAnZWagAASBEP/0+LRwx1InhBMEctwhIq\nTB33qMYbia4TcQvCK5Ron27IFiM4ICpVeJg9/9oJlgQg/DK6x0gs7acGZ1hx\ncfbC96vsaRZZY4qcbaIy1qKHWlt6fiqiSydsQYUURT68L1jhdAvP/XaDKWRH\nJ9QvUpdsKVICWw+ecFiJcwy5Y+1bkut6lyByLjvXLpleZC8f90oZf7mZWdXn\nHEVZgRDyEWUk1ac4HJbtZv1ZUYMDCoMx9R2eyrs6JIYQj9P8y9FQm7t/EoQM\nCIATkKAAnuk3xpBTppxZd6CWlSd4WYb/FSjbBYo5itWii29JxAr9Gczivkcz\nosRE8AA/mKiY2HOSxwacsDzqn09duCKNFqffcy4P3QG4GHSQ0+6FX7bIdkED\nYdiFMAFax/Ko4vG274rD72/8hEn7gkWBXdDVk6+8YcdIDfqkI56K1W5ZJELm\nu2cwB2AWqa8fMzCms1ZTN00UkdiZ7Idc2YspZXfRh74LyivYIElbPbN5zs9F\nlJalpfn7kW8GfG7+I8zVta4XNId7BX299fG8Et/7BhF5KFI7tbMdB/ZMcLMj\nJ3XNceuF1qh6f0wZpk7z07Y+DqjuwAHX+n4XGwNm2nPKcZxMgokYBp0FVGH7\n8qd/oZv07FRv6w+NJoc65uHzWErWSjgO5RavUuyo3TPddZ0D4+ToczTHE9gQ\n5+gO\r\n=fEqt\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIF79XuNTbRqEOKYPGgzrsdS7kCiX6RHOsfQQf8cIFLfsAiAtjfISmAdV/GYr1Csa96KLH15b1S3F2fiu0uRFwuDOjA=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201141909.3_1643230719475_0.2870078242698959"},"_hasShrinkwrap":false},"1.2201141909.4":{"name":"@bentoproject/date-countdown","version":"1.2201141909.4","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"6e60d79b180fd0983c9644d325b45bd569c6da2d","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201141909.4","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-0eNo9vtEVaEiJ7HjgYEhG5zh0jo5iVFoV1r6VDJ3U7TYTt0wMmB4LIpU3r7c3OfT2cS++W0u0bnWO1CyeqRI/w==","shasum":"f46a0e2eec7a1740ced3f045cbc2908cdd65211a","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201141909.4.tgz","fileCount":27,"unpackedSize":847030,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh+aggCRA9TVsSAnZWagAA/K4P/jAMAbIvLo/9qjLMGSCu\n6ep5JEyg3Wel3uRxOr2fAR5e6vmZplTH1A9sTe1o9anl+R/jAOatSZfLUthV\n4HwvXfriT/h4nYU9GSIuP823fgIIe9kxVs6aW/b4R0FCxhH0R58YJtI23Ob5\nqv+fB2bmETM1vix1H70GYT0T+kdbelMuilCRiDWwDdNl8X2Wo2j96J9IvdmA\nkRjmSyeloQgiPuEUwqwGoIW3alnGacEdfPP2VwEWYqfS4ig3v7cqd6MDY7Hq\nTYy6qxltfH6jADnVCHdXd+qO6nI5Wfxj2WT+ZdWN54Iq/gtQlPh4s9KpHoPB\nH7lzLM9M9Pkt7LmimBblY3/5T5F0k/v68RJb8RXYRVsfswAwxkKUFVhJ0IpD\n5TDU+/L3xyLJT6px/IKty1NDuX72V3+JCpECET6NxLq/1+Dk4P/FcEt4xtzD\nIoSFX5mu1KqejFOZR9UlJ2aEZHxwhv/nMndd7/zc3x82/LrwkEC+lFiAyE/B\np/412mgdYsiyy4srOme3pUVHL8wvQE444USzFF9o7b2AN7L4lMeJDodKMwin\nqyie+LMRsXzST9pXrDnNC8yjTMz7Klm6C0s38h2lpmuMWsJ0mKtXEeNW4jkS\nhGD8s5O8MllU/9O8KVivuM5hNh39WJax9LN6qzLKPagXcGOqRsahCIXkoWoP\nhTuL\r\n=0cTS\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIG+O0nHSmDSdCTSNpmZ8kQgXSRhCoDZ/tsob0CIJb3VHAiEAqvXhM64adHtNupbnXkyx+UvG0axs8BRgy/Cox1iFqAw="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201141909.4_1643751455996_0.7870023100650847"},"_hasShrinkwrap":false},"1.2201212122.3":{"name":"@bentoproject/date-countdown","version":"1.2201212122.3","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"ca1c7d4b4b4a72f4913d7c304b5368187458574a","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201212122.3","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-8MT//kEcht5VpdDtdIGfxqqTL3c+a7mYPURygHaDCfmnYk3ddx8oxpMysU+OuW5aQOv6w8am/GABLDhUhsZUig==","shasum":"23645262e08c1d6c52946d280f92b1501a324a88","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201212122.3.tgz","fileCount":27,"unpackedSize":847030,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh+sZCCRA9TVsSAnZWagAA5KcP/0YpsXsoGc7hSwKxsH5Z\nJcWszADCrJBLLoWdmTQqpvy/o/e7NKkg/ZjFYbeDYEusV7Zl+UcNbWCcG/6Z\nyJ9E/TM6JsAplYmU5TI76zcarzKuBJispXvaERhF7yS/Ektwh8oro69iNte4\n7cAdrA2Z/ol8aIJ99c1REGL9WAzqH79QuqXqKWh/ZiQI8T/f928Hc86koVH4\nx0TE2VjmICk0BbQ84v4TlY2XVjjS+wLLkAc6LSMZ+sm0FgBFBnkymK4tShFu\n/8+hOeFeeZKkurk86VANPjgWfC7bmazsEoQIlN4qW8GxKE/WepDOLNEJ16TS\nca+tnm/2/cKcNe3IAmUUKqhoJV+bOzLTU00mJR7xoiPD0CvY9X4dFUhjLQa1\nNPWb1Ko8oKNfgiMWw/jz4J5dKsmGHu9W+CJaOzl6MaJXhJGfANh3rihwOe4H\ngS0A/CYhmGoRSS7ah+bggdxEkOKZH4kOpoSFjmb+ytwLlt88kDADQsiglYwd\n6PEiuR6/OXVl65lyoiSQfCcjkZujgNx6VH82eGOcEYqFaxwiDfuT1DeZYlcH\nUlfilLIW3nhaR5fl9CqN9m/wIQJSFrCR71Z83GhWXnS5pwnhADinc8OGKzqj\nZSZcO2CHFSlI00O0oKwI/G7GUHRx00WNtw0a2CCKnSE1iwZgIVPvmYctq6r1\nPBWy\r\n=WAi3\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCkGIPzvDo43CHzYOUTxAVDwr+EO7LgPj7oRwwcRT6e8QIgeSuXtxpbHFUIK0Oxr8thagWt+BJmpGSeniZpTpDrvnI="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201212122.3_1643824706148_0.5183490825299923"},"_hasShrinkwrap":false},"1.2202012258.0":{"name":"@bentoproject/date-countdown","version":"1.2202012258.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"fb0c4a54446b5abfcc53d1d446f24370c05507c2","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202012258.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-XIjNz4gNBPZ3XvTIrCYAI0m+bgXIVCynSyAKjUU/HRE+8TicvzanbcCrXnv6ndQ9IDDg/0M+bEyZILF8lXGnGw==","shasum":"2c197fa57a758732fa025a0454230da8fd11c3c4","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202012258.0.tgz","fileCount":27,"unpackedSize":847030,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh+terCRA9TVsSAnZWagAALbsQAJrM7kuJ+0xVoumxVQy6\nOFN2c+MppLf5uFLCRTncfGqKiIc+XaU5IvRKcWa/+6eY9zewTxszqHFbiww6\nVr6PRS0MootOSTCqsPzFtrXJ0r4PUt4dsis5lZBlsps1xGIEoZ1zYWotBcV1\n1Il81eeloiORnU+eqlTzOGsufKusFxJ5WnA2D/d3roW8wHwtVglDUmhWWbDC\nsXFnFiouSqEmCPA0uThP7HIeQjcfQbhd12/6eeW+tHKuIW4QL8uUkcgonKsP\n1GsxOvPxXA56adOnSpl7cBof/tA5iTxu8Rsx4MamPETDSf4vM0FulE/ILVcl\nUqtOq5CoMbQb/UrjWf1bTGxU45GTnO/K4BWAPFbVxP3KIFxa1Se3AGzRkQhS\nYV+uAzAAOWJCyanr0TD01mp1KmQc3nEeZz9JUdMritgkxo/Q33hIRRvySPTR\nWyocHy5KDKrpavr1z7pt6pM1W0gsiYzz/HBauFaKherctmmVYnxr11kjSTe7\nn6GkL3ISB43yVcKdIdf7kyr/7X5A6ed3m9d7JEghbwbzdjClQAxczz0lAdBz\npZSKzrKXxCCBDZMWhO7hjg9z+YrbZEKVG+vi32p71lvcjxH7bI8Ai/TYufid\n5cylbFIC9eeXDvs6naysifLsubYENReiRMsstCi/xK0FqhkkhcusHhIWmXPA\nITtZ\r\n=0BhC\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDXtNgI0IQxgRzg0INDiMroRcgg0k/A8JLDWDuvNJq0VwIgUCcsMYYy5BFbu+6FwzvXZP1dIAEMx0uFx5kIWtpAfvE="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202012258.0_1643829163517_0.42031842440525047"},"_hasShrinkwrap":false},"1.2202022130.0":{"name":"@bentoproject/date-countdown","version":"1.2202022130.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"76b8fbdfc923fb90c4ecf4dededfbae0a5978ff5","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202022130.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-tIXHJTSJqh8ELQEDg3c9rcQaXn36VebNl8GSDGeXaeTDG2R+88ksLvldfFTPOzPEYHKLjT3OzLZ5D/t55mOLGg==","shasum":"5834c25248a8559a0c30729b44483df9efc572f5","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202022130.0.tgz","fileCount":27,"unpackedSize":847030,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh/AkICRA9TVsSAnZWagAAf48P/2xmt7Vlyq1xL/JC2As2\nbcWPA7kTRVUV3/1W/7DMbioXi3dKWpGBQCg0E36NEj9aAP/EAUVsh7TVNWZ9\nVjrgee8O0DX6nzx0hOSJsxMuweAneYXlvc9eM4wHTbgtyVuyyckxzHzF3OYt\ndRILtdzTc+qqqHqbZxk+8GUfzgMvUu6BA8n0X09zDbbcE+k0wO/LnP/L4e+9\nHXhEgPmkNS+3HwU+L0AAxpKPz41rzaqAjif2IvNzmZe6Wy3mPGGb653m3n17\naqbeexu6UnSKxSZsB0QfTg+mnHxcFlGszkruIBP409+uM/5aQl7meMcwaB9Y\nK8fvnuNlXcUVPS2srV6KU+YUhpRwWiqzIcy/Mc5pAItQv5BhIqKdU9Ium6SR\nGhmylXaJhri4860vd4Oe7T5gbYjMXVDG72zSZtt6Bd77rw2BNaPJB6ZC8gLN\n7k9t5VVclggE1Al+JBmNtAiedjV4Lm6wPTFs6NXfELm6k+9/Y/+Ub/K5kImc\nminEEsJiGvsQLUz7kIgREG26ifhSO1u8I+argjSBlDCtNdjFg14UvUjyVTqs\ncs8guXBgs6b5+zTzm1g8xl+OfPZ2/xYXr6oi5nvCNLiH1FvAPJMEe/c2arD3\nPHG4GVYR9xf2LmNmgGX0zpmwlspdPkfv7quEnbbDIZnA5m9lW/K6+CmljLA0\nEanE\r\n=w2cT\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIERRdxSSAmnOguDe/JQwooDw4XSFenrHHrurhknqTfD9AiBdmQt+JEVXq8xyHR/8qGPrw2VpCSwZCu2q6PnNqBZ/dA=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202022130.0_1643907336234_0.1700095328467579"},"_hasShrinkwrap":false},"1.2202031816.0":{"name":"@bentoproject/date-countdown","version":"1.2202031816.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"b29dbd478c93a5298a18f8df14e6c1f5184879e3","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202031816.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-cc2tjlmuro40cyL9kJp1wLn+QVClcpPMDeGKuUmrRoVHo7TjA0K7O/iuNXh2zFvwVLmCx+ME3IcIWYt98osz9Q==","shasum":"5a98d882d7cc48594450dfb78ea3093e9455bd0d","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202031816.0.tgz","fileCount":27,"unpackedSize":847030,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh/UprCRA9TVsSAnZWagAAelIP/0Bf4OAjNgBqI+F8iL8y\nSifeBlMwJzD4pBGISSOKQQkTcR9JE7+6zGPxTEytPZ9nuN9rk5Cnw+9MbWcG\nL1XeAGYE0r5dQ6bhVikP9GL6SK65A8BQblgJiXDDUg+kSSV1wyGvXSwX1XXV\nn/R+WdXz50RKsNXNK6nH/D9DhUrn9EhNnmyRI3dRTFQlWLWMC1O1VqN8f6DV\n0v8fz7o5KNilObD0HkFBFxi2C3QYCfdmyNYvIKGoFJUBoJOdrBiXBt57Ll/V\nXHE8GEe2kxhPDWcvI4ZtMM5qsIept5uzQtfMZPTvq6Q3wi8X+U097fQRHkoz\nN+wpVjPvuwciH/kY9oZioCI/WOaX8gyGV+FqzZ7yWGXiuu9eqNbYujLuq+Dy\nc6wKTlTRHzf0+i26ETXPRGh+UOg0+bdGPsbt2QDinVp3Wi6pHVfre57m+eS2\nwTUkLQ4UJ95+mMF6hlhyKPe6qpOixoQ1RSff07GnkPXthEcThHFv0+fq9Amz\ngZKJNTzNc3TG5FLKQDJ8tWtBoKwK3sPjbO0PIhxzHywQyxXbBUCAT6ZyOL0Z\nLrJJObONUt6oI6axOOzWsRytnaaILX8yPnRyIA0aVbTeKE7F2h0sYSy0nfLu\nGpfTHS6GavkYz2M5bA5qx+QONYEWQ8TAeKXYT1xmPxNyzWU1bgDgQqoO83Pw\nYwUQ\r\n=UOTn\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAjUWDGYFz1xcsnwQDiVooqwxf6Rx2UqTQLK/kHX9z7dAiBbu3sGrD7fjwyBS3Ru7iHF3KT7K+d+WcEZEGdlqd8kig=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202031816.0_1643989611214_0.22604601389350099"},"_hasShrinkwrap":false},"1.2202042210.0":{"name":"@bentoproject/date-countdown","version":"1.2202042210.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"04d031e10759f2ab3f4a10cacd2b776e3de93812","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202042210.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-V40ARQu3Qz4twctpUkrKQEH5yjd6Mt61ezseYu6TdyI4tFYNpZPqk5vBmY4k3W2Xvbr2vfBTvZllWWaRYucWGg==","shasum":"84370c898df99fec044fccc2d38ec211bbb410c3","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202042210.0.tgz","fileCount":27,"unpackedSize":851342,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh/kDdCRA9TVsSAnZWagAA2xIQAKAWxZShNz5CiaV1vVtb\nA2JMYUlpRR+Ss74umBayx0Q4bjZaPHq0n6VWvGLx5MTGCrghVBJ8pLpCWS2u\nNRt/LecVQurfHzwhdrr4M7BG6FrJodaTNjSYdgYSixqJ6SWviFZjxHCQ1e0S\nVIYcPjFAjBJ9rbJrbiZVtvAb7khF2jWksiK7WYNRErI+FafbcrtszQ5wnXqj\nDo6kO5W1N+lUU1vrdDj3TMhWeOk+GPOcN0Z04V3XrSGtOkXdfXQoIm56WNr3\nB7VHBAjptymRn6SQIQun+ct2urcfXxKvFGHNa6BihugoujuPj9mKVoPyBSZh\n3LTtHvQv0uDxNWVbrP0IcpQ3h96iY2/de9yAduYgFfSnmpidwrY3TPzqgMV/\no1PW5rEXzgg7viBO2s83u1XXm2B1871wx8pEzb+VDlmWAc8kTtOhDo3RQAII\npLNpixE3XST61/snDJ/LrbxYrK/wkNNA9dN0MVFmrXufSTXUe025aOKGZ1HE\nqV/t6SJqDLCY3VV4YvrL2mmevCh8n9hkrRrM3y3OkSPM8GQHo/hsvGBbF/5E\nohahY1QInXuJBaNTUrV9KLhYZ/ehaORnXAEuNXGZlmdcEWPtZNiGNKIUWrQ8\n0EM2fnnW0c0hTr2unriJSoLpdck/gInlKa6Z4rWh5en9tX4soEbwv7FubRtG\nki9d\r\n=kvQw\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC2V6Sa90kJQ4CAzM45K42E0iQG1RasFiznrhbMZKeeqwIgJayedE/g6KAr48aX52vwPlhFd+fhgBYuhYvBGEP75KU="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202042210.0_1644052701349_0.059783116872715425"},"_hasShrinkwrap":false},"1.2202072236.0":{"name":"@bentoproject/date-countdown","version":"1.2202072236.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"}},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"1d8443e81e44defe1ab915032668da75884187d8","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202072236.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-FCpvm000ecEWa0mrDyvNax/1bINQg1kYI/fnLzzCVgyvevvO8O6KCEiWKhnnJ2Rt2qal8rj7X0ZdWxFUgQvQGg==","shasum":"161580605d86aa6066c213f4c0534de6abddf6b5","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202072236.0.tgz","fileCount":27,"unpackedSize":851342,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJiAjXBCRA9TVsSAnZWagAAXz4P+wasCUQyOTsc0jhV0KvO\ncspFDeWGoc/YQEN/Xa8MxQyMd3u2O5V8MOpVXQEo7ia6CiblfVDRcIbLzjTa\nqYk2KDPeuUzx7/AFX0V81sKDxFB0msELk6w2NAzwJH/Af2L9kzXuzf4IO8Ay\nD+SzFG8cjQPhD9OIwTSOLt5w0uTKGkHZy0VCjXKp0QPoL2zWj4+HaDU7OOOG\nt3bk7m6Rr82iCFNnNYzaMVE90+ypZQjJomUPYOcKP0WGpDrjuzYZTmGhgtZF\nvoOXMLp9Nh6p/jFO5GLTeozc7wxTcKehzUaRqVPwBiAFCOYLht8Ujk3XwhtM\n9N98slK2N8PuTZ4Vs4Cvbu9Ehf8T0rqYxHHITFND+kktwgMX7A4SOMgFRVdM\nUUJ9Ls1KfWUJqWG7G3nyV7uyR5kOnz0Ub31QgUu5xuNrZ6KdFzhtP5QPv98b\nxTb1o26OsHH9kHAGb7bKAAUvK6ktyNwhHPMmE3z2hkQldgnUekr/RgPD7GZV\n0ONRJDF8iyYpvuZmfyClqvjyab3mlYcjUFkru/fyLtBMjBJoJpFeBdDxqr8u\naP9Gb2EmcT7rshCLp47NLj2sn8QTV55Nc7s+Vsi3UHZI1kayh8smC0XGY9Ou\njwERq6Bo+hy1jIOve/n45faQ4Q+BNtwIuRvb2TTETq48y2jSS9PfXAbVX+3o\nml4X\r\n=LFue\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCr3Go7cZkBYLv+PKV+dBexdwLuR9PvB/YeQEiXGZyjIgIhANCYR//TLuxfFbevD1iVusdqsfGVVt01m+G9jZTCX1gT"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202072236.0_1644312000901_0.15546721912580197"},"_hasShrinkwrap":false},"1.2201262038.1":{"name":"@bentoproject/date-countdown","version":"1.2201262038.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"cb2af7d382510037805d85242e3f21a88654a20b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2201262038.1","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-gj7Yq2sfAPR+JmscaXrpcUoXpDuz4BG5em0c8FQy3pz0W07hOTK1lhQR6zoPDIx1V1Qg1tgjNztaZmLq0DNZmg==","shasum":"7ad109e45c2d3f7514e4adfe80a2825d4ac4014d","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2201262038.1.tgz","fileCount":28,"unpackedSize":858149,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJiAtzJCRA9TVsSAnZWagAArxgP/1B49boTMrNFqrWsZgti\nKD/VW10nOB7vL9s1WABXpD8Rr6Fc95bwQeNG+oQ0uvQvujPTHk4dsbXG+yDi\nVrJLsg+qzH9eS2SwBgf2TDkTQSf9XtpPHrZwZx2oCGi46MOkHpqgyxw+j2Od\nHKcmmsbgcCHzme48Au+K9eGKSGT9SxVz80Ury85Du1776KZFjbV3L/uyBlbh\nInD/qkTUsHg0k64IyiwTiJx3lfmiaKAfnOTJFGQQOZjjCyEYmMzh8f993LHi\ne3G4ymHQOi0EJXyPTPCb9IphvVg1l5/Hlpyqbjlaci70bQuDpC5yca2fsdjY\nJmXaIVlIyzm6PRl5j8hhpVmnHg5m7bf3Vy+dFt1TKe14eQ6OX2ucV3FRlBiv\n5l+kKdex2ASkSDBvmwwX33onNV/JDTfVOlL6RnhlQCh/77o9Ig+tTZ06nXSL\nA5gELFA4OlpfJGa50YueiTHA4jkQzLrY5yejy1uxFJP3SOMLO8YHJcN8IOYN\n2et7MJGaIJOZcqBCSzsaEAaGZzlyljP4yMVbojhnDoN/tijGl3+Ro9OpZGRa\nkFZHJhMTL41BwlMDBrAJAQYzmOKtvHcDl+B0wOZHhFL8rDs3kslsQAtgHwmm\nw2S4AVKHKk1LC1IuZLSseq764I5HmyGIHm21c8RZhiC51tlYufMQKMfHsoqM\nuqph\r\n=b/Jl\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDezVBD/ZB2X+ggOZ7wa7ND6DPTHNuNWJG/sDhwVDYwbgIgBSdDQQpIBgc3zL8GBNTE8U73BZKu4s2HUyWPJ19kFeg="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2201262038.1_1644354761093_0.118982471109907"},"_hasShrinkwrap":false},"1.2202082004.0":{"name":"@bentoproject/date-countdown","version":"1.2202082004.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"572ca92abd38a7a42e381c556e12e2d929f26802","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202082004.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-hgOK4dreL5zDHDyiFGNRVIyVkwSCIJE10DAJjD0lFr+MXXHPmbbgn5XHDOFcH6TG1l9XMZzyj/Ck/G4e7FNk2Q==","shasum":"401244fd26b86e751cb58bd1dd85a8dd890e380c","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202082004.0.tgz","fileCount":28,"unpackedSize":858149,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJiBD1dCRA9TVsSAnZWagAAC2gP/11BGLsp4DvdJi2cEHVH\nUW42J0Xpk3BJRzHQyrQ5JNQn1hQ2198etf3JP1+3SZbBhwlWs5kzLMd/65PR\ncu7WGtN+XtfvmzfGshpPV8a4GBC68Eg/upL8WNhspJl5u3u90g94mO124TRt\nJBh0NaTFkCK4fTuHnZM6HipUDhsK/YAveqfUGMJwYyTsdjtqT89O8oh5ZdFL\nKxpTVibYw9gRvhTD6iP6HQTo07N7CthtUBiszXhOGxFsfHmO1CEKiDfqhX+8\n3cEhSX0gDoesc65KKUbW+M2TqzB0RxzOt8wZk+V5Jm3Wt0OiCzsqj1jsm8ao\nZMpS8b6x4lzHgOpm8mDO8Xz7Iz4aZMwDGGLjGCtqtCwroesxOduMvIfBZ+JO\nAHXoz5FQ5xNcxPMY9zloOUw5dUsdLndeNccJcTq10pxS1evIxdA3GgApDW52\nxZGwJDmmoZkh0Ikco4bDvoFjx5u3WMVipQjWiF7pWP3iVL25f7qP3UjH3ulr\nrilcvo3Y/3oowJ4wE70FRZGm4uMbyKx5YdBmr+dIs7YBPtLzOXtzC4n90GIc\n2fP1ya+YDKst07jakkLZZf0mk+kQ4ljwAEzYKi66sAwkBtpxszTovJPekjOS\ng/5MDBfbKdck4xRKWzVlDifAcCUpeygv8UgJ+52dVrUdX6TwGlxCu5VF3k9o\nlO7s\r\n=0vjq\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIG710MFhg+2ugf19/ZCmxJmGia1XN2FfwHmFA36sDT/xAiBwp9CSnSw45dDq84lTe3KY/opHG5UuoKt0fA2vFp0h6A=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202082004.0_1644445021588_0.9346960681217584"},"_hasShrinkwrap":false},"1.2202092050.0":{"name":"@bentoproject/date-countdown","version":"1.2202092050.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"37b830a030b935fcd922e108d5afe28be61d68c7","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202092050.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-kjmv9nGtxndgB2JqLjfRT74KBqXFWUo+BgvWX5bcSzDFhUD01JdDy/A9xA68qJhPkqXoO14afLRIJAZYF2MTnA==","shasum":"2760b807c77c30138cc466aeb3d7796aac159bd6","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202092050.0.tgz","fileCount":28,"unpackedSize":858149,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJiBVHqCRA9TVsSAnZWagAAH00P/iE8eJkh8cIOqlD870g/\nCZM9nIpSSlxlvX0RdGD57E2lgk1ef+lONqAmUtSRm548/rGKq01dvaR9KIh5\nl0tOL2FTKRRYjtUD+SCqGltRV32NEATR8O0uckreX9LUvJSLTPLpt6EqToCQ\n758D4kuq8oOZTblLkvFiMJ1MorqAahOP16Dl7wGEzOv5FHM2nbk1v2jQmlQD\nZLfzNKLb74PPYpfp9ZWp89phnAn7iBXwblWgIZmtiWzQUd2fIDujmGtxNSm0\nTf7vNzfASPRV9WDUkkXMla2rOgkcUO2KRye94HtzjzClnk/Xfj/xJjNCc4OU\n/5hPO6xh2lDe403Md3leSfHvVDtM/P5v6SON14fxyMrdha8u7u1WsUfScOm5\nQlJAZQGxjCQ4AKMeWtTX4Lqzefo33oAWEcQNINvhJxlw0hG9To8ipBVgmJNG\npttrboTjaOx2xL4A40uszCrCSOcwJaPe6l4ChKuHqnrfDOKSq4Z0vwaUJyZm\nHHmyJduSoT/XDE/HYL4hXb/DZvYLUgXxLxwNZ8veWKCClE7zyT7ObPQsP1Ei\nHVWpCPgsPSWamdQitqiePCLc9O4dfiw0e4ghGl57vMnsbCVBTCOXoFR2qRwe\nJjclYhDmRArECKpV3BAMFBNtwnGBoowRezW7hKO4gQbD/bPGsmE7sBurT8Dl\nuQqo\r\n=u/74\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDSarQ+9OpXsKtRfsiEmw1sWXLNN8UD260HKRS8gVnKxgIhAP8RmeGCNdEraxuBpJR7X5XY/KcqkhFT2rVDgwRrf1t7"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202092050.0_1644515817984_0.5198834643201142"},"_hasShrinkwrap":false},"1.2202112230.0":{"name":"@bentoproject/date-countdown","version":"1.2202112230.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"42cc51fbf53c86e33b0a12004dfe9c35b8f5d0fa","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202112230.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-itSONKVBaQkwHoFNz9Qtamf+xH9jXXLnIB07zSPTa/g3CGbtU9rqHZjHEkLU3ETJa1XyOjGM4J0EKqEd5U6x7w==","shasum":"5825e1e1aadca9254694854cff4ecea08e78b080","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202112230.0.tgz","fileCount":28,"unpackedSize":938649,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJiCsQzCRA9TVsSAnZWagAAhO4P/0+eI7HH1Y6Dm78PAZri\ntsFPz+0PuaNJHuBsLBO/o9cApsQiDaCjJWJV6NinZsWzaPU+X9Z0PRDkavDu\nzuAQq0nlU5gwbvy6f0eGRfpSBvs8H7yQbcEc0QShSy6vWiFTiPg8KOQU6Pvd\n8/f9b4dNJtLdr2gZXrJ+glAfBdkMaW4JZMu4U2E+XDOnsQ+3eoit3RHmpRAh\nNKV17DrvBUjw8wSHPUkVBcQIfdnGJxP8xst3RY2RUg3juz42S6G8xuA7XzV3\nxL18eLSu7QZph0DcpkVKUt4BmozH5pQo2i01o55zNioyZR3/G35jw0e10gWG\nEzu0TtCf2RyqyD3SvFVpDeLypI+lBT0+Kwho642nppbgJvbLUavgtdI1a0Tv\nUhjC2eYkd0sHfyRmkZepb+mA3n5MwBucAKGF8OCBkU4AOV9tFAqpo3zGMLwO\n/OQbKlGq9ZjkZcnWriUs6iVdEqsBPC4CSalqsOnVH8b8I5Q50naSbyewBRtp\n13+z95NTYS6wE4fCRrAKgdSLUpX7c5SZZDdlHiwuDfk1u32/UN/exim3qacN\nD3jC9Sicl12eX2Q49AZQIbyFzAzjx1XY74Wn1SC4HPTfrgF27CeY6kGhZekY\nXehj/MZrZ3rzELwjCPM5cXzjUb0vdI9SaBFXXEzqvIQoLcdawqsmQ3nAYCPc\nqovD\r\n=qz4z\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDqz2WI43LXfcNRjiF/Ka24lG6/Dj/dr81/cyhZ9I+nIgIhAMfJGIqOa4P0rkww7Uv772IKH0T9WQwA0hWeKE5MYvVP"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202112230.0_1644872755581_0.27309508426865214"},"_hasShrinkwrap":false},"1.2202142035.0":{"name":"@bentoproject/date-countdown","version":"1.2202142035.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"4bb5570c3d04ec8e2a88418e8ed8b420e5b31ce2","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202142035.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-ZzqnjY3waB4nWEPqGMOefHGxsazMA91HbakbdZ2r9C19pRenTTJz/TD3OlcScMMS6iZtMkSa4gk0dhpbtFltwA==","shasum":"c3680a2bccebc449b6500705626182fba92051bc","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202142035.0.tgz","fileCount":28,"unpackedSize":938649,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJiC3F4CRA9TVsSAnZWagAAz4UP/j63ImRy51djs+b3WQRJ\nXhHuFG66o6KIlu/GhYv3njb1EsL81p13dBtenW/7vEOUN17o6rH3KFzpqc+o\nR9UgGCDE7QUxMmklFQhtebfabhdCcegccEEjFf1vzWpZ/cDuVzOLFUtqh8y/\nKLCvQtdtY6JgfVkzLdsGMqc0k3r2VtYbkNp5wqgV+/dnELTO2g605RaMicoj\nXqrjVkeDCPy8m5Hvhd9dqBNFPpUMqSKku6qwY8QfQQfIKq+Sqz1NSi8Abz9d\nPIwCc9Tdufbz/N2RMTogn09DoAOth7meGePuXpUjXbj9YOk745hLn9oqqUMI\ntVtxpbUmw0ISDrZkKTzruKNqjthGahL0pypwMQJlqwtMcBBhV0pAK1P/O92Z\nGmdFrBcPTnCllfd390zVv1UVp9HQ49LuI37s9gmEkQFZLflOZtHog4dNW5Es\n9rCA93giRaLV1u2acBH9G+Kv/8z/6jIFSFzATcHI7+CBPFBqQ3nYXm6Y1NC6\nEhKIZ4mICfzSjOHlKvNYQbnyiQNzfN+GHV1fiD5qVqdRsYt1MOP/R1D62B6D\nvC2RLpwO26g1307VQ8d98lmiTFS9J+h3XD1LQIcUMFhLNJ3oIBwK/J/xauey\nNo8N+RB+CdakPd+/0vTtKTHv96Wmjnl5iXqEVInjCMO4AY6WkI6f3NQh1PYs\n5RyM\r\n=gkuw\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCVLbnEbmDc+VOttDsw8vuSjMIeOCFmdIpIBwfaz3cLjQIgZd6y9UEPq+pmL2pxZbkEtQ1qqUq5Zg6GDfKphbmhua4="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202142035.0_1644917112402_0.30829120564960144"},"_hasShrinkwrap":false},"1.2202042210.1":{"name":"@bentoproject/date-countdown","version":"1.2202042210.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"a656b221ffc7e0c9f092bede5668a546628e9512","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202042210.1","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-ockygZgHHIOHs3b4FvDpgCmPcvu1mXPR/Hg4slWngOT4znGalimYD2sEtVHg5SEuBoPo9sYRwbsnzhtLhA4gvg==","shasum":"e74e5be6eef0451136346b4d1f41e68918880226","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202042210.1.tgz","fileCount":28,"unpackedSize":939148,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJiC++LCRA9TVsSAnZWagAAxMoP/R+K3QyrPl89NiuOAXW4\nuDceT1nUaSoFbTaAHOWlol3MtGUsCn7GIQr98u0BowJTnXhFCxWiJxpEP3MO\n/BzRXFmV6XOHerUxNmWvebH2qRYKbFk+DoUxM5zu50+jmM/XEiUGusDCBvGE\n7gIOoX/cxbzHeId+B9LywZVss3s3yK39wD8UcJGdq1y+KytcbRqB8od9ig+4\nGk9tDlXE9L7Fs90QVGMO0s3PA6dmyc3y0QKC2ARlgJiI/3+b60TGc0uC/RXI\nh3VmcnStzjiQfE6k9hb+B+G2DWLPjy+VMjxdcg3sLyzlw8fOw398fzFdG3hu\ns/NiaYKKHxt3+dg+DwaWjq9iPnA1TAAqpvNE4rTStf/jYzc0Brq3P5Azs/m1\nTJ3EKqiw8njE6URAA8M8TJpM1TSJ7TSDT4DNkC/uwNuAmPdV3Q2r8QjErPQN\nIim+NCank/mGeuWJpJDcSMpmd4EVf6Ddd2YCZWJa6z445zsa29Irk0cRB1cP\nZgufoAlL3WlyrNEh6xBqSS7GINeus0/ko2mbQRR7PU7Q9FtfzaNBRrlqpOHZ\nLGcEWndAHK0GsuSsQmk7lXHZXBKf14W+EgIvTvOzV7gmFYeT71exLOQxKK/a\n7+OnMfRKA1tsmEpV7LzNJUTvT3q2tNiVuhjdicG77ZzLE2uOakNYhDc8ckMg\nWEbt\r\n=Wcki\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICPTbxokzZAU6lvT5lQTlVK4mgLzwJ8kH0LkEKcMTubkAiEAgL+tRsKeW1O96mCMACTn8udZqmu+8E0hY6sL0/dc8T0="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202042210.1_1644949387546_0.3359858817128445"},"_hasShrinkwrap":false},"1.2202152253.0":{"name":"@bentoproject/date-countdown","version":"1.2202152253.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"a50f1711cb8aecae95387e7f6b1fd1862206166b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202152253.0","_nodeVersion":"16.13.2","_npmVersion":"8.1.2","dist":{"integrity":"sha512-1ai6htRpPSqeZnlY5uyoBEMumIhu4c/Pg+DftNgzE5n8G6RWs4HbUtRRUYiCrp70U3ddVxsVXB/HT89QH5EdAQ==","shasum":"64221f95d3f7f6fd735d7d6ae9f08d8e167811e4","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202152253.0.tgz","fileCount":28,"unpackedSize":938649,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJiDL8ECRA9TVsSAnZWagAAK/EQAJClNwIJtp4KhhvXZ9/b\nENp31hnzFNV7y3kl2qaWqymvGnnzAgN8YtTu3ic2n4NsTS7WqphQs1I/6nJz\nMF1kh+FYtSYzIh5eIFImbOQ1RcrVUqqWEuqjffx7bJMjnF/urPEJ/JTx1cXS\nCk0G/+CUCSNSVm0KPwT6YAVS49wfVutTF5POuns6PkvwjX3/SFLYsvSxuRLD\ndhFWD3caxn1ZpewvzJHN0+JorltDamhFeV9bgHfoxjRAIQweMMHcjDsamX0f\ntTut4oaRRu+AQfXWWf/8S2/nwt027qABvATYtYiBg9BJ/Kvsf8A+0Eg0m8BO\ntOSlkm9cbgtRDdMLeQmA9q7CkvDUHFI8LrQEAtID7J4WpNjfd4RCo0Bzyj/8\n19nVedrfjqbde5mXDeMnK4T7fdj2WSPDijP0emzc/oDfwaBOZyMds087z+9s\nS6DSMhVtXfWwMvheas/vg3+31JMM1GUB3CRqedH1DSsSaX/7YOawlFVWvMgQ\nLWE8XEO5cq80B+HWlC91c8gHWuQld4zqRLp988ZSPZWyKj8+ZzR+2Ik13rWK\nqQT2GTVKIHPwl6kYxmWGDrUcN0JcV669QOfjdEPBM5RDPd9FNsMIeogaph5x\nFxFTQ64pEM5dZTefAeuMfnFI00bD2wWGJGnAo/HF2iQkF3dwgy5zunUh/QYp\nRcyN\r\n=Z1Tb\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCHz4NH/2dDgIW1D8qCHud3xJc2CLio18YvjEV88cFHfwCIQDziSMNbLCtFz1hqn+uRRIp6yLoddesIo0vl5n4Oyyryw=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202152253.0_1645002500423_0.854462665242496"},"_hasShrinkwrap":false},"1.2202162256.0":{"name":"@bentoproject/date-countdown","version":"1.2202162256.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"7548b64f77fe070829e46481b6fa247b8813958a","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202162256.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-yM5fM8FOHVAZTVRjjsPZuFlXByNT63NX2VEEjzffbEL8ApyD4IgV35voUZCKBZ8weSkEhf0jyN/i1qZ0fIsurQ==","shasum":"4fee56e81326fc8f4b73e039176bb432838e82d8","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202162256.0.tgz","fileCount":28,"unpackedSize":938649,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiDhVyACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrwSA/8CoyU9j0GbpXB2+kPM/5+6mg9G2s4dGZQA0GZ17w5cT4pGUEH\r\nuALlUbe76cmONVETnqJSvwdwpEazyLO5Tfzxk5rOT4BDY/DemoiEAdfLC45a\r\nCU6KWulriXVFhPuiAI3qzFWzpTn0pPQ941ccPmZuGdLluxSmBdWZMeJuVdAc\r\nUJYsX3S49fdUEqm6BeaTT/9cVAsI2oyfqF7DDreJbeI+jVv8u7Dh+dUooJGG\r\n587ic4K7FbEA09Fg31vaCtv79PdXcFh4jzmoeRct0P3k6lj2+6q94ew5gX49\r\n50Xto6+tmxMFfdJGrJ3Ze+WFPIRtxlY6EtdTZOVBEoaueXoOV/jUM2JWNCgR\r\nVBxneKNndXdcCCU4bXkfsNstULenUR8UYhHV6FJ9uk/eJejY1Rr6gOySaHgW\r\nkXBUzSsh3Z0+o2y+CVrjkonh1FRzuxFXIY1Yst+bVNVDoRad5ZgaF33i/QTy\r\npw6zj1Qe1JW9mxQ1DTwrx63vuvIKmPtqOD+NEE4ZjFwWf2Gg5GEe0kTVMMSo\r\n/j7JbVEMr29+FMIhRgw++9pcnUP2dbHywOaEwfBhMvNmsy11W3jQBkR69Yze\r\nYtA+B6CZhYct0BJ9uYrnDy/HcfW8hJnBAuadRrnsTJxxGYnI8+2nX5VIkWz3\r\nJS0vMU05WuWYB2JJyN6V++S/4jvPgojuZaQ=\r\n=Q1mG\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFyOWZqPAB6rAARttoy66nYCzLiXNh8h7B08OTuT6XkoAiB9tQNiLxjlYY9TBCFrH1CVQbxhLv8opzU3AEYqHcWvKA=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202162256.0_1645090161983_0.35056205709292243"},"_hasShrinkwrap":false},"1.2202180255.0":{"name":"@bentoproject/date-countdown","version":"1.2202180255.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"8708c2591965df37c54fa25ae829421f10de58aa","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202180255.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-gNlpAIa9Bd5ivmupYffoJTW+EJaMtJq6J5dLF8y7WX1SdK2oh/+bQUQLQtfZiYpRtrom6ZF7qlf0pwkZ4o8gjQ==","shasum":"3b1a05a143203e1bc713cf721ccaff47220d099c","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202180255.0.tgz","fileCount":28,"unpackedSize":1743583,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiD2qcACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmr2IQ//WYiUfQv3K0fFvqgeaP/crtMcq8S2uWjEq8cb87rMb2KFDqlQ\r\n8B1If5n+LmTKiVmnkpNSpV9LtrHYmoNGZAkFLbriI/wNh3i/ueinf0x/s3BG\r\ny4raGI1WatyJfsMAR1olEKLehTUJYgf3gOai9AysWqV6wiwvaDN3DYzveYCP\r\nn+fKD0FciWThmSXUdGwa1PerENyaibBOI3Ms0SQ2aw6y9iaVdAWRpmHpV/3t\r\nzTjO8Gu2qI9vUV9Ox7qPH67vFMW5UHMupRJWAqxbp1f40QNJknANm73H/u9A\r\n2QzN72x7JQpVvuM94bYrwj/q04HUfwktq6RNfXx3kgiy9aLmvwVDTPXGaJar\r\nCtNzWIIzXW6r1EIRZ5UauFGTq3phveBaV78iOyb5u3DNCdJkmrJNvLeCbyEs\r\nGENKtyfkCw+bI48nWaI8JvmTxoNJffeQijTW8BPqWd0U5kEPqV60LMvCU9xc\r\n+/tTmv843S2u8JpksodRHe3UEOO/DEJuBkrTfLEYZuYhp/NNROSutmJgnAHI\r\nf+MASlgcn2Nhlg9wrFqo57SnNeUY2bqgRzU/NY4vJxDK4ocwXDx19n4U1mL2\r\nr4hblvhRqP9QNKmtenRLu+H7qinXoNNOc3FRkIAA3P58CFpvf2zASCUJlOn2\r\nTkqZmnnM4EgN9ZsSxCy5Ft32/DWtW8313E0=\r\n=oPly\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDTdVPZVVVYjkvuIo5Uyv1SEJzhhn07dv6OFVDGBXbq6wIgFBkC1x9RLD+7eYjS8Vm1hJY89g2vQLSWy9pSyeu0NcY="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202180255.0_1645177500423_0.15389420238782736"},"_hasShrinkwrap":false},"1.2202230359.0":{"name":"@bentoproject/date-countdown","version":"1.2202230359.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"02e5f5f51d0375b35a2a20b27815ab79d9767e51","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202230359.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-+c5qKORBW5YEhdkg8g8+dsMuCxsQD8dXSiJ/6v0eSP2Ni6iyL7mIUiRdhR0q1kCoVkTrXOzp0luNekKTAcwjhg==","shasum":"b2161efd44ac0b495eaa98b42ff1b31839d86d6e","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202230359.0.tgz","fileCount":28,"unpackedSize":1744111,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiFf6HACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmraPQ//V0eBot+GYqZ7t0CfaUjHlkvO8UoYZw09qQ9d025mYhqjbTaO\r\nb2No4PDiDZwF/9NpYG/uUrTOPG5MrBQeFUKTI11xNdbSuB47+xcb3OqaQjCH\r\ntEs8dIIKMuyDkU6d8TDNhfPs6nKuOeu7sbV+jVFlpS9pLqMGsJ46srvHSDDR\r\nwUU1uwhWPj8TrP9sFHKGaGU4f3pjvhNqsbH5QQVE9M5MehHJNvHOocy8xLks\r\n0zKC80oPrvWhNnUT/9fN9vIAlqlWQfKmK9Ec3EX4PesVFhFzreNteQelXX2Y\r\nQXqA6qYWQbUZ7qfHJZ+tpMgtSAJp2OmdPu6evo4t7KCtjia+T8TdFM/95inH\r\nUwXYUsWqlBvES9HKL7Rw3HsbT/po/+W0ZyzTmOmOdpl9B7u8Z2IU0Lt7OD9o\r\niAdRhIQpxLal56VzlhCHnVkv0yq3bramUg2iiLqyqiGvL07GpUbUpeBOet8w\r\nDjtbXa1r5u4OtzL+GmSsHx162NzAl1pBsQxsteGIKufZbCw5ixg0tk4Yu5dp\r\n3uAK56RyLuJwR3NAcd/9DiNX+sa+WIXxlLAZt1xRg/K0MeNvh7elPe3mdLmS\r\nhfZv6Ge9Q2qAVpFsa48BfjumFgptS5fBMv8tdtHpaXIHXEbQuAb1QDBVkSXX\r\nfl7uIe1ItyzlAkz174WR/cZipSbxdw3JFFo=\r\n=MmXV\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFMbql9m1/LYVmws+DPnMy1y4/gir/rQev5bpmb95jlFAiEA3yWcvHBnK+sR5ZTNlpjxUE6YiJB98L4bNag06scYwTo="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202230359.0_1645608583328_0.6727393692313679"},"_hasShrinkwrap":false},"1.2202232232.0":{"name":"@bentoproject/date-countdown","version":"1.2202232232.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"66c8923bb334f4cf267bf8feebf822629a9129ac","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202232232.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-b4YNkYLp17XiQVwcP+mDTCUBKmlA0hI95/G0EzkwJnSWkGJIn4zfy3VfOkcRTTroEyeirbJNHRvmexcoFthWbw==","shasum":"7c969225b680d05f2b6543b309b9c90ce9d2ee54","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202232232.0.tgz","fileCount":28,"unpackedSize":1744319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiF6LXACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqgOBAAmJhSHCzYK4QRYx8wy4pewPTLSQN59PGDwki8QUM5QhSd44NI\r\nXaVauXnBrNp9AzfsEfpIO6iF7lOP66ozEa3tc6h1e+jPSYAfSW49lHqSqYR2\r\nwN4Qmf+BymMSrTaLFRX8+evZ9/jQk1Mz89ctOphjXyASMHzcITGMQj9WKU4f\r\nlqS3Dfs6m2KcIji0eVs5vQz73oqPqysGDvQQ2LZdSf6vGsVS9POBi1W4g0Cj\r\nuiWZ2CsKxirePBr6z/eKTjukcH7rlgIP9ii2L3YyEtPPtyaEY/lqe4wnRsT/\r\nY2Z1rKUJFQF/DJ17+qSul009tKzAE240XdBeI74JMBOEXgSXAtXQrOpvI2bq\r\nkMiQ2784/+ORPwoCPlJ8piLq7ugdh+Q3PSeIVazgeKoRf/eUbUJbZOiAm2wn\r\nwwk0ABl7G3xNtXVeAp+jzrqK5lRVq6SVEL8wRlZ2iT4ak0dJQvbM7bOD1/f1\r\noiW/BDMw40OtX4EKoyeHOvLHPJpzPzM73gkLsgEe2nMvyTcaq4ZK7wkxjuwh\r\nmpnPIa6MGlpAijHrVg1oRAptDmYhHKxQ7FJPgE6BiASuQAqyty1jjcg44n48\r\n1Rt6DP1xS0LoBol4T6YtzpCPeuvvBqiCgEDZ430PkfOVOhBGiDMyCJJYQALV\r\nIW9LY734gHpstBguw6pyWso9yBItoGS64gU=\r\n=UjKO\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHYuzsd/DswuMch5t4NmfN/sHJjzqV57vJ+xw684SagaAiEA2wyOYTNBeYxPkkKSSw22PQ/0z9WlZGa1Yo3otBu0gXQ="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202232232.0_1645716183150_0.257616493050415"},"_hasShrinkwrap":false},"1.2202241911.0":{"name":"@bentoproject/date-countdown","version":"1.2202241911.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"d0f22f13b53d3b67847e18749e07ae4640258f87","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202241911.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-P9qeKyWBR3oc8G0p/m/GxN+7gWf8lvCAqM1tnNjzHEPRv1GK80FySdkWPKqhhZ5s5+sGFTXSwvoHYkUq+DKvLQ==","shasum":"1d5c6367b0bc18dc553a6da8f806fc12bb65016d","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202241911.0.tgz","fileCount":28,"unpackedSize":1744319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiGPMrACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrepRAAhV1e3m3Qz5cOqHqU1qYovYkEyhK3zeihIi4BKVTiVvNEsZLs\r\nSl9X/7vjDvOEykyRWkU/3auDag2v+PD/vOHMAGstNRCg13LTBAoU1Tn0nUF+\r\nR5ng+I69zs7ZGgh+0GjeQ48hOaNVuqjrjVfHInSW6y0WQf57CiL8M1j4j/Cg\r\nxIIgOzl6o2csVnhKgWrR6Pzy8wJ8/FiSTTcY/3n8C7TSX9rXeGlQ3W09B1AB\r\nNJWFeAfdw1UjkJBBz1+yt3fUa5NsZ5RLRfc86u9E8H5TvSq/m+sQjtqCJ4Q8\r\nkCsekuPYMvIchzZQWVVnkRelfLYOQEUH0sUAURTHh4WYbk/aOSC4itwuGYxP\r\ng1+EZAlLeuSSqeGtNw9fh59+0r8kcrtlzfhJWsM9L/dW0muN8iYsJCx3pK/S\r\nySgfmKf6P3i5+Zv4Wkdeg95XWmWPhTiBcWDdZmNoJ3BNs/0vo7blZJc3S3/3\r\nVvap0uVQn1I3ubns8FAWGAkLPvqG5VzegLfyyFkKUny0W8/rRa9gY98ZpLtD\r\nv2xIr6p1zS8rFHBpobhH1HCMnH8UrbmbrzS/G2LK7cQ4VaFYE1m2rr+Lwu6u\r\npaYxz+gRV7MoQ2Lq5mIIBrXAoTkf2mUR2oZERo4NxkEPqi6U64oEmP2FjJx8\r\nKFLYZ7Mr6jNKTCeR6bpA0G4ZhLy6FI69UAU=\r\n=Jlua\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD3IDQkKAw4LHHV2SUE0XzCc2OWal1a0t6UfZHSpw5pwwIgbYAw5lTgUS9w0KY+PFhjGNMnfq3KuD7MxBo9XtPzuyw="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202241911.0_1645802283170_0.36123325772427695"},"_hasShrinkwrap":false},"1.2202252101.0":{"name":"@bentoproject/date-countdown","version":"1.2202252101.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"fa0da0bef1bacbbaabdd17ebdc31b018e6450c58","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202252101.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-kjUBULGYFMTSTDYP2hH6FqD4+aTLoZ/SDQKgDx6ACIOAYyP56PvJnT0cwW1mTiphuTUISL0Btfar+93KuDIJ4A==","shasum":"64b4a6192a8d33d3b9b7725a6d64a204990f6c1c","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202252101.0.tgz","fileCount":28,"unpackedSize":1744319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiHPxLACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpnWA/8Dxov8K0odgbuPa8WZFtJb7jZj2xeIpAKyA25cKQXaSTe9a9a\r\nZo+n29gGZQMmH1uOCVfJRvCZF/CT+qZ0wgCR/m02GPPpBx8FBuaZG6LORIrF\r\nJgoPRm9ROeNM/cq8pLbHrpBU0KGtPN/maDoxcTmNyYBt2btjkn3n1tufq+Bp\r\n2vVMmmYJvjzZdXLFZWCiRA3DVI4/opL9tDDqSmQAhOswOSu953uKErxS+6Ub\r\nLW930HWlz16jvyL0B6RQCONlfZPlg8sw0V4vSWwFV3Ozzb5OWN1PinzabxC/\r\nX32TOQQBgQ7VYYTJiVFD4G4tzeqLBCz+8+3Yv9zYIkvXvpiHxksF/hM/Cf7b\r\nmB7I8ZYishyIRClvlvt/PYzIOVVMwOB4a1bBZakHvD4/gqNB1fAUv9LFKupj\r\n+Ls7YolacjIfCpYKdIekaU6w8mff0tkNEkfyCcKNETHW6C/mmphjn8pTq7uf\r\n8N1Ecr4TE+XGZRRBIMRdgDz5qlO+mysA1MB0S0x8moNBViAhBkkkSsjLgp6A\r\ngFRnEGOLitLLEYBZ/1vnNqkVjL/VfzqAZcylPDkCHFFAQ+dGNCQvduCJgnHR\r\nDZj4ACLQCzixhgD3zf3/4Yt6olpoWRLv7kPbLTQpdm2PwyiAbM0PtdK8IzfN\r\nfokCnDsAkakjMPZLJGiXuv7svnDhtG+Hc38=\r\n=7Crj\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDAFsTrvnCdyGRaMrpto8GNfv0x2/4xpRJdqVE6HVtOJQIhAJbgWtGIiQ9itFAW9X3OTWppUyXaO1aeDFZtBPnCk3zf"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202252101.0_1646066763084_0.698513823941229"},"_hasShrinkwrap":false},"1.2202230359.1":{"name":"@bentoproject/date-countdown","version":"1.2202230359.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"gitHead":"f459124bb58e0a0d2076f658b8fbe3c9db13a04e","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2202230359.1","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-yCjyWKaZ9vMRVTKCeSosFEOjRpmAUaHNBXNA1dtm3e89Gk3bEBqUDUwCtg8o0Sju+HOkyrn1ilS8RUKmV3lkFg==","shasum":"b1ccb72b2530eb9401acf170fbfcd7aceee6ffe9","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2202230359.1.tgz","fileCount":28,"unpackedSize":1744319,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiHpicACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpG+w/+PB/Ab0S+IiJTH2UVXR4wQTbr46Nm+i2E6iFZ3QlHTZnMp/rU\r\ny+rGp8N0O5DrWz9LKH+pDTGtPLEyDhNrRYAZyoSuWW3dePYK+u5RKxmragMG\r\nE7xJmdGOBLmxkFQf/FfFAzGLs2H5yCErvUznZkHNsglAAyqCRtSq37UxpfU6\r\nV58FR0JtzIq6r1XRHaS5NYNkiWp1XzS/RTk65m5QHDt0jHaPxo+DzVytyrVe\r\ntcVo3h76pM4JstLYJeZWLV/QMmcZQVPyqvLiQZTNG8Ni2bqZOFHChfVywYID\r\n8F3VCECfZnXSLRZr78xlEFkSKaIIIe8DLoJObhmFIuHsNdSndfEKa1gJAS+9\r\nscUzctxGnZdMPGL5j6Wx8GDzXthj8FQa9dhSgM/FzeN6ZdaLLwKJwidwJfvK\r\nggU5WpN22bus08OryFa0GlxeW0OjkbTb8WeyNMLvhl8V4mIXcztNVqUn029d\r\nsw/gLNv2Q+i/0ZArDN5k4gOmQolNtZaH/Pa0QVc4F0MTwxp8d76TE/9mwImg\r\nl4VncKBEKPnEY+ja26qP1xFMr+eErrYVn+Qmh2CwdYSCP4hzi+VYusbT5L4d\r\nor4y9nvOcptFzXOJQ4Qm6gsnkKwESuS8rx2NdBfU5aDQ5oOZx8WCiq5a7W8s\r\noitErsIybd7VeLid5+6maA5BubqKeLvR2+I=\r\n=7FVQ\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDCZqEpe1BwP1hQ4tseQL4XwaJPkDrewglf9qsCuAj/FgIhAL4E/mC0Su0TSwwa+0Zg9Kt9FeDNq0hUqV6Yx0Hg8I2i"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2202230359.1_1646172316261_0.079108386635663"},"_hasShrinkwrap":false},"1.2203041950.0":{"name":"@bentoproject/date-countdown","version":"1.2203041950.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2203041950.0"},"gitHead":"419d49d2920fbdf4bf88e8efc3421f7c37ec209b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2203041950.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-63n9G74PBYHQMsdACn058dirrbANleNFs7tjjIYddftxmin8LeWlU0ZdEhbMDKlD/wcQsRHrMslepiHAab4Edg==","shasum":"f9d1748cb6a619e23fe7fb5a61ab3c793bb0d597","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2203041950.0.tgz","fileCount":28,"unpackedSize":565895,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiMNyQACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoW+g//Y0rU3PzS/oX3wtdtWtKrFtpiEosNyCUyaGL95gPjHm4Lg1ia\r\n5lNLrq/3FHww/jMGtQYXUYPC4QiMUramg+bX81ABahsyzD7D6796ms/fUktP\r\n7Sc0ba7jKsXVcUybgHI1WxfNXLA6hNr5SWTulI6VJsSG9K0WR+eyKLnxGR/4\r\nWubsI1GQ8Os1Z9LYUxpiZw53qSJyMUDOPIDxwiATm+uEPyLjEqz7OFfhVVwR\r\nGFCJiLbuHUF6vZMjEHvi324j4POyu4ILTM0AsJzuHugOnwUG0+603yYjjIjk\r\nxvZcYIPvt3FFtNq7S0sb3+RJ3FDnWFJVi3hTTjotqJKTBMu7ZWrbwIBy3NsD\r\n+dBCET7L3Aj/+U9MhiqOLmd3dARXp0oleMUGW31alWkF0moWTL+kEXYOE6fB\r\nAgGe9vYSNsgI8tM4uKqGi5EHeSJS2SkwVnrfFOeEpip3H7SzOmyAtLcUXJ5m\r\nNK27k9fPQMBbJcKBRXPw0YQOTPT1KwU9mNPb76HtyyxKmV+tPtAD84dWBa2p\r\nTApRoYWO7ZxRgkHwm6MXksarozp87+cpnqtaAFThBwEcrKItfni9mjz793me\r\n3yroTYmYkhVekTIPI5s11f5dda9nzFUjnWBt+WGULCzqL3DqG1j7yQ9Ii6l8\r\nyOzYlRAGxHpFmATXOnBmUoDb036cIUjjSfs=\r\n=pevs\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIG+afjRB3lwj/97XiQGXsd4K1kZkQ4M8wVKVRaK0qYA4AiEA/V/imfG4sdLf1SSb8uz6aJqH8M3tYL7Vpzcy4XZklvY="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2203041950.0_1647369360231_0.010002460409029856"},"_hasShrinkwrap":false},"1.2203151539.0":{"name":"@bentoproject/date-countdown","version":"1.2203151539.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2203151539.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"fc739c0d339dbae236fa53a87188f5f7ca58f25c","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2203151539.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-pjCnUd/rThX4LQ+7vw1LxQZG24x2U0aKvvI2UGBstgIQxuAQMOTrRmeSeYbVpIMEp65SFtEjpp8IfcO75v+2bw==","shasum":"410fe4a7c39188559e86a665b8152982078e806d","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2203151539.0.tgz","fileCount":28,"unpackedSize":565895,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiMZ4OACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmptoQ//cXYQpvj206RbXBsA68HJPZeKsWBwSbhWQ6zIRldMwyDd0+48\r\n0kJmL5SfeLxrvREIUr+tJAmy+UXFnlcQtXCWnOqfdQW+GqHcEu+OJfRUhZJf\r\nB93IK/2h6awVv0HzaZtIH0B1FfXlC0yb/G7i/hp0jeA7XxynvWTmNdD4abk0\r\nPZJV4Qr8WPqph/6YWy9+XQ0ktXbpT0qaKJ6zMBsMdJ62oCC3137qIBJgeekB\r\npM/1pLyMyBGRDYKwH6Z90GDOniJJFvJGm0WYqDT0FTf++1D/2ostg9p0Bzj5\r\nPbTd+fx/ZvUgsrET8Y2LXOKxtRpUm/2VrCAvUTJS02/Rp+TKsf7Cw+jtN1J3\r\nF4XKzL27voESCnzL3tWOXRTtAxNUokIAlN16jdsI7O3WVWNBzJG9aYwO3fgA\r\nd+giil5LGhtqcjK8BFD88DSZ3MKU+d6Czr8JPUCszStwN837EjEjfm/w0clt\r\nMX+XBqlk6tP34wLXIEMAX/2CyFa8eqY1EHNQg+Il9/uO5x/KVrV8ERiFaDWz\r\n6NEI/J6C7wAA5Gay2OStmPHQGybqCKLaVrHdwhsEI5Fj+yXKXyNrdLEmBBT+\r\nkX58tX3u3E80W2pTvCLOTw9wMHAdPzpqd/nX78Cp74O461RE5MxVLUzkhqWY\r\naS5+8f/m3L7brA34IckGjezmp+ACnJ1lkwI=\r\n=XXqv\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAmXfxa6JaB+1+Rdl4ltHv7aAo0l0nsM2kdcS/JNQkZ1AiEA6PBEIOU4VNLNJhZzcZgr3iNUthkA8yNrFsckpJKsaTI="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2203151539.0_1647418894048_0.7609526538543105"},"_hasShrinkwrap":false},"1.2203172113.0":{"name":"@bentoproject/date-countdown","version":"1.2203172113.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2203172113.0"},"gitHead":"96b2159ef70d24edf6c33303cb76a623a4669cfb","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2203172113.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-RuyEne3w7yJQ5pvqMr2yKDAFfAhTtk2JkN75XR7sKtUy6LmFwD6f/XYgr7gYmjIwyFKKhJkTL3Ec7TbwYVtCgg==","shasum":"bde0844acf04526bbba9ddbb4a0db4ba603328ee","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2203172113.0.tgz","fileCount":28,"unpackedSize":565895,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiNEFjACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrQIxAAlco3LkAhk9uE6OIHzTo4Ma4f1jnLQmZ/AulwTciUL5bfouW5\r\n4bzteOVw9bE3CFSeU5ab73Ys7Mcwqqz9VkksvR7KJxIQur9nCX71GHSeZ94d\r\nLf7vhbANcFt8gI7ZZOSNqKOjSsgKoKdOarikFu8t90fdiadwn9BXUE9zrbws\r\nmrPNtuNTBPQhrz+XOgLEfFwCgPyKCoGa+I1BxFM8iDWevyBsyjQ9+IsO952+\r\nJ0SlDRV3CYdyCyD9W36P7pOT4SB4XC/+5lfzveVBdm5u+izyJYGRPHs02Sdm\r\nX26Tm40/RXfZYBl1TDogIPUsfOZ2hZ4a+4aalBWq2E4TQC+3s3Cg6iZxRHDP\r\nk8yuyyhjovU3tyQeDWsF9GgKIklpetJV2NvGQvjS9crONO80GJQmAM0C3RPp\r\nKVvdsre+l1oj4pXT9QN1bjlNcakoj4dEFUfjqK4RhEBZ2WYo4nGI3oqrr2N6\r\nPNkvVRC4rrIPgk9gl6VpatiaDtTyT4W9VZ4VXK+pf35JSbko9ZN20vb2b11E\r\nCmk2Xdr7GpRPh/7e3XayokpeYcc6iHfhNwBNm5zwQW4aHsXYk7NEkiFLwybE\r\nM5eV+LVv/6uxD9wvwWhpTr5aWr7KGcLHpUxonhbAPI6NSm9uyPCMo/WYta0a\r\nWcNtw/jocToLWBNt1XqrVCR8M42ZNwS1/IU=\r\n=Y/e3\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHsFImZdCc9DNcD0jzvdf4/jYpuEKPe4+gS0OWvReUVaAiEAwlcrus2/vnIkS9oTHCDxZhq6ED5BEoqlBeHvVsJAWsM="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2203172113.0_1647591779107_0.8889009477053404"},"_hasShrinkwrap":false},"1.2203221937.0":{"name":"@bentoproject/date-countdown","version":"1.2203221937.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2203221937.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"11fb2607ccf78c526a38e31bc141dbd3ac75d326","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2203221937.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-S0I6JOcpmbk1Myhqymmm/Y2xxkluwx8WXlwTXt6Y6Fvyvr3gA4meaAurn4Po2MLWflwmHHTOBu4HYm2F21O4Rg==","shasum":"b4272989a621f008111b7f084892e016aa61a84e","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2203221937.0.tgz","fileCount":28,"unpackedSize":565895,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiOtliACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmplzg/+MLRbKhjgn6Xr1MU9fSJSIopVybblLlNFXXT9MF1RVLBpB+Jw\r\nJxsNKa+PvKN1IUalyAb+W48xYFAI1/RJIqmLm0Ye0xmhpnJzLMH/hvRrsPwZ\r\nkokG3ykkUVBBrj6v4+zIJU3cdlSckzZv+jRiH30bhUzIKaCMb6Sfw3AdLdbv\r\nzzhZJLrrsqJiekrtvK5C4cKLHRP959c9ZW/jTdGYd13S8fBF8w0rc1An6QNP\r\nDBfGoWRdgCBDmN5HIhZ1korTwCmeNNy81IchJfm0wq9KBHplwFJtpOgfgqvT\r\n+/nlHcP0weiKSFHVRIDpx7ot9P5W032+MXaN9xhAnWl68Pom7YYVyih69qah\r\nLjw65SJcDMmSKzp2HIKeTMuazQd4pV+CQp2vgrPjUKWK6zdrPbhuumMT2J5X\r\nhAMZd154aq/SawdqdFVG9XWXAPOazEac0D5ft9/qJJhYxMmtqPzyVXSV6LxU\r\nwY3sgT9dZrJi9zQKFISSynC6PxuksrJv3LOxdyrhGetWesSx2vUPju89v81e\r\nqayi9qyxCFuFG0LQ2Zi3NN+3ql1XAs+wvZuD3a4dJoqVqg5bISfCczj+PQC2\r\nJIZ8gAtLO2X2LZj82rBDXpKnvN7T0DtlQ0eVPbD6gRwuyAAiXJrhrp2yv8qx\r\njGZ77oXFKct827hzaKG3cqehuEZYqAWVAfs=\r\n=vZ3m\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGbAq2wHIgLFiAEHnxzU1MEZ2AQxzlnOC1OUg1yireVsAiEAzDHK21fi6VsSr6JbaEuYat5rV7VIGzvr0JZEChcA4qc="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2203221937.0_1648023906366_0.9596145042126867"},"_hasShrinkwrap":false},"1.2203231914.0":{"name":"@bentoproject/date-countdown","version":"1.2203231914.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2203231914.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nWe don't support the web component version of `bento-date-countdown` since `<template>` support is still being designed. This effort can be tracked in this [issue](https://go.amp.dev/issue/36619).\n\n<!--\nAn older version of this file contains the removed section, though it's incorrect:\n\nhttps://github.com/ampproject/amphtml/blob/422d171e87571c4d125a2bf956e78e92444c10e8/extensions/amp-date-countdown/1.0/README.md\n-->\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br />\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br />\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br />\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"9bf7cbdf0dbb4de2bc6b81fe042e52c990576b61","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2203231914.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-GcKuOZmnvGdFUvJ2PL1pgo508DzKiluPvJTIxQKj+32EpQCauCNBR+nPUe+FhLLBY699yfT7b7QrVxMhNgNJjQ==","shasum":"c42d9a2bdbc9ec15214cacfbef517096e514c64d","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2203231914.0.tgz","fileCount":28,"unpackedSize":566074,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiPCpjACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpQvQ/9E68oCEFiMXEyH7bw9lqJu7+/bMPIZtTV9PTLyVspbTuHIHf2\r\nIT+8gov4H3sP9i+3leE528FoVVZRMI1iBvr6plrWsOUDq2CejNhpo33mjWJ2\r\n18aRmjjwkU33DLmTXppZ/xZ3cCl5wY0Sm6m/uiyUVKSkHUxg28VXlHhqO0MV\r\nnZuRr7z4NyIvMWi8WrrBdgkOCKg/ZWFr0mwEXtl0sstaAkCL10UEuBPmcclX\r\nWi2T0NilWOX2wIacZP7Lz0RgLR4sXftBMBK6EbRwelnPEhdkjkDtBwm9DIK7\r\nqzkCzErcAAyYEdHoYA0nLT3NY7niKBpluQo9o5fIEn2fOWAQBUpR4pO+wquE\r\nLjgpa15doevGLGKqulg3hhWmOs3marjPxQks8XiJYQE+P3sYOSRD37oAOTn8\r\n2am2lMudfUBQbMUy74Wz3mgJwNuCVNlx1ABYlqC9mByfC26VI0tLfLw3U1vA\r\nIaqEQX0EyEwHTCEOI/MO53HQYp8UMhEtf1hhqYXDywY+xvtXQk8Z2fL3iKQE\r\n9W//4kBn99/pHl+ztEgcsA+BESUdkygTnOz7lYW3CpQjlvOLXcItL/0/Tk4+\r\nJ8267zgtnOVJghpP41aF9P87f/nvYnnFhWjOWCj2cqIeDVI8RVt4GlssC560\r\n6Kf9XmHuI97JB5qSKxg3RzXJvsEKAzyluew=\r\n=CS6V\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGfcMPQyOymdV8qtxwqFZ/99GnP1jZttlsDKurH7y/4kAiEAhXSu+TQh//XLoKz9Icow70uLjogQX/L8pXcMjDEFfCs="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2203231914.0_1648110179292_0.8429551176721051"},"_hasShrinkwrap":false},"1.2203101844.0":{"name":"@bentoproject/date-countdown","version":"1.2203101844.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2203101844.0"},"gitHead":"9bf7cbdf0dbb4de2bc6b81fe042e52c990576b61","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2203101844.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-/Q5HncKJAbdiQcFIxNsOa5ZDr3rfL6DMQAwivvh3CUVq1M1mzpKr+f0EEF60ZdWzNg2kYzE1NDqF/k+7bEnrgw==","shasum":"0e0503b866c4410124697bd988d68255ac1058d3","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2203101844.0.tgz","fileCount":28,"unpackedSize":566074,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiPM/nACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrYqw//S/AD64j4NhDLrWzOxrPnojHiI7gvQJzUddbZstS6w/AwXJJn\r\ncHDYDAYWL26S/55MU6d2WDR706M9j++9IHBJFdRoFxCqzZmdK+0L3qjRSmHW\r\nsB74gbGQaGblvyKiCzXPrgbTGp8ykjCYDGupbEle8lW+DEUfCHrqfmA0gn5u\r\nhUyYeM7j/zrhhD9qV2lhwgKD6Pb0OsdAWpSCKoI0lAhzJPLyMLYWR+JiwLCr\r\niA9Ez4OhfCb6rj7yURGv1nfEApyPqG2eqrShhMPg4zIIWAFaVVQTf4JfC5jw\r\nqLbYXKWed0ZMMINZcsV4hBrTvxLxKGjpx+++cxI6I4bF8N7NjW3bPUEpwhl7\r\nt5ZDOq8XseRMpwIiWGBd4Vhjqq/LOP8ArwQHZFSPhTBuhyuIDMYO+1B59JG/\r\n7LWicFwOfEJQtKQtVePUm06oRp6n806TaS4GuF4Ob0B0fRVLkp+L2MpUkLAU\r\nYoPYibQYnN7mYuH39XNM8gavQSftmY4Mt2dEjPWY5ig2Tdtp9lO1un1c++iJ\r\nR3y1xXVeuE13tEc0wrj+whCXT6a42W1lAAi+yHNJ2jPv/juNwb75qpCCYyag\r\nA3BI0Pb4fwqWKQlxi6RgRhkZRPIq5FaE5MZj0qvWjea15brucTeqMKv0HND7\r\nGfUVWhD69lwrSbx1i6K5msWaBBDL8gf09ts=\r\n=/QCX\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHO4A6wN389rSGMKplGbB8tS0eZVsdsxPI5Svi20gKqqAiAgWR7qQsp9aRUvb5jd0Ghv+RFebLVzu3zMzq/vP/tfIw=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2203101844.0_1648152551078_0.282290540950094"},"_hasShrinkwrap":false},"1.2203281422.0":{"name":"@bentoproject/date-countdown","version":"1.2203281422.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2203281422.0"},"gitHead":"f74833d1e2b0d9176900cb183c4edacc4ae53986","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2203281422.0","_nodeVersion":"16.14.0","_npmVersion":"8.3.1","dist":{"integrity":"sha512-Q+I9ALHK/6gPQ7Gh5RBQfQuNzK6yfl6d3qNEVKYOpm5JP3bLlWhtIQnCbzzLCo8W0pwuhJ2IIXAVuqJc4wrrGA==","shasum":"2833fd52c17834cacedf81ea2bb5d55138d42519","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2203281422.0.tgz","fileCount":28,"unpackedSize":566074,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiQsMHACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrzFRAAnWSvBy7ticrdhFbHQo2J9YwOoKut3sMTyvsls0JVZzyw15sQ\r\ntiu1TkqSDoiZZgQCZpraNj8W5lBawETImaMVAot2JK/6y9nzKvfHx7c4zluw\r\nC09lqijuB5L3Bvs2Hs29K7y3gVuQiVRh6/1oCN24c89F15KL1bPOwPhgjQUu\r\nZsh61vMNr/Obz3jnRpujyDxdobQ4sazdlX6hii+CHVykP7eW8eOgEv9gkBOX\r\nZOBAfZIvvIZh5f7YHkOt3/P+TbWot+cj99VD/dGRIO70V9SeRohyjjv4Prke\r\niroRFdupMhR+Yp0dVl+mbNE/YqZpkwHqp8WLvYHIwoHhpk3C70mrjjeEizDB\r\nHlTYVCxnX5nwngcwWTDXShM2eft78Ka/D9lCcQVfUnsqrocxT9UIPUifLmwE\r\n14wMIRjHFzQcgn+Nj+35WM5h5c21BC/dCyCv7x47QBNrpIgqbEupqoq+MGB3\r\nNWgNSRsMEzBWUv5gzPqFeH+/lYKyTNDAgeGPk+Io1x/0P73DtPImm7ybhbYe\r\nibGOq35ZYei1ob52A8qkpW9M1u/DEwmTe/aHgZdx7ZW4eVIHhAk/UMRnzJlZ\r\necRb2+GUbstbHhKNcMuK/hEmMMJhqreejaWuCkh+ko7nxzCSon5Cvm5R4yOM\r\nqz5wjzVgz6kUx7NEvkhJZFLobY6IJxZv/1E=\r\n=xtc9\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHQkDmouMI621c+ufgvyWwYT/HN7Zwnu2L6PuCwWLBH+AiEA+2IXkXLvf2y8SQJP5AG/hoiUvRZ3Xf0xQYRo4DjIQxE="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2203281422.0_1648542471685_0.4852680056961358"},"_hasShrinkwrap":false},"1.2204121632.0":{"name":"@bentoproject/date-countdown","version":"1.2204121632.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204121632.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"dce11ee1542a2d10e47b8e9875dae137f4cc1b0a","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204121632.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-3+0nWqxE79GCxgLkzBSU1FePlZ5oXSwqsMG7zK/b4YCcC8V6X8mE2s9ce9M72XOJHb+/1/fjEOVJYssFfLhRqw==","shasum":"620b79e87ca1e4831c2c168435d2d89791c63fa2","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204121632.0.tgz","fileCount":28,"unpackedSize":456467,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCg/dnnjgESHB85oFZLNoNAUwvV1rT5yyCKyhhO6itoVgIhALqIhXjPzUZVGHlyTwxDZFqP/Qvk8dXYLuOPDxB2ks0O"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiVcGuACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpRxg/9EMlYQKv5sazi4h0T/ggqqu7aLQ9ZdFUsOjLB3/GKzJrPkZZk\r\ni/6dgUesPraoWL/ZNbj/DME6kUq+0yxlTVpBBcczGYpd24XVcOp9VzLDdJz7\r\nGNcpeOjDcM5KxfzH9trbeyt5n4JLk7quO10aXmT7JveFF22naLLofj64YuE8\r\nPro9+cJidpK2VxLtb+zQ8ugISHthliMvU36U5YGaQrHAlCwozJiIIj96EZT4\r\nqt5MKXK2VEDhGDJuX+gESGp8Vh4q4HkuK/kB6eiYIHdlf0xOwsZ3gndwiTBy\r\nvAP5g7KSMZ39Fw/Zd6z+k3NB5CuOx6Z79OtkR8CyRD+BFWhDffmGeLphwO6o\r\n/FvxZDOMdLvJzy8xjXi2xc+6cYHfKael6ZiK6fsTcrRX76/szBYIAAeWAXCA\r\nadx18pSS9DtaNucy7Ha1pfKBHH0QXmjOiHzqtoY2WquFLWOK94cXK3hS/NPI\r\nucpSkA9zHDuMzD7fIWQvYTciSF1X2uP49jwRPldhK3LVD1+IKIG6hekKZPoJ\r\nTEbgMbNpUsU6l5NXSkGmqx32OEdhhDQ7DMvz+Ols+p5OBsLrYkZdx9pq4wEn\r\nKJhAIUZEHT2V88/GWPoYdoXu+lhea1C94O9ipRIHvtTk+KaL9qfIreRNqYTt\r\n2WVIra4e7bcjOUZtd/1wkpXpqyTi/4ZxYac=\r\n=du0w\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204121632.0_1649787309990_0.8848246281893704"},"_hasShrinkwrap":false},"1.2204122000.0":{"name":"@bentoproject/date-countdown","version":"1.2204122000.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204122000.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"9d10200b5a9784c35ca9fa16b1a4b3078aab3180","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204122000.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-TDluAJHLs9JXlkCwL6bHSxd5vB8ivoTEqOt2mXPZwnLEhBzddlnrhPsCIFhGgKUUuw5Mawc+8OfT3y0ZLbeOXQ==","shasum":"60a6524fa29186fe7b652fc9b7f08e47a497a90a","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204122000.0.tgz","fileCount":28,"unpackedSize":456275,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHXwGl0tkPqhnh3w7uwUBBvhTQtnjatHjc0PbOz9M2VdAiBIPhyJ2W/7gdXTpWEwk3AsjPWw8o2o44Ys5YcrOObjUQ=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiVoomACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmpf9RAAkloegOiG49FwY/B1NViylu/xoiW5w9vD/F3pa4+QjuS6Xr+u\r\nNjIYBuxV4P9eEOvUEreAm7uqLz2uDYie6ZPTrdjEEPzc7uSpoao/GbLPD57z\r\nLOxCDEmt8877Ln48ZXj6syofrDUQy1zJD8E4AHNV7uxFgBFsAKCsOgqZkQCf\r\ne5VLqQ+zsK8bAS9L6etCV9x5CNE2uxbNlvTW9fYrq2IaNlM9WV9EMwYX4rEH\r\nUWfT9MdT1nP07VlbE2eFOeGvIS9fcvC7i6saybSPdx0Q9NZ316qyawPOCtNa\r\nGPWognUfvIthpSyxDoyV/EXzLQ8TUGKf05a5t5z93nnEqKr35zkkZUtj2hoF\r\n8WhiloIArGEY1N6TwGn9N11o3HCgH4Z+21IX4UPeDL48+4kHHw66jNvKDDaK\r\n+6hMlFdxcC9sWUpjbWI8pXWlUGkEi6JDkerhFxDOzkNz/CqMIYgrjt3ZHDde\r\n5Ir5wK/ZVpDsiUEKYK8ig+nx+g4MK3W9xPg4sLxvlMAJVbc6lxBv9vZQ9V8p\r\nqGro12hKD46so1gtBPdU/A0Czc4cUAK9JIJfVSkHAoMh/jpAAyvYvX5kUs0E\r\nGv6k5P7kiw2K1zo3tcL9bklvcA+XEgsQiVIerpy4ErtjFCdJJgfLg4Afv89k\r\nxRkxDLM18T+Uo62i4cH0eoLlCZ6eG7mhokg=\r\n=1YGb\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204122000.0_1649838630239_0.5380568227628661"},"_hasShrinkwrap":false},"1.2204132005.0":{"name":"@bentoproject/date-countdown","version":"1.2204132005.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204132005.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"26ab90e1d3f7c29ac76e3fe33cdbeec9e828eff1","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204132005.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-2kmUDLsQy0dvl/uCKxg2BgLqT2aHengnQ1qQ4DTtq7zWkUg8aHRT5txSorb+zfgBpbOPgIOeBquQ6LVNTW/iIQ==","shasum":"71c8c54514adfad287b0d929ed798ae25ae37f55","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204132005.0.tgz","fileCount":28,"unpackedSize":456275,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCCcURpYJiIwvugQyRuDE+zf1RLCvV+y/xne8BxNjKmmgIhAIgMcfJwKef8jPAk0FIaglvijVnK2D4wdAEcowfu3vPf"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiV9wFACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmo9SQ/+NFZFVXp1C/KrSitDjTdzBHVWTqOJzY6CgTTezHNSM99qkYFW\r\ndoG+Gqsntxa8SusarVbkEMwI2qZU1v1oOyEbb8YWQ4SiwSX0mj/s4ybi28WW\r\nxU+A/51m6s9z2jiXb/dzO+8InAViolkotdgZUI2ueQ2GbS54AlbYaUHxpA3c\r\nsYw22DECvbxV4yCN5ibhI1DwPvstuwisvyqOXM7AovQXuO3HgirSRFFWMkeD\r\nJQ8bNewJwFm52fE/kQuyScvlMIOf7iDxSf8gjmytV3qOnk0QQ1pm27iOEEYx\r\np0raStAsblGzKuvKwUZLLD+Als+6J3P5gJRjLW81MP8OjAd/5DW9jHOn/j7m\r\nMv2VDFC+lctzWALRBft4vpYRI5i3kr3ShzdMqVFEGO2qw5SX+Io/0QQuz3GY\r\nwToEc6VqHmz50zUyU+SoH4lTfQnV9Pp9Lb9SqaCM8bokbjSTSTn4uGZwfidY\r\nwEM6kETYevKWNxSN7herGbvdRatVuI9TwUIVy4KQM9lEa1GL4LjhS095ih8H\r\nZtsyH/pcZqwQRGThjCl25rAIVhTj+WIXZaJA+nZSY6VgLxNFk35lz5pZtcjs\r\n2PqueHxyJXI7C56IokF7c8GwceTPjjS8uzEJKYvSm6oQxU/EnMMo2gzxfoO4\r\n+EL4qxBRc0iU969fFi/ScXHut1J+kzP0w3k=\r\n=A/3T\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204132005.0_1649925125570_0.1452664856893202"},"_hasShrinkwrap":false},"1.2204142048.0":{"name":"@bentoproject/date-countdown","version":"1.2204142048.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204142048.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"32d29a09afd66bca55e024a4f21b1cdf6690cfdb","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204142048.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-djh3hzkqjRgC7FhUACQt857/obmZ6kTIFEM3Am/crZajI23TPiYd802/cNMlImw9ZWqr+6XSINBLEcc4V9Afpg==","shasum":"8efd845fe902acbe19c522d0187286fb742e6c1e","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204142048.0.tgz","fileCount":28,"unpackedSize":456275,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCYKRT5Gq1yj/lKScxwnUAkK16yuE/FzbzC/z2cIw4mJQIhAK6VYe9I8IP4dLCjjzXNA8pcYzqltYRqSRUetD0vlcF0"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiWSwnACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmokDg//VRt4w/8W3Uyf5PxS0rG41ppCGuSKQPq3arrDhOLRigOTL4BR\r\no7daHxFcGCDoHfD5JDX+gl9444ZSkNlonFASDdCKZTsJb1oZrN28SofYc0+m\r\n4pFGH8VuAJmYsgYrqG3VsWjug1Jf3LeCdUYmPl2Ip6PbXc1ha+Q2IgGnZESY\r\nPxKthlzjsR1I5NMuKJtqzCS+aP7hGhRTvzcyFsRym6T+j44Y206WpagMf+2d\r\nTz3kzOEsGCxZmBDXWSSm1keS5D5cX47aYPS8eDFhqbvp6prfg960/Ry+qpq8\r\nCulO3OsiIPXVtbHTqtJL76jDf4dPT1I75Owvol7vHixUuCq3oqduZy8SouRB\r\nSx6Gu2EL5aS+4W/MdGh4ljLbYFNJByJ3i8EzuWE0u2BvKCMIKUeMIpEzckIB\r\niGrdSVXhhppKdK85OQaIqScF4KdkYEIrVi/UI1R89sYrvEPIuKvyrVmekgOG\r\nhF7Tsmct/rS5kfE8W+h7kSA90UdivAe1XTcaEeBBJlZ9s3y2oSB72v376/I1\r\nAO4Smrh/vRaf+BfmQ7fdtRmT3XPqfNcOJgcXf/USqisYEXITTSuu2u0yC+oR\r\nPUWKmuJJPORTAFS94rf2T2Thuf+LdDtJhs4mrmEOC/pIbWcxmdZxBTUN+AnR\r\nP0YPWagykEwvphXvoJnu7wTbw5TvbToqmmE=\r\n=mnT7\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204142048.0_1650011175276_0.10265654837420324"},"_hasShrinkwrap":false},"1.2204160405.0":{"name":"@bentoproject/date-countdown","version":"1.2204160405.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204160405.0"},"gitHead":"a26d51722a65f29aa7f77872b7906f6e7ed62e9a","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204160405.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-CP7jvcpjCDYNsQAGIioKnWqZb3XF8QYIU6GJRFJzQa63XcAhhWFhdil3q5EjDUfHYvCI8HbJMGB4AETi+5dbcQ==","shasum":"25d25f4caa0a9d4191ae55ce010c403e6b2b657e","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204160405.0.tgz","fileCount":28,"unpackedSize":456275,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIA51wU7GYZ5CoE5KiJU2ws4dp98L0rFLMfh+6d5ZQVmkAiEA9ALEpFzurZvEKQyzUrTo0YBKkOZP4jzFlavbuT2zFe0="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiWn0XACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq3fQ//bRWIxvv+geC1YJWPsZ0XqYAGuptu2IRu7Vc55IqyJoWuUGqe\r\nnGl8tabnnV/gWs2ETOVwfFI9jf5suj8tP/sCe7Vp4ZntFVQqjwtddRtyZG+X\r\nnqPexXITRogNSoz0JWG8gPuUde4+TXik6DWS3lZ/GwHRj+3Hps1r8ZOVQQTE\r\nsZb7cYTzTjoeYd9xbGjDVp6a2OmhkRwZfNa+79/U/wxO2RIZnIKFQmmjmOCy\r\n34AdaJT4kq5NZLON5EUmIyFG6lWWgCOeji7DzaeCZlkR11qK7pj3kN5hI4pt\r\n27tQnQCfB3x15YqlVof6ilWEXQJ1IiJt23cPu6JwPwefGL3Stqp340ide4wY\r\nTQrtkLZYpL4VV7CA5HpkKW0DzI+yJmnVnYg221TM3kB97yzR2hZeeqKU73Oz\r\nyuCy0kBMbFQZvUef8kQnfTNwDkw4kV8GPV2ynkdg3DLSIFV2dWeyxERLrzfY\r\nvVI3zw9OXuZRB2hhV8WFaX/XpUkstgRp4Jj2PGZ8aZza+oSVd6N5g7m9sB56\r\nYWeuZorEN3n8Zl6QSAKQ5utwlW11iWIzv7YhKWL/NTdmDDIDfnN4DX/cSxfk\r\nfN1O9t+N8g5m468KgR9z3QX4o7NxiRZuhjCybvGv/kKmSgeIbGQZzP3X216v\r\nE6ZhOduT6VlpwpJvU5Cp1aIXBmJzyokIm7s=\r\n=hG47\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204160405.0_1650097431397_0.5784239136882263"},"_hasShrinkwrap":false},"1.2204182206.0":{"name":"@bentoproject/date-countdown","version":"1.2204182206.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204182206.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"83e7c80d7406923369ada8c1a7a5dc660ebdcad6","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204182206.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-rbCZZQ6+2zbHMKUCtehfzxOV0h8i/FMuBbmw5a5Axe6d0YdK0nTommRBNw9VKmdxXnkE361cFmOqlNfpKazqVA==","shasum":"6066aeaf5d2dfc922d61b3842f27e1471c1d0271","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204182206.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFzyp08LIY+SY4RtVac1wU1uR7zR5U3Q4l/v02GvfZINAiBbIbuKztqSSG5rbubMQfvDdmQe1mEXmBaWuRtIOPKoiA=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiXnLkACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrZFg//UG8eplVDIP8j8WoZjaafPxkvYnBITXwYECUoy0LUdvpfxYvL\r\nYYIOs+0R17j3+bN9T7bIuAIc8KukWl6TbanB66ccJSuT5r7kBA6l/R6VqHeK\r\nQVfRTONFdZ1cUy/ppYEPBDom8DstClBhPUqUyrBOG83Xu07/bpxMD9onfwRM\r\npMNgTLBZKc+vXaZcls9aJwGe3TLXxlZoImLJdHgBZ/kEhvwF7+QJgXI/tGqZ\r\nquUHqtPV1DIXMWemuxEu6bz/qbTT1TUyMnuR+h60Sz7l4mTb7os+0oN/8iM6\r\nUKVu0rGtfKEony89/DD0ZovsOovb67mwGPEXiopk4Y2zG4u/gWqMEiKxarO5\r\nT/G0QF+Oxsy+mYhv0tM2EJ6JIO7t/lyL1ZqLBK2E4Ke0Y2TLZ74bPp7eqF4t\r\nNRySPyn0AW/FY99aBcHTRklm8F/sHMphPJqHiUvandbFfZefC2PCK0caG5aL\r\nbo6RsUMZMjGaUtJo+1sq+wGPhIlPsmhLaWtqt06MlEpBFyw6oTRR9Bb8GY63\r\nUgsLgCPEFXzNGe2k5Lc/vAuVsS4PBRrz6Tf4uwAH+xUODnrqI4t3c1YRRXx4\r\ndpnHGrYqWtbJZmM8tlbv63x/HdJ9kWw7B4ZYlHGqkFNd0XsRkgmFSiKEVSQH\r\nH6s2Ko2+6IzAnTj+l99zobx1tYwpkDCSt+c=\r\n=lT+Y\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204182206.0_1650356963988_0.489732785262748"},"_hasShrinkwrap":false},"1.2204191429.0":{"name":"@bentoproject/date-countdown","version":"1.2204191429.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204191429.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"2ef2d96efb4624b0ef0313b60134c9e35a4e8429","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204191429.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-99Vz2JFCliT1C+TEUyT93iMrC3qTmod0I/q5xic0g0+CVfeijnA7bybZcV3yaTCjWeQbAcinnTl1Arpi9NwuKQ==","shasum":"7ff0c54681306c22d563e3e70f53e0a4bf0e8400","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204191429.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDBBrhvvvd6U7XGKK0x1QZxk3Kl1NF+HZ0H3cikIz2G+gIgUAwGu2HSU4J1/TW2RSCitRcT41pVU50d4+eT0hFmRHc="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiX8S2ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrNUg/9F63jf0ZFMY+iP9VJWdUPnd5Y9x6fZZZmjATQDmOaumLyVTiK\r\nm2Bf9D2CJRf3SVH0xepC6NWPkhJHuau7TcBCJ2vQkDfxoAoYbor0vMpl1SqY\r\nX6W4AusgmT9c8vMVWx5l4JuwpocGQMddLjWllurRPjYtV+kBjZ8wQGzHaUbg\r\nP2zArODt33gnz801lDSV1jGKpr5usePLLvEet6qUUm03KKCl3htALRs/Bb9p\r\nZeK6O8061mnKWovqVz3wfzFuL644DG57icXVmykUksH3wJ7C0/Qwdxkmx7zE\r\nWQfOrw2XNqnO1tJI6K/3lDGt5KKvXKVBAUaywJ3g1gHCNw5E8ts0r60kQJHe\r\nklMCrPn2pSYk9JswnwYZLvEC5ndP4lZtMCv2CTnb6U/S+RY9Y+JXOoQ8/gbT\r\nKzxIGIWAzvDvmgFfyO3yhLGH0YaxUOTpO18qChiNmk9hST0GLxq6R3WveWih\r\ndIIQHaIUPWO1YNBejBDHK8uPgmfYj3orbuGGEYGAR4R/9nurCUJz7SFAgw2I\r\n+oKaUvjTYEFM736uDeKtlB+7iVTMPRpliod96cd5PeVs+InDaCcve37lAKOU\r\nKTpzeidH9HRGOUoeRVhUDCwPHebrIlLj8SXaYJQ3lzz4P7H5pU99cENPFCcG\r\nbcBpCNyQKnbrG/XKlYA8eulAFAseC4AqSKc=\r\n=4JUi\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204191429.0_1650443446487_0.42243321128538835"},"_hasShrinkwrap":false},"1.2204211736.0":{"name":"@bentoproject/date-countdown","version":"1.2204211736.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204211736.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"01dad70364e4b2b9707441c2c8ec973e1547b195","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204211736.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-VjbhuJx+U6O8B5k9QF9kI8gMSm12THNQvuqUGgS7D4bbvXVw5C0iUGhnMDPkAa4GWIZXybbI1fEMZhrHv+sDDA==","shasum":"cca6addca75aa7b73b6d9b61b529c2c34109aed9","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204211736.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDCcPbNT60wlDvw5myHsWyN7IMmzdoRC+HcD9Oqong4iAIgD99NTDEUUhm0aG/o9iIQ9RkrJ4v+XGmRN0NPVU3G57U="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiYmaRACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmonSg//cYMZkrXCnMfSvpyIfyG01y2Ypyjk39P3opLaCspgOsvmqMaC\r\nIpHO3jLoxdMrUOhkTvcIIFgtBMiFzA/r/9WHaFUw3SxwUyhLR6x5EHFhOuIM\r\nBkIZrfglF6aJ2M+4QS1q5XBUseUI82nkT39oqCIqSvY3dR9UHStVXKOYTnwz\r\nEJXcLyBlZzD+Lq/UITjItCIDLwP4YqivEbSp4dxk0YFLP5Zefw848FtxvRvV\r\nlE3GpybBO7ogEPThWTT3fJI2NyrAcJouuf1Eabb6Ce4DeFgea7ff7gmp3ioB\r\nvCS7PZSYMGRXnRUFLxkdy0KmFJCYVV7L7USbbzehycaeBIR7IhNHbRBUoy7g\r\nMqlTHtZJ4gP/DWL0UB3nWVKaQt+hruR3CGN5zOq/lR6oIfcoZstPBvgo6K96\r\niM93xyKU3vXvPandIQfQHVGdM3HbCwhtGo+tfwUsQPRqixC6hyhcxiRblU70\r\nYkH34yNv0HHriwlMfYjw8q0oKUu4CqKvgaUMbOscwX+wg60fDtbVUR2745n8\r\n32Gk32Qer3aGdZzdhArkYL6jckUP4NOkAN2G6j79kbn8/CCmu1pGZfD+NEju\r\nP39sBPQbIO4B8XQAEYHKjhtVtHEnxe4x7LtD5lXjFHMTUNY41Acccp1pDT3A\r\nuea8GsrMFs7/qRrA57Zs9VVNuUZYLzYbmos=\r\n=e9Hq\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204211736.0_1650615952944_0.6562925929524086"},"_hasShrinkwrap":false},"1.2204221712.0":{"name":"@bentoproject/date-countdown","version":"1.2204221712.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204221712.0"},"gitHead":"fd84f283465064f90218f67c2964f8c0ecc248fe","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204221712.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-dzzhY7Cu2//6qKYCM60uhAz5drvoWy9Ifa/WQprSlNwoP6JgYpz3b31vwRqBkTFcAIV5qKBo6EosARx64/4kWA==","shasum":"6daf751453061338fb989f74abbbd3b35f73417a","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204221712.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCWZlceROmC+pLIFkANmTWILIthUZxl5svAtOZ3uMx9FAIhAN8wZAf5ecChkm7ptzgV5pq1IaWfqwaPbow+QtUQrcc/"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiY7emACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoBeA//Rj5wbto4UHULNL7Iu/hJTZ5xnMzkI3+cgf+GRrp2tbZ7RTwV\r\nJv1pNO74m4dHr0hcf7qH9blYeIwJ26/DMPLhFTqtRALvcqwtxwiCYVkSX4F3\r\nSmXUS/3HowU/lSjTLYaP0MRuE6XfqS75zh8rAJScrD2g4VzghEdB67pWfACy\r\nu5ELBOz6gvnBI2+/gT9/515d0aoPxFT1kjp8ihvA32U5os85ySgKzYfWAnIu\r\nb9eXM+75Bz0xnWVeolM5MJt3ER0WYFJwhDUv1ItnJ6V5VfeKQBSfV0u6mUON\r\n9Us73Nc0ZGEsUaAuqTRg7IuLkXRnFap+ig865wiwVTfXybr1K6Ylo3qqNKG0\r\n+xjx5dHV+aVTrfc8OkTOxA8jqfRn1QntY946m+YKPYKxWV6bbj8ojkCke3OF\r\nsDTSLuwVwAYyrrjOCRSVH57w+8UbR2ReXSGgLm01t9FoqBVJoOKBqVv44ZzB\r\nUDmkvrrTes8kn0wJvDh2uadBSfvam1D1lVTNTDDa9uLJw/qYCO7ohXIY3rFV\r\ndueSN+mFqmGY/FCeH7NmrW4fYWm1H6q1A5CFjKy9fO7vbdDTsiVipWdMj1F1\r\nDNK6A+u2Om78c41KwucaO5WsWFM6s3RHEbN+RLOpzAkwLXUdhH4/p8fX2yhX\r\nCVJsTQXWGTSziwcJ9Wl9IxPbjiooZa9odfc=\r\n=lQtt\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204221712.0_1650702246099_0.320399411744013"},"_hasShrinkwrap":false},"1.2204252045.0":{"name":"@bentoproject/date-countdown","version":"1.2204252045.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204252045.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"9dcb73514b52c635b732b72b56561ac680ea344e","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204252045.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-o7QLzzKOwUnpoXKubwzVwLlsc+Y4RzphepIZVhsz3KRg9TIU6/zjt7NkfW117dCcbgFO9K8hqWEBZNVCSp6V5g==","shasum":"d3e50358b96d016796c47f50e1140d0033c579f1","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204252045.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC/btQnAZ/CEPWfxuMqvny4DwTpMrhPrg0FxHMJncG8OAIgJjPuLEhciA4c8/SH/5bDX35l1nbZmTA8rmKu8RSMFco="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiZ620ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpQHw/+KXNJUek4vt5q70aqxT/GpNiHWwZr5TZCpdt9AHdvgGJr0goM\r\nzsofN45U494QkW6JBbr/8CzEkIi5o+H4wh3OEdJ2LqN1mYeUWiRPHnjcqVro\r\nrnF2sLQqoDlNyH16V5NKrtd84Z3Vuwtx5x0/fsdnN2HlsG5mTo3uhfxOXwuV\r\n1nvSa61jXVODTUn+cXJJvanxsmZYcF1kKxChMfo1HT9zZg5elmp1pdCv/3Oh\r\n7M0JPG4wkgzVs58hRvcLJ+U5W79KXRo9kqsncNIs41yvQZ0vX2dakDqiRduw\r\nert9KPNAVpLoFH+LfbOMPEwBIbWWjwF7yQKrrGptnlFUYnjpR5GJmwBWPFCb\r\nwB8KNYkxcTeIzhJn7J+clROkzFihKMLirGf0l8Jlm+mUQvrji6FqhWdRxoqp\r\nbynEHjm9t6cVH5gj3cf6gvhi3+xGFZUF/u0+i3AmTgfv4EkDCn3aTX2t/Ejg\r\nFTWCINLhE25pfUgwZUenbp1HkOjToYlv4VUjvXvC/Aw9cw7NMRjAk+XrezM3\r\nJfd8Gt2MbbTtCJopm974dx3+EflHvj9e3+B+FA+7B8wb2Djn8yBfbahF1jHS\r\nvevUOAP2IQxsGJxtLs6otJOOhwpDvOI4BWYE+Wp2JwMhx6mPfIvaJp01MG9Z\r\nhwNG5lWdbFUGKPhop6hu7Q/bLVua/wsJf74=\r\n=Dp/l\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204252045.0_1650961844110_0.17305201456356167"},"_hasShrinkwrap":false},"1.2204272205.0":{"name":"@bentoproject/date-countdown","version":"1.2204272205.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204272205.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"c2397d28837191a7d145806840ca6ca9a73823d4","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204272205.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-CAfq9B9PY8DEzwQUVw9/7mLCJyLpvS2IefpEtLVZp6nrWjhnm8bKeEXpdNNqfcYAp4BlRjtlgeMUA8B0PRgbBg==","shasum":"a8a8eec03e807a86a4001863a639bdce604b4091","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204272205.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICmKUr+YVZTm+0SPMVtrvM5+FOShWkq5jEh0OUzyc3hGAiEAr3FlFIXNMOVkdFPUY7h0qfSblQHR+foFXGaP91Fqttk="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJialCrACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrY3hAAozOyeuDj3anx4pgP9uVZghWu0Zd5+nsihtB4d4zr9N6wc+W9\r\n/lWhae2gm8otRyuEWsMNg+YriNs9P7XDc/2msrIymciO8R2CD6mP64DZszuT\r\nZ9oeBlIcmP841xam1NrbUzm1Mn299+aeyJXxl2MB9tuEQBnAfApXnl340n0m\r\nnCwrL04MKinfGg7mDFomAd5rn9Nlcio4tychPUhasA9j4d7WR6zFyLHjxgoN\r\nIWSfDuAacD6K+S3PozGIj/bBDlPn6n7FrvNCe9TBlWDWevp6hrwLV5JMARFI\r\nSYp2NqSxrsJtQvuNUVrBPEpy9kQPE0DFu05hI8tfl+4hsNV3uRYN6onjjY95\r\nYO9FvgnSdVSLDjgMZLaYpZkWuaY5R1YjIyhuRDdC3bWAm8dV2K39TEqDQMeQ\r\nIo6SIHPMIhtJ5Xlv0iSd3Leg6lbDT06MD5fFvrtwZ8im83Wr+N3s6dMIebOa\r\nT8DEj8Zhxgvm+EPgPuH8oIDC4wjpOOBsb2cCQl82LDffxGbM7P7Wr7Mf1+P5\r\nyG/M974h/8rLDOlDfVBfuc/NDsq+oBRGCFjqfJaUP8HABjwnahAADXg0iSQe\r\n4jAG/xx2X/2XfOdkvblaWAUKWrgyluvU4O9QbCr9EiuWKkhZBYkj8g71cqD2\r\nEgcImaibKkYSyFZVqPlSAsYftDdwzt7jhBo=\r\n=tWZE\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204272205.0_1651134635344_0.03498430518130169"},"_hasShrinkwrap":false},"1.2204281949.0":{"name":"@bentoproject/date-countdown","version":"1.2204281949.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204281949.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"8bd4749759e81fea16cc216637d7a185eea3402e","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204281949.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-FT2796e1/rM3eTk+RUW8V4UdnUAW3py/auV1NWUMp5lxjlFI+IdaLzeHfJKUcDtoww2CR7aYBSDkm+CCzoITLw==","shasum":"09cf36b126099ec9618d1f09e8133a1e67a49835","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204281949.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD9nze2NX9WzxTiDdsPOpznoXoYt6OfEq4saBfig7MT6AIhAIr4K5XgXwYPKDmuY1QvLDXhXT3/lbom6eFA9Zp1FeXr"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJia6FCACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoYDA//QFwVE88w5vOWuv4eZAsX10hK5nDeriG8FzK3vtH9X8yri8OA\r\nHtAqFW+69E+jreNK5C8js+iXE+Sa6x7MgD5mmgGUe/XaBbm9fpBNhy6pV71F\r\naATj9l84Jhp/Qoa8J+WxuwvjONOksCAkafErH6z0N4jc8I2lyYs1ZqNI+owt\r\n69xhxmUSI8sCIptA7zsd++e/lQDooE6wg1C71k7wiCNstDLvaCbH/ZBhstjd\r\n/z43fPGH6mDdEQWpsjo4EG4KI81t2JPU3Dz/ggt/IPNHqHiIquafCMh5yL3B\r\nw7fySJhBQNxmT13zPOPJVjRJUqyCgVvc10kjAhb6Z9GeUNzyyggIoG33rM1U\r\nBbXHo4fG92jYAnipjiB3afS1qOlt74R4tyyWpv/xhbRoOn5ia+F9OK7ebHvV\r\nkVLDnfzT33Msf3temc+VfetUtW5NuRILw1VoNO+OdVjwzqipXk06Q/h5I+X8\r\nuWCDVmuGU3y1cycI0gF0QmaEHlmZDXT4KBTWEodKltTolQKIofF1MkJ7fZWv\r\n6TOx8sErFKicGrA5uuqYQ8si1FIizjRz53S8qr7HA3xd/Fk6cWiO11q8sDp4\r\nOPBK/6kVTj5Kh+PZa72xPVe7NVa7GeQy2n/hNR309b0RIlvT27lO6D+4AaUj\r\nRLFXChqE1/XLZWbVe96IrbiBjeeW+7nbZlc=\r\n=ePzG\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204281949.0_1651220802642_0.4250362579896876"},"_hasShrinkwrap":false},"1.2204292129.0":{"name":"@bentoproject/date-countdown","version":"1.2204292129.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2204292129.0"},"gitHead":"266c274e2aa669399dede55e9fc55b8917069279","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2204292129.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-NUCj50i6aGiNaImAiaD6xokX4QwzJR0fs1aCJzA6eTXkNMVcc/dPygiEeyjMMNPTXRg4zPRhOPxkXIG7G4LCWw==","shasum":"bf214ae72a17997c69a4cf0f48185a49bb811dbd","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2204292129.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHSgVS6aZFy52pO4Ln2jXZOnVKL7CZrGFMT+AWjpiSAGAiEA41dnV1kyAL24GuNXehTS6+rmDWKgTjahF+QX5e1thYo="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJibPJIACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpGXw/7BUj9sHjrTdioUQHrx2L48U9bbPrRaY3nZ3cz+8nWhaFcFAML\r\nLLEa2MTaB4CFNDgA4Uzuk3JgiHZNtvnb29jGicvfJEwYwcDN306+D2ZBn3Kn\r\nWnqEohdr4ye1/vt2ISDsxMw2en+O/ugduYxSjSPMJLb4zTLapxklhavJJhRX\r\nBr39hj9d4TpicEwE7U0TcVEKQYx3kn6rdBz30aABsLkZWn/Dwz6rDj7o+020\r\n9obGYiNTk6LvfhbXdUwqknbt34Mk+b85fL5NNLpjpqQqaPgNwRuXSjqlKLEA\r\nFP/dVcAtcj60Yqbz8H+DIPjWOfY0AG3qt2a5+zb5bm7E9x5beOQMjy9wKkPl\r\nBrb+dZijSrc38juld3Q0FufzlR0sXX7DYtlrFwXXdlDiDiOTC8HOeMEyBnno\r\n0D6uwMfTa912+nACw8KSBdB4G+8+Igytn01KhPF5cEeB9qNdQOahprjoRuwb\r\nqeFXxE4G+WOl9/A3ibIlfpwmS2pBEWd/o/ArINJF5bDWwbWolX8hhZXSLttW\r\naAam1KMemeYB1I03o/bbyoHlhwNqCismsvYYJIBT2cwR9NEe1DRTiAsevaV4\r\nXFzW4ll8y4DwV1/Nh65LoekRM/48LBOedSr8ZDSriGtVzeEaPF6ShBxj9Dds\r\ne0QLQ3UTzIS6bzT43s/SuLTCWH5fYBbouOM=\r\n=hlKQ\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2204292129.0_1651307079976_0.7276660895587448"},"_hasShrinkwrap":false},"1.2205031420.0":{"name":"@bentoproject/date-countdown","version":"1.2205031420.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205031420.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"d3652194dae7f17865db127c7135ec194907b7fb","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205031420.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-MH/P4/TRfJpJVOQXaqbouVkwJceUAhOsVLjIagbLSFrlfXBNlZwYI9zLhyJaY3yF7SzkUr+8TsNgWtsf6zebFQ==","shasum":"cb7a39cd91762d73dc8307f2d225831c87655052","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205031420.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHvsmKUufkHXv6eOGlw+c1AaH+V6xbt4HuSTJDgybcwXAiEAyOgD+DCP4KeNY9jXWpgWYY27Se8A5lk+Qz//4eBa6QY="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJicjh7ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoDFQ/+NfWrX9vZCr1Shc0SQEoHG5bgKIfZf5aBGSIrdModMMZaxlFq\r\nSyAMxLkT/4x+TEewBPNiQdgqxf/uh2jfD6jh5JN9YK0TGrIf2s9uTyeWp37Y\r\ndNZkqnhjh8/XkRYSkqy3VbVOpJz+Qpijdy+JKciSKAU/1jM6fzrK9zoa9DBD\r\nm52RvUEztJEcts2cmvivw5gFpcPnkCBpoKNyXKLsOaz1yqyLi+awlsKTh2L+\r\nw3x+CK1OunI2l8W5e0XrYn1O/MFdcf8bfxvjW8k+LQp2kTKMfx6XFdJT4B/7\r\nkqFCuKkwmgu7oqUmZfWuyNKF4BMkY6CN0ft14brGqClaGmxoufvhb6NZ2uX7\r\nD3+n2HErNzzXpi66JPzTsfisf9JAE+nZLazFVk7uhnLOJBQHsF2ysTqSe+R4\r\nveHQnbg/o8Iks0/Cp6m6I8YjCmudy/UU9lN9bGc4nzevHeLii5w+JzWOOmcw\r\nW5iYp4ifHjj+cFCtXVn5oyWq1oVDp51nsag2GEBRUCS+7GYBDsJzW8/pB34H\r\nsbopjFjhphYuUkofIk0+nWNJqFLIvUyWXP1lA/GXcbqgT/pVq6JvmWDyQfbf\r\nrX2z7FCzDQyT0uhOZxFtRwrG3WyeEqUhrv7YewMc4EL8BgFzG9q1uG2GCYj/\r\nJUyd3eDzQRqbWWQJmAdv5PZa7612NI4YZ/g=\r\n=62R8\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205031420.0_1651652731064_0.9595068859677813"},"_hasShrinkwrap":false},"1.2205041533.0":{"name":"@bentoproject/date-countdown","version":"1.2205041533.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205041533.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"8c9c66c7b1ace99b28d77b82807f84e9e8cb305b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205041533.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-bpGLOgJSIdXQf/g69Z/t6Zpxdg3jLopr8gXxTYG+CvMB6mBDz3oo7kjnO1M4T8mIYAwAq2K1UtNdKU6I1X3HeQ==","shasum":"909d8b138fc6913cf69955cc86aa7bfd4e8e084f","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205041533.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCg81h3cTQNFec7PIWWeTcGh5dnD+m7DJffuvXSDDq9fQIgavhnCHon2I6IL+xVKtWC0d2i5KAzh7nDX5xalmQHLXg="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJic4n5ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqV4RAAksFj6UQjVtnhQ86GZx02fTiAWbhVVZPFL0Wyy0z7mn06G7vm\r\ndg5phdWvFstHAD8hj0aMwWP4G24nu8PyEaw1PmM5yQyJc2redAc7+mPpfNn7\r\nhr6uEHSFDPcBwZ+Hb8HWP/bgOJDKdKdZ1VI7kHWFbjGSsqlLefZNndbSorC3\r\n/oN2NLthLBRiybbkBk7Jek2zITc1A+IQvoYaMUDh+0DaWBUXsrQdSrQMSVJi\r\n8Al44uP39fMYJDmWDXUPXskISe/HubxSMPOtzp1bm/+2u6Fv0i3OS4Qt3drr\r\nTwlTM6cs1B++fr9UPSpn87X0WOmW6SgT1V0InA13CvzEz2rR8vNNm9Zwrjhe\r\nMXNhWJ5WCRGb3SEjky82kkST/Bvt8Z8npfqWefH6pxCDKVX6ocgd3XzLcEkg\r\nRJkED15ZzVnXad2ty7tIvRzMyXWL8kBWHyeTBsO6OhnEduUdPrco3DLHBBvB\r\nSJgjZYP5YSiUwbYasojMkpfYfG0ApbPY8OJ/DAJynCoY9CkVlIsWniRSFD+c\r\nc1/4Fasc1aPN4pqY2BM97SHLlrjrkjPnbLDdQzf2wogIwMFezEJ4Zo8ZvSme\r\nKdkiUqwuIE9xz3QZc8HEDLL5p3KHm88fRjhjRBo422bZQQbgnVBCoRk0MUnf\r\nwNEy9LHkkKoaMm1GUebcXXe1g75k1mUrXoE=\r\n=UyJv\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205041533.0_1651739128937_0.0034468200729185217"},"_hasShrinkwrap":false},"1.2205051832.0":{"name":"@bentoproject/date-countdown","version":"1.2205051832.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205051832.0"},"gitHead":"3658b8bf865c7e71c605f93088560c0657af9cb4","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205051832.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-xOyBmwY61NBwz23rd7bXRpiq9S1cctlgSxwYX1izQh3le3RvQptfugncGE1/cjNmaN0YdY5+Pf53ic7rnxEFcQ==","shasum":"e645eb8aa5c8e8957cd79a70d2af2ec0ee174c31","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205051832.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDuoWvrCjwSec/AZiFSem6sIjq0Lr3ZmF1gO229ZVUaiAiAabbtPlZH5tdaVukjR32Y7d7odx2gucZLrsUe85/vRqg=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJidNuWACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrBlg/+IDh07a+UVxYQ+7HBe3JKkbjbgM1IQcfw1dQtG8W46YHzkyQh\r\nxjN1WqHMmAlhSY8+95G9dggVh6JCNMUhM8+v2jV8GFSRwe7pmMl1zHdFEVnE\r\nQRnKwjY4W09YvLucZmKZmDUFK1+dqo/D1oyCEcnwskfyaLGAbuhZnKI/2+pF\r\nxjLzaJ8iCBQosFAzXVNbaOn/2sHHL8iWMB0WAwWRawLKNOzREhaXzgLxHC7h\r\n5t5ntmP3JR3VciFEOYfBlIr4LPv9fc7MRvWHTt58dr8Am/ZnenA+p1PqPFzB\r\nCmHMznc6EDR6hPkS4vy5EPPKMnRq61D9fPBFYH74kpRs3nSeExqVJu1vegSC\r\no6FZkJGjX+RW8Qm9fERFExmpU3xqzKyje1YOUDmCO8U0sqc0ZccgwSg+9yL5\r\no+ZmdlrZJ07cMiDQKcPQjerEfgRRdeLtZKyT7xBmhHSOVLSPiOikqhZk9BDk\r\nL9zOGo2RKp5K3NssmUsnowqeza7QccfpjHUGGkNQHZejZD4MidXmeTgIelZf\r\nP4WkH8IfwNBQY18/7D8xqLGyk/4YCTmyHcCxqef+6WfLeIqOEqUhW91zvbH7\r\nXwDWNpM3AyiHdZhzcT82QWQUbYIXxB0dNvVsZagJ6Fz1LlVomwrFE+cu3dUS\r\nFzw7MUFS1nk6RdK2+t9ZsiF3hZViqVFDaK8=\r\n=9FDV\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205051832.0_1651825558050_0.9026413115590752"},"_hasShrinkwrap":false},"1.2205090810.0":{"name":"@bentoproject/date-countdown","version":"1.2205090810.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205090810.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"3fe2ae4108e8ce4355c90640458d13cf81af160c","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205090810.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-WVq71YeUBZfuD7U4P+ayxa3CEHlDbC3C853f8zPYofXIwkb9zuUoKa81aa/y4m+6vcMuD0l5MGbW5hNETl5rwA==","shasum":"1e2dc47b3e473aab9270e2396bcb53ff9d5cf298","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205090810.0.tgz","fileCount":29,"unpackedSize":457243,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHKfgY3wTbWXj7KGto5MTx7j5eQgQPpfX45tuSY8LMDSAiEAkE+47SERbpx6vjqqVja8ynaPPtIvhjocSLkhQjysDAI="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJieiLOACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpOTQ//YAaUMPGQDrmtjrTpgg8KPV1+prsB6g525WQ1Jdm5y/pcE/+d\r\nAN4sDmzn0eOz8F7Ru3D0bOG03uqxsthCwz4OixBhKcv29JUHdjz7o0mvKfy6\r\nBKYtqwkroAKK6DR4XMe5zdC/QpQeGxsC8teQT2KPsePZjTZo6QwD6kyqHA97\r\n5VmnML2m0kjiBkhM2d91p6u9oJsVDqejCl3oepVPeXlHVL6Rzhj/Y1K6Mkng\r\ni17HtQLQI/oKmIhRPikNt0Ouf8makS4UwByLVims4/z9gQrj5VCGwUousjbq\r\neOWGba4E4Q8cLk02ezfKLZbuH0ra4nFeKSESpDrrHWiIMWj+WBeEf62xY+/P\r\nobi1rmmoctZZwkp8WmC1gZnLFXkXVcLHYWEmx5sE5uy4+7iZCLYx1YRJnK/R\r\naf4iBh80Gz/cO2/leGJr03tr4Bob9CeIrqHkOyzl4x7tGHCbDIf6HJpVLbuy\r\nUegNvaFHW0FZlnRf7Hhs+DuQKCrm/F2PZTqMssZ30JYTmA/IBXzputpAefAV\r\nRdH+BoRDN2ogDvLqJ6UlJbrzB682Xv5yk2YEEyTfthLSnUZviHWNTzB1lMcN\r\nu+4MfG2QwIO9K3WT+ZCW3Pa5F1VNiLiufS79gx/EkMQIGooNEQEoWjoczveA\r\nPxMFdtT95yx9ZDo/aBz6CsOujEX1qKpjwFU=\r\n=9PdH\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205090810.0_1652171470755_0.8637514636938648"},"_hasShrinkwrap":false},"1.2205101904.0":{"name":"@bentoproject/date-countdown","version":"1.2205101904.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205101904.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"43d879755f765aee2d0eab657533b493a025713f","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205101904.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-0cDJzlrAkMutUmvReERq9DqoZnrxODjccnPLSOi5zBMfxqRzWHBXHbNUj6QpuZy+/DWwzuLwAvTBn24mFJ2QEw==","shasum":"4f1e54c59d759618c067921c5df8b64f5165ee80","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205101904.0.tgz","fileCount":29,"unpackedSize":457249,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICh3fMafkCEmCWPXzyMhd8+vnyUSEyM+joQvqBuClN9oAiAhEh21lh6rHIkh26zos3m8Kh2rtSMbLU9CddBi15/73Q=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJie3Q1ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrG1g//WMGnBk4uNjYLC5EfDFyjmHccQDJsYotyEpffHgidP12oTKd7\r\nb/trsj5vP6gnaYjz0TwYhUhtoj0crxzYd4OyctIHzeGV8tPcOFOpMriQdmMe\r\ntn9FNuUGKLJVLAPRBsafmRDu4SjI8PNFBLDJ8xtITW2va3vl5crDEREGlDp+\r\nImhiJIyqZzYSeoJ9+i3CqsSXyqu05f+VXarWmmWkS+9uy3y/FQX1VYwQRxvn\r\n/myBbKaoGt9I0nkOSEXYo2Go4g9aveE1ZNImR7lQ9l4+8JM8cndUN0JLYgCZ\r\n1fGvp/FqSvBLHJ0zqMrTXS5rgm01WBMl6nWsE0djvJthMElmMJarxdekxpni\r\n15ICGxMl9YBGn3aPHuvryYXo63IlbqayYlTadxau7uoPNBJ0koORoekf6yZM\r\n3r6ABYKjwkQqZq6Bte3Tg+8XeaI0MAnw+Rf1O0vSLnN4RtmJuLOpwLPO7+LU\r\n9WsNin2KC+I2FZ2AoE2vHETUrE1nrHjY4axrFURnz02uzGGvaPQdA92qG7fR\r\n6lTqi934MLO0wbKUK6fnG9ihFa40FXCtpV/enECyXTqDznT6twCIrazTgZNy\r\n3hIIpybLFNFw5Jke46FZWi40YVUNRCyG6wfh/wU4xPSfK0LVSfn6uSyjWrtn\r\n41vmRuD0JLNMAZMfISSC6VGYiOPiLpaEz8Q=\r\n=oC8S\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205101904.0_1652257845653_0.5503063860378312"},"_hasShrinkwrap":false},"1.2205120110.0":{"name":"@bentoproject/date-countdown","version":"1.2205120110.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205120110.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"46f34860b9f501caf0eda81977d1ae3aef4a947c","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205120110.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-Ki7bX3ZcFR19pw0r4Qi5FLiaSWbGLpCeovey5g9bP1YCD5BMGe0hXQAEJl7ALmysYkUq84ZLzDYo1gRWJ/lqQg==","shasum":"f8fe30f87f86b1713dbc87099140b3f77abb4fb3","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205120110.0.tgz","fileCount":29,"unpackedSize":457249,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD7dZsLtPhGMxWTMcrwOYGw2lSqje/23d89W3j2mHagHwIhAJ6Byskyt9Ei6saApy8MJ/ynyGumaDYzuKWW7PSGXUEL"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJifMWLACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmr2QBAAixPgvS2O70gEirtRHjKdNT0MEmidCC1Q+a6kHvcG0rfYdIiU\r\nQt2YK5L5bMsQZVqN7hYAFv7KmCvqTubWd4wIwinb2pKvfUZfkjB5dpIDRvMu\r\nKl6L6ibQtllYU8IjuB00mdwiLYf9BZbNEZTC04vao+qalPw0/yfhHT4mwnPN\r\nepMjFRLN/q13EWjtd0iWHuZ+pwGkWYzCI3Y5/UvSh3pAaJI4R/mVhqSzGIVM\r\nvCD9dwkob/lROGaNZa1jFXmqltgT+5H6GGHvbuns1AxEjNAsvEnyj0v0ddtb\r\ndxFYG4R/GuwSFuVB4OZELGtqjE6nv7Yy39kAWM8lhMZoxDqQciME4+qbUY4P\r\npBpIP/bmB0ctvRX8JIos7GOmSELf2ILAW3572GLAzDP4cwRsuu4f1PRFlB9P\r\nFyFgyYuDUvOo+CziXlsWK4T36io5aduwKJGHbRzetJAC07fT4pwWdonY9XBu\r\nuPe6qHSiO4+Cc2txsIUbTbZYepw+ku6sDEvTVDIVLHjSgtU4dNyKOOfoYu3C\r\nuGuNGjAmuYu5VGvVHumfbfRiKveKUpqQh4IVoMcEh3TEPNcctEmlCQMqqVHq\r\nM+8frn38cPrTXbEZ6k2F2AlMwbAOPI5MWwU6Jo5rWCjau0xmaCWapG7iVQki\r\nfrhAADRPRd5bLk0Qwjtq+W4XNILj48W3GE4=\r\n=r/7v\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205120110.0_1652344203583_0.030464832061379177"},"_hasShrinkwrap":false},"1.2205161914.0":{"name":"@bentoproject/date-countdown","version":"1.2205161914.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205161914.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"2fb4e151488ba4d856b33f836151d66b45ca457e","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205161914.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-UIHzpGcFReVr+81KFIHS9D208+0+/MqSER97fEa8ontw4d/0IFrf7modqAobL8pCSlA+f/7wUdhWURPo2drJGw==","shasum":"510b2ed13f6313483e753008ae15308c9f3df29c","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205161914.0.tgz","fileCount":29,"unpackedSize":457249,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDXtW7FbNQWQ8O1CDv6B5+sdN5vn204UJCDv2v8z4FEgAiEA2IgA2LRdcgcygrwBhYmyO1geg9kpIda+bSL34JWTNDs="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJig1wAACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqeKBAAiKTJU85c9vQe/MvvcLa0tASqTGRZSQ3CBfFFVp8VHSlah5fZ\r\nHKU0K554hFwN4bHfyw11EPSEj3be0kPTZEWN0dTmX/XLi670LDQ2sAtZqbKW\r\nOjRWrM32ipsxWIAzTsHhallYsvMykH9vcKhAEtymbde3aykPQ8GXOJ1XwXjQ\r\nXyHFoUVrd2KuIwtaecU6ON/CkxTHl965EiRzuu2lGbw8cCMRAHhJgyWmwTE8\r\nfj32FbGi3lgJiGKIck8MiICLrQW/6OacAE8OPDlG6XxQ3OL7V8NWvn9aH4rl\r\ntShHzUTikOVqWmeuxcmSjswLTqgt09kBWGUFTXp+8znBvLwksm0vynAzLdc7\r\nqlhJ4WKhQN9w2rwJ1srqscgHBhHmMl9AqbYtXbIY28OnhHYA06fVTLFUmRRf\r\nbrOeTge1lhB940PvU3hoJvYxv10jUh/c6mir9Ia6NnIMqnK7tsOCorYPmjlP\r\n1x4L6mbvVNPWfSIfmxpzx7LNT9M86j4hgEFDWRy1cOQyyjdb0swCOm5nFc8D\r\nFOIxWMRVQlj0vBMi3Mu7fQw9BDYDofP4O/ib4vtvn/9ToQlK457He4t/vl2V\r\nLat7Xg4mXQKzhflBJd95BWgQvVc0OgCy0U1JCK0+CbHiRG6svuURePj+k+Je\r\nRRjEXEvw+Nr+PrwE9mBukIbra7xCudEFxEI=\r\n=vYDI\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205161914.0_1652775936625_0.12388448712958544"},"_hasShrinkwrap":false},"1.2205181800.0":{"name":"@bentoproject/date-countdown","version":"1.2205181800.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205181800.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"fb3f61c46e2221f0f2e1dd836127cce386c7bbda","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205181800.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-Uuf6A+yl/W0Aq6iKy6apvbumJSHHN7eWEwAx1Q03ulbVXiOUxdrI0tpmTA97DSLMIoiZibKBiP9gVXVLBFoiPw==","shasum":"c2960cef6a22b8ad2aeded84d483a039aaba7a41","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205181800.0.tgz","fileCount":29,"unpackedSize":457249,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIC5mvKSTrkobee7KgzMif0kucXddRDWYjhP1aW55M2eyAiEAxAIJQHCfw0KKtC1uJbur/ag+NtNFosBDo0Ws3TlM350="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJihf8GACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmrykw/+MaN37LJQ+Zb0J/G3ih/fqj+ogHa9oABYIDqbKkgDr2gYMNGB\r\nVy8nRLQaw+EO0NlygVPQs2GCaRl1GkuwuMwrs4nf2FDZojcxu3lznMfxBgpu\r\nmMMYQGNFcCgm/rzL+FnSM3S4LlE8XlmZgPt+S0xhLZo6Wr1ZjHhG2Dptb+vO\r\ngqhxhND09DLbjOSzuKI978DY4IUrY+mwZt6ywO4pkCkXhFRW5cK9qB9JpyZr\r\nwuiIPfcli1dxZk0Jrm8KWDpFXqPzo3LafOpBZwXOGKcp+mQXBS2IwZ9r/klx\r\nwX8rnrX94eRA+12RxhGsvi808L1baALmRxhn7nLYPDGjOOdn4pPPL6HnYjnz\r\nn3wkGkcLg1Vxui86jfupFeHcddffTd/RpVWM/A57zEygF+yq6SzyqbMvngWk\r\nM6X5LyXEJr0myrRymTbXJMTGjsK5gzu2NnKw3GFZtYcxn+dVNd9poV9W7RFQ\r\nP5+RmTuaLQrrmpxuvg0IX/C0WcIFs+JKF/j7wHg4jNtEwAhr3Chbf1w4Lxnr\r\n+lRZZxui5IuOgHum3KiNsUyaM1YbByokTUzgUdYxGphh+scavwakS/0Pk51w\r\n06i1d0cC7+/P8R3DQ+wjzDyH6y7KbZkapc7OjOMgUg3TwYdtwFx/9JZGsFCz\r\nLmOSEbjDz4YpYkWxciK4HnyK7L0sHtBUVDw=\r\n=G97D\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205181800.0_1652948741944_0.7045045869371565"},"_hasShrinkwrap":false},"1.2205191749.0":{"name":"@bentoproject/date-countdown","version":"1.2205191749.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205191749.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"83c369066eb9c7dfccb12aea936f29a84bad30fc","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205191749.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-DwG1421TCDZYp8hbKDZTr+a670gxT+3OCJxc+p9rYjUAX2OrvusqQBXWUlxkInmkj93rlI1bDNRaaOne+4EMEw==","shasum":"091516702e414846fb05b3c0b254cf6463134589","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205191749.0.tgz","fileCount":29,"unpackedSize":457249,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGs0pQHQTMM+J98QUS1npTz7sLJNNeMl+VNHcFdGU2q2AiBhtb2cBiwfg/1Th2QyKGTfK80k5yDMzedebilsu1RPLw=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJih1DUACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmqwnw//Qsl+oSwqPolI4uM2CaY93fCWfpONeQvF+2F6WREhP3+B+dwT\r\nSePvhZvvLHVQmfsSs46IxplsRFd6PSFpExtnxh9Y3PuAk076lSZhIgHCUTZa\r\njTzQDCpSwfFfhIPUm13tiLLu+v2tK6hfoLC9SNgY0Z1ebxuDsVF1ZsLctV1e\r\nfct1qdkoTYijAz2a7g94Khd4uV+RRyAatwsBGpr1V4JSjMq9a0ytxssMuoYF\r\nrnQ1SG980b3Lm7hHdRiVzhFT7n44JAJpromrQnH5LplSZpdZo9WtMdaLQYkZ\r\nBuEN/CxtTtGYAntQM00BkHoze2pki3vaqAGiGvGtO/Go9HWVhtVWcp2h1XQT\r\n4JP/vtlHhi49H0Ug+KdGsRsOWj8Kl7b3b4cmoIAXbE6ns+sNa38AhPu/JVhH\r\nEkutKr3c0EtGCwpRa/d6GTUmce81Dp5R4TWCO3SnV9N45cda+EXpEzX6YyZW\r\n8nW4GlwU7EAQteJ+T2V0OrDIT427sT5D8hb5GCtc2Az8SvNvxRw6O4UYcplR\r\nAFP7/kWDx/eufnmWBQhaZ/qXVv7NSmjc0PMi0n7cik1GLPpye1VyJwbnZwSU\r\nXAPQHFGnwY95GKMdyPopSIkoJc2W7U37GJV/7QvRNFHrGoH1jgrgKHPZsTb2\r\nvg9jU1FFAWa7jLnaQoL+VZ/CG6Mxd7GrLAY=\r\n=+fQA\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205191749.0_1653035220683_0.3217585913564234"},"_hasShrinkwrap":false},"1.2205232225.0":{"name":"@bentoproject/date-countdown","version":"1.2205232225.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205232225.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"ed0c674bfc87fac47bc1360a13f5d69611a1228f","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205232225.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-mQMdFZGrPeY9VVltVoyWx4/Ffx8/W42JQD8AHkNzQ6MThXxWMf2wC5+RjHjcSJ4uUvUt0Nw8LDBtg3Je6ir8lA==","shasum":"7f72d6af271bdacc2e465f6c728c10195f74538f","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205232225.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQClF1vu4xV4avmrskTUImHUWgXw74HhkPxnv09Gp/cX+QIgPI/p72BhgZlUiV/WIlkfyXi6mlSVaFU6ti/pSNyoeKg="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJijJZ0ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrNKA/+Mw5bHKshYMATv6yQY1I54joJvrfEGO0fmenSttUL7kf6Trvz\r\nonqTlIUlUsBj8MBh1bWLsx7bJVevJChB8E2Rl/Ku/GJeqtlyQDPb9xIryLNo\r\nqIpRRYTq+32JtAYWRn/2xocGJ34RXfIJEEKA8xPTSZUFaX4D5dDNausoAqGj\r\n+tiiKeN0UZIt0rXjxD3RCAD/ln0nkkmJR/GtIfOin3xyPOITuKs4JjGzALZJ\r\ntmtNXggcrmV/r+qNjfUzLLQSpZDEKq9YX00AWwdzHKRP6DqpY7wPKt1sSVVs\r\nXnTeTgSl5WRvGsIjwHosm+UsfIQnlY5aNODAq1sOi2CoC2S7zHF06KlsdL9h\r\nKjCLIX21iXEKdom03KSOrXfgIaAcaH+3ZoxaInbIOxKvMXntdc0vh8lbuVzV\r\nxL6tC2K9dseIRyi0f1boupoCl2D0f69JePSdBh0xksZSGaMK5Zcw4MxcU2+x\r\nSfnnB0fAJZdbCuqmqW/QxmU1N7zJ2hUojO/psxS14yQk3T3KS+IqaEL7VeYw\r\nYtsHr3KDRZN/iVs/ErBp3yrIv4/McTutVd1NJNTaXCHf5yJ+6ah6ZbQHn0zD\r\n0AKG6k12Q7ulZFUTOfJglrsVH83hY7b8pvD8N8/6e3MlhBJzWBf3xgh9hkM8\r\nK4a+rzJsP1H+OCsTSKWXqv1mRSZCY/bDLhQ=\r\n=osQl\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205232225.0_1653380724039_0.909840506978634"},"_hasShrinkwrap":false},"1.2205120110.1":{"name":"@bentoproject/date-countdown","version":"1.2205120110.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205120110.1"},"gitHead":"ed0c674bfc87fac47bc1360a13f5d69611a1228f","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205120110.1","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-dw0K4NoBKQBFILm3JWw1y84jANv4XsupKqGy9pD/sS5IHnzvEKTpDC91VfW/B+CSzVLHnLKQ9l4XOYxSJPBwBw==","shasum":"8b8dcc50f77604382f3c39e171bf18e36f0ba599","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205120110.1.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFDei95KqOJX4HRH3vPCza81fivZ84O+TOSGiD7hmV4oAiEAqlabPJk/BTRhyVKhxmkunD2Qm4mu/m/IigqxpD7a8nw="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJijS3pACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmpb1g//d5ClddkK11Ejgc4JGcrw1aq5tS4D2nP6nvAvo1s2F6mxUa5k\r\njgkL4fvFR9GUaMxcpvXSSK8xo3Zhp3naq9JCYwDf/Ry4f9UEWFuUG4B64GQd\r\nfJgTxJ35TdYwgldMJqQtRpztnavSvg+ySYG1tMEjqvBU+6hTqJ1+9mVYCXwQ\r\npIg/oMglyzCnVSKMeyO4QbfIfxEroSb0nFJ5PQ/wua2LMWb7zDCy93ldNn5Q\r\nn7OzqhWKsPDsXY/lpFIMfKVyVeNFiFbcLfuQhgkrvUgeM1YKohTRu47x6TWa\r\n55Fr6GxTV5PU/0OohRztoajUBMl4PW3DHBJ3VqaJ+MmJ2gYDIL6911nMh3VB\r\nYsrWLkIl78SP2oD3wSbCpouFw7R2fl44PqimuoDAFj9PtE0mJCYk/xQaIz21\r\n6/Fyw8LShVucRo4Vekdq0YNzkdomf3/q7l4s3RuHHjoHGWYPDCcBz315Kc1H\r\n2KniB+o4f/Y2mPzjLEenBLRtvduBL7ofuP5AGw79NKIPbDApzRpZXrrY4Hjr\r\nahJesnkmuRzEX6Cw+DIY1B+tCr1EYESDI0Ve8ClGIEhtQdayO8DDZtKeumcJ\r\n+dEUMbSzn92CYsN7+6EGK7xmBD8QAKF0Pdt/NPmL/2x0V7xDv5Ky5T2FE/ZA\r\n4JCDQHhJTWpxsliZem2ii0iz9CsVC+k+ocM=\r\n=CNKm\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205120110.1_1653419496899_0.4917700811271728"},"_hasShrinkwrap":false},"1.2205251942.0":{"name":"@bentoproject/date-countdown","version":"1.2205251942.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205251942.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"e2f9546e2689785f0d9b4ba72e61759323c45bef","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205251942.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-nm9tZsWsHK7DmtwRcIIf+J4fIs3etTybzV/ZWYHmlkNNDCZqx0QVyYGVFpuwR7pzpvn174fBs3UIE3q1w8AkFg==","shasum":"3ab353a86fc5ee655ca627e944d170e3de7ce964","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205251942.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIF9iHRSoVT/ufDsf3p9Q4Lq3WQdQyXKmDqb5mbt1JFkAAiA3niznAnMLChDZIxrD8nCPPEEwx4ztAf/6je9F+jRmrA=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJijzmoACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq0yA/9FTO+ZvosQs7FqcndUdpp2lVSprac+l02cMvBhtiYPWvjRr9V\r\naFY/rf1bFLncqEAMhRYiMGsGuiaqFkUzZKvOalXtBdAnGkVnMD9GLBQDNHK5\r\nw+bMqw0ZdiuIjJp1yqrxDpKW8ur9WtkIt01Ir8b7dpdtHxCoqPiZxX2zvz3m\r\nAHLDRE6JIO4IA1LEGXmaU1ABKSHHq/MXYJr/bd5umlWhqQ5OQDGAf8VN5M1p\r\n8gprcSwKRw2DxC+71CeWaNA3CNZx5sZaIgX4RcoP2sOLElfxM+79GTGg7RYu\r\nmB6rkd6V7Kgu8RJJ3c0TozhGpyxznz06Q+6Zc/eRLy6otxIxUtIEIFBuJ66n\r\nEnpVuOPUmyCFAdSNK9t9gHBwoqPEAt/LKlW4FHWNFwAQ49EKPvGVUtk57VTG\r\noWr1hulwFXmVUoQ3/vDEg35xFstGTNCbYRR/vkEtpybNZUzDJmtw6BIYK/13\r\ndvZLBt+z+MUDtaJND3Jr6EvRKvlX3A7+Om6yge1PkLtH1zKHk6k8Ih5y3zOP\r\nwnHZ32LbkuMeM/g6eaibzt83ZnXxEkzA2Fl70qr+bTzkqv4OmrOhngeSrRha\r\noY/E18Jn009KHKMgiB2+7URqSggThrhfRfC6Ay/8V0JPeLbSNdXs7PZ3Mn2P\r\nPUWDekss8cl4ygngL66kqpGGCDDQvrxsez8=\r\n=mzOo\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205251942.0_1653553575963_0.7024463699741341"},"_hasShrinkwrap":false},"1.2205270638.0":{"name":"@bentoproject/date-countdown","version":"1.2205270638.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205270638.0"},"gitHead":"11e6020f1ca745e65b5d80408e0beca2a8d38004","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205270638.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-9XCuVyzIL6fpC23LHvb1TnVpsy3rg64W+3xV8REwDKcn0WDfMHOFJPU5f6zf5qGGyKn7EXCK+L9Qafx5B4yF2g==","shasum":"5df4d09ef9dc5d934910405338e36c976914846d","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205270638.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICVricySBaxMOMBthKDhAtN8mqzGtRsDH8me6rHkq+TEAiEA4FqMF51gZlOzqm18orZxOVshOIpyMC2vcZFrisQrBvM="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJikIsMACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq5fg//WC4zVndGStzZCfNNeCNn3D9bDqDp9ocD3x5Yf3aj6gAYpzFB\r\nENErQV7TXiBgAYxglBFcExKyNrmiDdQyqpJVWyU9AWkreWbBbDVCmlHCJXav\r\nfkVc9B8tJY1op1mvr5LWSiQl+jvImOrukJ6Rish6BKxNdHmgbwllCq4/lFKT\r\nKZDj2Y5UBGX2+9Ts96MGfYqmUbCCZ4vWm9bnp38D3ghokXR1KVQWLCRyG9Oo\r\nRUNLiuB2vaySe2bG2HQcs7hQxwerdsM/Tj6sBd99vJpvT3R+0NKIPJxdARdp\r\nnT4B0Ewvj4F21/Usc3W25Hc0MHyi1wK9TKhm/tVoswKHIJ5075X2ilCI9DAJ\r\nlVl7oHqu5l52JqHVJ51pUKD0SRuWMF/VaVsh6LVLSGC2fiDSXYMXRpBXP/V7\r\npKnkfrdPJlZgIiFDy7pPM4IaSf5ZHt4Oa870i8LkpEEKRZOnzJh9aGwvm6oo\r\nkEWo87nF35C9tuZB2wc8AjZ1EIDU79gvxm18k9X4ivRzBX0uniyVyP5EPF/V\r\nQuIY+dXyItfMoWQlcE4hFWlXMSFtwpMtO4gEWXDQ4h5GEZ9hEdIc+7jokcAI\r\nM7LrmtCMhGO/nsrbXsBsNHxCIFZgmfrgBhmgvvHTamMAg1Gh3zki4QHOFNsx\r\np0viOR9hHl3AsXI5VeRZ92SfZl+RMeQvXsk=\r\n=DMut\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205270638.0_1653639948810_0.22696244931677656"},"_hasShrinkwrap":false},"1.2206071918.0":{"name":"@bentoproject/date-countdown","version":"1.2206071918.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2206071918.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"f200c815cb7bd0e1495bd9c338425aed1887a459","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2206071918.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-EJoqQm0/VRXo7mwcHSyckFmMhWCmscPALB8QhMVUBuy6qCRV5Ri3omKbPEA/VrOM4V6YgHtOHVTVg1y2PO7ABw==","shasum":"29fcc0891000e1f76cf26ff7e55611ededa73dcc","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2206071918.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDXcq8P58JXw1yokxOj5fOpNu2IZNj/DFA81VOTzzymYwIhALrUeKtK3LRdbpfTtFGmy3jyctgpcrQpuA1P/Opqel+Y"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJin9CuACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq5Ow//XEwav453qdHMTa95Y7JZphStB6XgSa9vM/DHlAhZ62ew5OCk\r\nia9tj41ICm5OjFjp9Qcxia+yNOQTjb4dQ9TIht2f3OU6C7Oyv3G9V5rtiKxa\r\n53lm4gwNkmVcbjmPZnajY2+8tDwqv/m6lvvP7nI/q+JxNDu0M38kRJ/X7k0W\r\nTN1xsyg/k9wASYX60ckTHqdAVQabzGJ0tbezh0Qi1XjO2CvRar5Il+TcmsW2\r\nvd0D/WTt5SW+Qw+fME6p3EdMJRNz5keujoOtuL13ivW7o+mR1zs4CR/Yg/Z/\r\nEjCDtmjmSQMzHvbRw8jBMHFh62yD4/QhYaClhFQC5nugrPMSelytcOB4x2cu\r\nyOcSNlx6hRBIYIIN6OhsepxnxyiLDddaghV8B1eVtpXJgxBvYMz6zckZMR4v\r\nQwyjvHWYweb3+nuxHJRbushv5Y7Oa1RfFyBK7nV6uaBz2Js37oPMosYYsbEv\r\nFJpsKuPymwm9SQge/SSCpqZS99lHQLhUSYSaZ3/i8Hvc2qAGU9/WnurwZ84m\r\nQiuaMFLc0nhMIXMdL+MYAWRuseG7DbeoAVW5zdC3W4Kk9GCUEyN9FOKmB+r7\r\nooMmWBDU4Q/khE4bG9w/Sm8hHdnC3+K7w19S+xexnUTYAcxHfO+6G6NU2dne\r\nX9ZtJSj3lWzzriIcJ6/Vv3tDCy0404VCLyg=\r\n=ILzE\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2206071918.0_1654640814393_0.38123341319228876"},"_hasShrinkwrap":false},"1.2206072228.0":{"name":"@bentoproject/date-countdown","version":"1.2206072228.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2206072228.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"9cfa89fc95b4eedfeb00b4eec539909f0b0c0f6e","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2206072228.0","_nodeVersion":"16.15.1","_npmVersion":"8.11.0","dist":{"integrity":"sha512-aNd8BEi4ywdMP3m+Et0jkbSmTSarBrKvGiMvKk6bq0Mz5SdZB4y+WBU8h/k1LtO4r7qgh5Li1KLEC4YcPgt84A==","shasum":"844ae5b72be74e7274abb75de34035056eb64f3b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2206072228.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDzxr+F2dBOWn7kUnPUfNplB7YyhYmtQ0ZZnoGhtsX98QIgDUvItO18brcwV5/Q6OKMxGFuHbwLwbDiTGMH+2YIzLA="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJioF0sACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoDJg//ZqC9Zzq96Q+C1KBg3b/rrs2+RWby7n7RTc9v+8P5JhVjqW4R\r\ns4JHHT4MFDMN698EfWQ0+Af+outrPb+FOEqwIvJrarNgn8KojjtZD6I3vbJk\r\nOaRXy3V7/3lPS2ozoY1iw1U+xq1BN4VNdGzG9tB2/tPjg36MHNqRmwvtH6O0\r\nbOkzO8NWdHXM7f66oqikYIpy6yYkjP1xizOKygHwSVIvpf4Twm01kLQG0ffv\r\nB1fUbh7vadJfgfMNnQuiskjTvo3plMl9/3GGYgnRW8lnv2sMKomTRXQNjCOb\r\n0KYqBskWyfHdk3hcBJbmTIqghPuwUQe4MoZTXSXfoTcW2pUEQ6phi1mHNN9L\r\noWIAy8973x7EIPazigEkI+nvbCFmq2h+RG/cew7aMOTwj+HEu9ZIygO8aOqt\r\nIt5J7tbuYWys2jRpNL2QP5/BtkC+khVtBcAeCHIsjmSgkOLZ4lViPFJMEKGB\r\ngUrYZ4qlQSawTtjWumWj0h/fZIvJqF6WyYpAy+AKCc+LGbW2WHBYLrBVnKKK\r\nDLUK7zwx4JV17Mn64ZO0y0vuEdsKzBJr4vqli935W9DfKmCsK/7+G+8kMdqd\r\nYV2+rqdaYH10ZCtYH3Ler4YO3xPN9CduoWLYYRho+CHYEzVN35AldLP5uunp\r\nij1HFI1iS6XmZQhpoLm5DIlWDPUwKenHHCk=\r\n=7CLs\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2206072228.0_1654676780091_0.9233550568077331"},"_hasShrinkwrap":false},"1.2206082301.0":{"name":"@bentoproject/date-countdown","version":"1.2206082301.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2206082301.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"32e83d3790f33da4840247d996ed3f6b256a796d","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2206082301.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-DkwdrIWt/7++CDewGcSa8Qa81pEmByOQBTvOV7CE5cAbAPt4mzZRRVCWvMp1f+p5cloBdLBHCmmqDOF0gRdP5Q==","shasum":"e83695aac4a02d92f6eb6999729bb4c42a2c00e2","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2206082301.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGIKLiFzsWnCdPddGWw6tcFlp/rl6zC/q7p1xmgh3+KrAiA+KGKbMhAPCWzROUDP2s1JNVgwf9YT22XdnZGoyrpGjw=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJioa9XACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrCxg//aao6WBHZROChzm8CdDH3CZHgV8mq2TfA/bWQwDUg388FqFOh\r\nehZpuuNqj2lvc0eFRkJl8YacO07LCjRyn2+UNkp2CnUAtbZWAC+ERDV5FyFz\r\no38G5tu/Tq4MQ/D3pS3UCVY/0y/ItjXFRmJDLc/2KVBQT4DlT0OSkq27GCuC\r\nHwPW/w/S4W7Le2fMdae7kJFVd53cE5y1zuuycpiD+dVEqbRHbwZUSCiLR/0m\r\npIr4Da8XtYvbscL8G3JYkHnUbSRFKi1EYf50p38llAZvt/MazwIXXOMd8I1E\r\nDp8RhlJEHr6t+bc8rmeMt3VJUQuXWrOz0y/ZHuZ/YHEre0ODso+2l4OH80Xl\r\nFVTWkPHsL082N8AfuX2rw60r1ZgwaeB12e0BUCUiMuhkOV2WGJhZivaYgJxX\r\nnvcU8lIflNcYR6EBIe0p24998/gskfLV1JLkqA/ezu2d/PQJCe/NRtEnBwIR\r\n0b3v/Lu86p+Wzfld/4xYnTvfShulLBLa/0I8z+6NKqVg5F2O9LJ+bqquCqlC\r\nOl62BQZVKfMaP5yz8r7vLmhCkUIILAzOQ3sYywcNn4eqWTBb2Q+GWtngJ4p7\r\nveqfBBl+f54k3HoVuA+msupJGySA+5a0P2h/ZoTseWfmZ2tmdCNdk7ZJi/DM\r\nLf82L1unETBrGm+S3arWmhs7aYWdS/rKdQ4=\r\n=izTv\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2206082301.0_1654763351362_0.9470740596732259"},"_hasShrinkwrap":false},"1.2205270638.4":{"name":"@bentoproject/date-countdown","version":"1.2205270638.4","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2205270638.4"},"gitHead":"89e43e107472144de698a2c3ebc9e78ef35d58b9","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2205270638.4","_nodeVersion":"16.15.1","_npmVersion":"8.11.0","dist":{"integrity":"sha512-GfR2n0QSWQmX9v1GBzsxsJQneGZnRzcoUjouUuD+Pn8m5H5BD2sW6XLxdP0074hgA83Vdinhs1RinibixgOeWw==","shasum":"71dacb36a728a28de6603ce7f6eb3674936f957f","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2205270638.4.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCfXU1dJhklxcdUy5csIdK+r76Ep4b+IMEwzUyXjAlnBQIgV8IMHkPAcQ+VRbZQ/lkFNEZ6HQTyzWp3wfCjQuUTQFM="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJio7jUACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmqg0Q//b5Ryf6Gk2+UtDk8rEsIVN0LQJ7Jzu8noqYXU+bnudQkhXSxw\r\njGPpPgRDYjfp7GPouSbPHnrnBnYpG9Al1/2SAnJDTW4AVqChCsNpdXckNyuM\r\nBtwCEQNU2iHVJw+H4Z/Fw/sgYQefv5SfKn/J9Czh9ZZCXNncDMVRjjPwFb7b\r\ndBTtVqkeg4VhhHytRogHT73zhbCUV3EFAnbDkYV+jU8eN64mGnT6+OiMIROS\r\nMlfDudA9VN2Ssnq8JGQoClAmC1CQfcVT/kiifpyfo15Czu1eDGDUVimQGnHX\r\n0xojDVGNE9ar3vZx17uiC/sNy4zR32Y+ApNwOPLdtJxFag/4HtSCIvexq3LU\r\nTp4JxoJgv0Im8kS4oNLVd2skh0UsCLgc+1G0o9y2nodE91wsoTLVX2ilnzfx\r\nZMj+GkCqYpDm5VWvkuJPUlFwQsxSMcvleDoyy34z4PDsaIpEgLtFOCDYMCtl\r\ntnY5tJHL47zcVwPyIwMY49fZUNe7Ldu47EOWUzXYCNITQWHvUjQk15ITSLI9\r\nhWjrqPlHBzkk8TStQwG3OUilgkC3g99lkWfhJp1ffABfa7feSkJmG5A63rA2\r\nyX7b44+qIwW9umFCMdJw9coCjQhbeP2gR41U716SzEFnTTP7F1AXTlJydybc\r\nP9oeFV4zon38yG0c70GFqB59eja18V/iDTE=\r\n=Ks8x\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2205270638.4_1654896852114_0.2607614643912013"},"_hasShrinkwrap":false},"1.2206101637.0":{"name":"@bentoproject/date-countdown","version":"1.2206101637.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2206101637.0"},"gitHead":"89e43e107472144de698a2c3ebc9e78ef35d58b9","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2206101637.0","_nodeVersion":"16.15.1","_npmVersion":"8.11.0","dist":{"integrity":"sha512-eFftSCeooB9UmF6Wd0hH0OVN8CkQnfwDfaoc/1bv3DqN/bKIinr7sSP+4rG74qk0dzoetpxsElPXWqosOxn3MQ==","shasum":"b0eaf30cfd1b8be9ed0fe85491d937ef4d4568e5","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2206101637.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDjbV8crO3bAJd4dakyKn/pnXXm6Z9p0DZrvWjX3aku3gIhAMOyZYgzZOTvhcUirlEPtRoU8T0i7ZKvdMiRL1+1s7Iq"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJipFF3ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmqu7hAAnVZBRoFoIfgZcHuobu4FgNhnXTLVip+2Sejz1oVk2vWCvRGn\r\nM8jFFiGnJKrjqUuGrhSP84sBWIJR1MpQz7AbvYu/HKR7Kc8m3WEF9hGCH9E9\r\nhRVwuWKDVQkvIPxIOwMpP3/XS4oy39TFEEcIgUIaL1/M4x4q4U/4cva9Zhwq\r\niHa8cGcg9sbAwrgAgbsJ0c2PhMACKCL+ULZHfNZlTxXvcS1dyd2ufcJqQuf7\r\nmFtLUoPy6IICQH0yWglqmHg/ktO9i/kLOfWIhYrLpHH5Szy9nMNSD+om+YwD\r\nkSgDFTXKlNSEJ+zr2Gyh8r24iMMZbdVBjoQgmPAN3vq+j+O7wAKhf36BZPs+\r\n5H5MpRAkLadQXOQuefELyMYFUhnpKorgtxedSp/wnGY6KWzigCVbAgcR2PbR\r\n8IOaIxRmiZHHzlUU85j0yuDPfOZHex0ewWayqaOhcHAKvhc2Eczf2ytdAtPN\r\nEIpYkzB0DmECTepVprCDpbQd5I5FTuUoROsUtAtvOMWj4nRqtwtJ49E4Valo\r\nWwdaBA2kE8jlmoA6dVRi9BKBCum/Hg2gQhlQH+OgwDIeqRCnhgy7E+5nEOmr\r\nEJlUw/o/LJZVM/CIGB6Gv4w69PVx7v4u02Q7kzojKkpXkVteh/3rxyGwHmIv\r\n88HJftCqvejI/iS/7u++Wo2i5BBZQitkK1k=\r\n=ESxl\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2206101637.0_1654935927411_0.5358842944616444"},"_hasShrinkwrap":false},"1.2206131450.0":{"name":"@bentoproject/date-countdown","version":"1.2206131450.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2206131450.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"f8fbcf58e78ea43df73b529ed4a25e79ac758981","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2206131450.0","_nodeVersion":"16.15.1","_npmVersion":"8.11.0","dist":{"integrity":"sha512-hBbAFak3YqNu6Qwz4cQtJGHSD1pyPeez1yu/AV4WhOpUEBKP32NAUwNnT1by7mQ5BkY6RgjBDj+8L5FkoYc6LQ==","shasum":"05b226da2cd106819648eecc14a3a49b3994e71d","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2206131450.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGEIKYY75u03aLB+08tC6nbzc5rXyGcBIhBox4uDtkYrAiEAt+1TKwm9BMI5y54+Ls6W975JyG2MiKaHZbaK2+0B+l4="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiqEZKACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq9xw/8DSbqBFp10o7nDdOH+0gn8/++nmjoWMeKbPF+NxcUs7b/AXs8\r\n66Yk1+8z51iXwqsMfpGMQLIoAP3h0KsrSdUAdyDYgBhWC9Prr1wwWeraMPIv\r\nnZSasKpVBbyL3puvBsHMODb9SYMTNclj8beBOycv0smSSRSq7d1cwhe61zd5\r\nU2TZyNPnaf+ALI7IHjtt9apfKB8FknQPsPhTuEHobdivsU0IaBiYFIp9GXMI\r\nZ+OjBp8eDUNUR5Z41sEgEj3AvlHm5Xn0ShR+wRzJkZFXyIJSxMDqHAxL3yeK\r\nan3QoGw/FwwtK4TNkHQLoaBSTga7BZcmwt7+39KWwTCeH2cS3ehUDS4Rp795\r\nOQG+7VuTt8P0KpEOXfO3/7bBwvTmEU5nUFITpIbbPgDijjzNi1dPye+9+Ol1\r\nPpttwjWjNgwsAGmO1qxikcjIDVsdORtQWZyce/txSHeu8GMqdqTIe1PUFq2w\r\ncYacUp+ZkwrVOUxTZXFdFJOVGfe25OXuPtDr5CagEB572A+3N3kdbvBAlF/g\r\nSNl+rDnX9CbK0b9btybTFCW9ZuyFtvyJCHQdKjCpCm8M1itsZTzCniBuOvEb\r\nFM7oJCdL6sn3oAM3VYNOBa+9+b763UFXYveuQY2LPxQqK0dKwARv06xcDa/U\r\nmlc3yF/bvsEwY6mYbjjzmGgRJQ7OTGXrW8c=\r\n=cVNT\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2206131450.0_1655195210218_0.9651735868118037"},"_hasShrinkwrap":false},"1.2206071918.1":{"name":"@bentoproject/date-countdown","version":"1.2206071918.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2206071918.1"},"gitHead":"fb620756f1e66d99fa06cbc467207602e4aeafee","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2206071918.1","_nodeVersion":"16.15.1","_npmVersion":"8.11.0","dist":{"integrity":"sha512-JRuiPvxE2II1A87o2G92K/sfmsQniv8PGYUKgtmFUV1LpeiSArrxn1MJMh8HuOjw0I7epgQNQLVqdjfDresCRw==","shasum":"0087dbcb42a560e4d38c25771adf2ac4ba0b1400","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2206071918.1.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICjgoGbjquU/KMziF0yIEMdJEGGH1RHhk/0O9AwpUGMkAiBLA6a3PqviuoBhJ6timzPEl9oei/S2oVNjdTZPV1HRtA=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiqPz8ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmo/XhAAl1Q33J5XDWOolcZeKG00TceClze5A6dSs28b7LZpuvgCwDqW\r\nlUy1YnHZsL2h3Up0aCzSSnXpa72y39XhKHq2x6zC0FpNecjpuiaGo2LT71H2\r\nOjZJLlTUAf/gMJO+vt8n0gP5asnJt3qM8fF8BT1gst4It88BS+69UBpRAZZ8\r\n2mD8DuT0zuV+HOTCLaaWeN4WAD72dDgMWYam4oost0kf3JOy4500Q4GM3MMu\r\nirK0zMqeTB0omMgnNV83lVrrzy+ygQvZbDqmT2hfLHo5foiOhBDQK0SuOjLO\r\nCUTUw5ReWqAdxrjziI967ELNWOZp9IR6l2cfLVU0tMsPpfmK/MuhxQAnxBYx\r\nUd1Bc4vdHr0GnNhIgDBU0/xbuEC75hz8OqFA3CVQcCaXClMrbU8/AcGixO5D\r\nqXRLtASwcDRl6naFt2CCmgA0MBq3JO+lO36+7G9I3G6JoXfL77Bo/j8HLieA\r\nYQhrz01dxbhC3qKVHumLiV44l6MNlQ0Cx+gq7zUkvd3iW4h+Lx0dz+RZbK27\r\nCDAEHSxS2X8aCyHt66yOhMWyEmYlcpJsmBMn5YaXo/U59D+mgL49azPetOAU\r\nPUxn2xefAe3eCcMBeWlf445inXz2X+Sxb96ql652SPYmEkuwXBUScgPqo9IL\r\nWpGLEi8W9kbSoCYGiPCnIMPn5s9sfxJYzeQ=\r\n=3gDM\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2206071918.1_1655241979998_0.6763132437723827"},"_hasShrinkwrap":false},"1.2206162023.0":{"name":"@bentoproject/date-countdown","version":"1.2206162023.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2206162023.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"15781b541aae254d04a1cc777016aa40759100cb","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2206162023.0","_nodeVersion":"16.15.1","_npmVersion":"8.11.0","dist":{"integrity":"sha512-kVVIKKTJlPNsWyL+3SE2oKwrI0QlciqCtx88YZlDGmKlmHJwok1so0tpQ3VgbBvtZAzXkNm2c3reoUxSIXDX5Q==","shasum":"081f89a90310b926c8031e28f69c8da168361bdf","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2206162023.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD3rvk1yv71lwSXL/4/NuswlFulhvz4ERADqPU77cW4IAIgXhY+XjIyJMeT4/0r5YxtSt1qldh6/E3Pwng2RMWzCRg="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJirDqaACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpG5g//deMWzUcAbBowieqdEvPYPXe04jsZu1uWVALomlcdxWC9K6M8\r\nIYdYpZEvAJw9tsPEbq2p7X/VNkILTF0UBsTZiKggFK+8KYOwqwdvTjx8zCnx\r\n2lDDCD3h2YU78Flx/04QlstpOXrao3KtNIKwUyfMOVTj/p8PtyiJuFofPz5e\r\n3IUZyWt+N0saE6sTkWhYlD1krDZms/B2AoM6A9do/4Tic9OoRwGEbohiWVth\r\n1gatldITB41mSXPhx0eKCEzfk/UojC+OkzP0zbNH+jowm6WALZguyXO16x/E\r\najdRJrYTUN8GYOcAffoxmq3Hq0h8WJGePv1hjiBjtSKZ1MQRk4e32msfD3TQ\r\nGIt4e/S/EaaijjhlUjI0885T+GYljdVle8KkRRldg4sKA3LAPpL4abVOyO5j\r\ngbvFezRZ9wWcSKK794EL83Fo6naXXE9UUt75ADP2zzL0wUVRmCngie+LHREk\r\nPXkjzRTMz1fkXq1sHN+5h6XKpyoaaM+CvONYha3szdifdrIyFICQq5TIwtnH\r\nUSOaSx+Xq4zVmyZLm2KFSbI+R8cyRmJORVp1ECIGyLK9SdtQXb+sMUJ7TOIY\r\nW+6jXdOJqdIgVhypAsAe9CyonhO5XbwGl6a4NppJaGPwyCrwIJFxHISHQXE/\r\nrZ/edWcqgcd7b/gDQwwCccrCfHepV7RRM4I=\r\n=kyAE\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2206162023.0_1655454362727_0.7242317269242304"},"_hasShrinkwrap":false},"1.2206221455.0":{"name":"@bentoproject/date-countdown","version":"1.2206221455.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2206221455.0"},"gitHead":"0f6cdcebd462d3dcf580d8df0a7dfcdc02de9061","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2206221455.0","_nodeVersion":"16.15.1","_npmVersion":"8.11.0","dist":{"integrity":"sha512-guWSZsIkK/Y6LDMJQCGrgqIoItCnxEA5TXE+OSqUFji92IdE7d/jvcZ5h05i6hrOUC5hiJrx2LpEnmEmrCk9wg==","shasum":"d280116afa0843acbdf4ef95683089f0e96e9984","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2206221455.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEwPo7Fz5cqmQuyXWIA7LXVP8xUTXvVR+o/PncolEI0vAiAnuUGuCRmhVKczzyLMXxiikVbeLc7xLQ9KOxS4Elox3Q=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJitCPZACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrKGw//RKGgiKRsvrBTX/Ufn2bl6A/vrsfI9gPthK9C6XwI84jLO2of\r\ntJo4cFPXgba71+2CaZJ5LiZ/zWqSnWqiiQQoh1lzAMS7JCzSbEAQV8bTo1K8\r\n4yfZyY1pvhWnQfBYdJR+nCagUuFk7bP9mxT2oWWkhjKD5lv98PtwSd8EonMu\r\nEjsqWiZqcF05RL89gyBUuAZUpiq+h5gL1ciK2mbS8ywc8YtxNYR/tgVDpE5L\r\nROww0KMz+0qBY2ywK1AAjhX8MNeendT70bf401HOMcQurfmJN4ThycMneJ8e\r\nZTydNI0n8CSqSRdR7aCAQb3Tfj0XZKBN8cNzQsLm5e+xcSqzkbQPRPYuR9Hz\r\n+WUGMgcIdlwZUAsq/IGwSPS1aQEK/8MblXvubiaGPLVFeNik3ruBlcbMrif7\r\n5PaRGgOaaMr3APab9gv9Rv0ecR5Na7I+GXVT0rCMOwWPwMRWo0tanGhE8FKo\r\nru1uxNh+v31L1w/Sv1bH3StRZMrvW6kvV8hn/gjj05lmGONOfLnyZR22KGSY\r\nALFWTO7hS/nXyVjpz9dDJDLrUkb4sU783iUkXHjaW43HcwWfU4Rbx2vPIkxk\r\nA01YhbcCU8DIeCricYL2cAEKzgMKrOSh4gZNEJeUCH+rRC9VwaKWzcs8oQz+\r\nfb3y8oJuhOmSLqZDYAhHnk4yHoeZr4uIxfY=\r\n=WhIr\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2206221455.0_1655972825567_0.815078216116891"},"_hasShrinkwrap":false},"1.2206291614.0":{"name":"@bentoproject/date-countdown","version":"1.2206291614.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2206291614.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"34fbeda57c3cc9d01ab3c39cf9618342ec840187","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2206291614.0","_nodeVersion":"16.15.1","_npmVersion":"8.11.0","dist":{"integrity":"sha512-h5gQC8YKED4Xrs7+u+O5GZ5qJsZ/e6nH951TP4MuY28uaGNrfIWwUjKTQzKduLTyLkVFM56Xsb9zgnWey8lKFg==","shasum":"1b67cc32f359761300ebf94b829975040c252c81","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2206291614.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDZVDNB5A7N6I4NYpHwbzR/IHuylEHpMeYWyK/dF8ccrAIgKIYWdZ/jUdxxC2DKzRznx3ftQAv9TLAjrgFtIf35WRI="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJivcoUACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpHTxAAjN7Sf7mxAiivP+YbsvmQszHuet2oLbaoe0rLOauURM14PJr1\r\nIuiRxR6fXPH30TjOzIL9fxaH0u6m3HyMzIbuDrupc/dJOoDybELKiem2DKM5\r\nLEEprJijG3AFDTYZmtLdEgBxRt1oYRoC7nSpnE8g+yjNz5Tw4hRrZFNzPz7F\r\n3fdsXxHu+kJYRvNank9nC7VRYDZX0nQZSLs6r64RNlAWH+nGflYaRVQ980ER\r\n3yPIfZC8dLDb9dGcT5pUXr59qVxpK/ghuYrs8coYbA/VzOwWGpnttywoakTs\r\ncorE1QHzk0h9DlWhBt6ZWKpCOq+OBdNH+0Y7v7pMVuGKTF8/I7FAI022MvAX\r\n0MUgaEp+ipbFDgtcN+MLo1bUckCNBUkQspl3Wb/R6TgD3MdaN6tA3NvGCHpq\r\nvs/xgqGuFfvjBjTXaFfFFx/CK97uEYcyoLu8vNB2Q8tHACXYJ/zwbphrEmSi\r\nOj/Kc2BNraNPcM4OHkJVh/uXNSrv1F1N7Q8InUbPZn7LIJliGkZnUreQL0V6\r\nQeYrQ4Hkp6kCV0qybMtLtd1UnhEGItWRaMBCky0397zbHHgaQ1k9tILLcbst\r\nk/8s0bFz/vib9x6sPKYEpaU+hc73NjcpSymT7s/4FDGDZvdbKrW2u6dzjsme\r\nHLSFj/aOg04Q78I0uc1DOBjRoj0/JTy9tHs=\r\n=Gl4a\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2206291614.0_1656605203899_0.7569853553155168"},"_hasShrinkwrap":false},"1.2207071723.0":{"name":"@bentoproject/date-countdown","version":"1.2207071723.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2207071723.0"},"gitHead":"4ab5ca14023804a1af71c15bba775c5805e2085d","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2207071723.0","_nodeVersion":"16.15.1","_npmVersion":"8.11.0","dist":{"integrity":"sha512-wAbVhLs/9rabd/Xsh5/Ck1IOsvWmR0CK8rVTXUzp2lPcKYBW8IQWOsevc0G0j86EHCHGPAVlzfN9+ge1PHXOdw==","shasum":"35dfdfbba5e61d453b0043dcc7e1a8f3f2acd0f6","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2207071723.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCk3h1W1/F2223Jv+5pd/QFqYA59QY85mJK/DYrmPeBFwIhAMelCKhKpUFynk8wZQbE3Mgg125bV8BMfa8J6Y6+2hKA"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJix+ujACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoiTg/+I6SAlO6g6hEV6KjoGYdj0g4oVMEOp97JvJh/5ilCU2lyl84Z\r\nUxkcH51ezSfk94kB0gLTRTlE158FRNCRgVT+gf7xdLOdN0pVCZcvI52aR38P\r\nJ9QP+dhEhmGr62J7hZJMQwM7wiOIywWg2WiTcFI58r+K+tZtZkKqz63fa22B\r\nnO9uLlvJCjfGpWAkzptvqnqRX9Y+XUnzlCxV3c2ukiKsx/OFi57fufdAXY2/\r\npfjsOdD7/jhsHotgtS1KaM+5F7Ep3EMjKUTbY+2WPZBJT9Nszi+YNzto9/Pi\r\nd/rYx+/KratZ9jVD0KEo9xJJV8eTQBDZFSDiAVctqJ/rijz4oiffZbL2WES8\r\nKZx4uXXjcuq6iPl5lFd8NrAblcupZ2y4x0A7MPSnk3R3V/9Usobom/CaCvzb\r\nwnU8kfN2lAJGaCZVPr9Xz4XOSKlK2/D9AXVJc9WneLzWjc9wcu50I8QP+uKZ\r\nvjtnbwozZljMyLn2zRvnXL2oCCcWk9VsrGpZGmha6WR05ogRubg/XcSvSC3R\r\nJHlRu8HEg13bRg0S9j1ERkSmNShmTt/63QhUNTIBuXmoWAW28u81cQppRmtC\r\nAetu/X10DnP5aKohEbg/ozcFyM4SBy8d5BrMp/570cWJ8XyRUlfpzwNAOGB7\r\nHXYMN0SdZzrNtpNGsb7GGFKX2+b2LyKM2rM=\r\n=7mww\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2207071723.0_1657269155702_0.7921744739657925"},"_hasShrinkwrap":false},"1.2207181727.0":{"name":"@bentoproject/date-countdown","version":"1.2207181727.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2207181727.0"},"gitHead":"78802d83c6c9791cd4400e761bf22f9909218a58","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2207181727.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-BvA9fg1v0c9/3gIsKbDPsQiYjiGFkTaTO1HdjAfyTYdzHAVF+Nqsvd2cmxMyFWTpXiFZtG48PwI1yONQ5/fATg==","shasum":"e56c104878961d7e02dc6a4ee24f61a707fd5c81","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2207181727.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIF9e+WljiM/fxwnVx0OilW1S6th/ASfhgQ29MIiCaQcHAiEAkEqLIHK1VlalIGlIxQNxPpR0O09HrUlP3AWKFFuabaY="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi1mqSACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoKdQ/+LH/WzqF5MW6xRQbDaOCGkghKdQuw6Q3rZUISh9EM5arSq2dp\r\nzkn8dPYt9sPvuNfjZROFtS3A8gNl3D0CPldXGpLUeh/lPL7RG3veU8xkMcBu\r\nCz0tQxcZt4+u//SAncS8yqGvA4aVNVwpt3X8QbJH5eymzf7+lV+RAeWH/tdT\r\niKo9hIwE1U4X4NlO0wqb9m3ZJ0n2/0LPs7VpBWJgQyDmrV+fEM0iOOs/+tsg\r\nzbTU5SKlek/FVIcP++0C2wh9rR0O/t3Aq7TrlTK92FtU9tW99gd3hG66Ufwa\r\n8zwXT3/aT5dXOC45KCfCVxDgSKb+PS2Dk2r9ZaaQw7S7AuTfkROAT9cON6Vq\r\n+QowNEVV5GcfXer5GkTi2OxGuX3mIqg9fjfECeXpo/orJJAi8rEIlmot1ejF\r\n8tf2tXenr3QhcdNjWJWMMOkzWmEbrTpQlRt+NXe2tlUkCNLoW6LwpE2KoE+D\r\nCqjXrBNlWNdpdZNgqTbm/MgNh2nl0PE5Vi5yJSdff2JQD1GUYHuZY9CX6kfb\r\nKWdyzBG7MqsC2Xlo06dpt/bXhW04xBKR9HjgBXX3QdfFWSdBCce+tL+m4F/+\r\nHw/Xy36WVwKXsr6Q3GWBOuk0rSkA04iqtqP9CO55kHQGC3Ol8BWpl/pn6rcE\r\nJGTxe8KZUdK26kWWBwzBO9dtgedGG8NyuT4=\r\n=5ryN\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2207181727.0_1658219153793_0.5536411130878995"},"_hasShrinkwrap":false},"1.2207201724.0":{"name":"@bentoproject/date-countdown","version":"1.2207201724.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2207201724.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"62d86212e783d34fd2dfa8bd02ffb0e447c0538b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2207201724.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-PoC4P4qT5noa4IBBvlXbwPOUmHxRB9CZG/qjcLE/bIlkqComkwT71wpB8eeGwHOyDlSDhmzTpuu3CiZI+9f4xg==","shasum":"7aed8336108455468a063329d373faa8911755ab","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2207201724.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICuKcUOq9q8XGV0zloUYzWMI4M/koDxli7U18QHzxQyrAiEAkr0ow/JGbGntdqI3+3pUuCmrGKYjHpLpHaGmCJ/d2Ng="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi2Q2yACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqBhBAAhI31ShdqRhz/wuQvvche8fgTr0qLDCvYs8zXtnbQhUVTK6Zj\r\nci843QqDcDzML2NEqqABEMgnvaqEeYtGckJIhr7LUkgKsz0816OeDwukU0XG\r\n1t10RWpOofZSpyOZBGbmt+w/RZq+WnoNJYvBQMoVyBB3RepxIwTdqIu4327t\r\nK40VdY89ovloF9UtnU+wy0Y7Qm37BHKpJVfXKpjGU61i8P1VML9/py2oU40J\r\nrRt6kF/ZNp5OCgwJTVU7ZCdUNQJsSqD26rl264HU2TS5vlT+n0QQvzIQ9VVL\r\nz6Ou8J2bfNK56qaIlcragWqxQIiQ5HF7y9BBnHkZ7nYKbUflcap/B+J/pJWv\r\nimFY6TuEPHno9zWyFzwEXs8rr91EAdwbzlBzqzFjuCPr5BlNBS/b96LU9jwq\r\nk0McyiP6EPkXACQ2+l035fPPMXE9AIWtM0oXnvj/8vtY6tsItTvfMt4NENfA\r\nHTvmIObKidzlTsuf83vja5KMUu74zpbfnqNdPEW+rJBcv+J0u97bhFTVrEFa\r\nG/c9eOVpbRDfi3baXJ1PPC5Ekpwd/3mYZp8NNuNaIUIwFqrt3unpUJ5Qioet\r\nwzmyVF2V8nj+vp+PLnm8kfbbJgGNRno8wpA5Hc+WYdYTXw9vLbSj3S+tAjDY\r\n5nuthVqrWBYfnLpp0/oRDrTx8ImJ/7v9wIw=\r\n=vi02\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2207201724.0_1658391985976_0.28015821062851387"},"_hasShrinkwrap":false},"1.2207221643.0":{"name":"@bentoproject/date-countdown","version":"1.2207221643.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2207221643.0"},"gitHead":"83270c82c0130eff7988664c86a7482098f9477e","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2207221643.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-ZpO4FQ8+kGNfI4YYj+r26u4hwmT2mEI5oBTCniLvFwHWzAeI9OOT9BHVvMxVTU8GgGytWsxZ8o4NnGHltUrpdA==","shasum":"b7cb9cbe5161ef5a97e38525a48e5baa3fb96fb1","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2207221643.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAGSip4OZNCaa6/oIBDwka1fmBhOQuMTy63uTKcBQLQvAiA2EfPHbW9/MaWqLDlibfNyNWtWyOjJzKaO13P6y0Wb6A=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi27B+ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmpg5RAAhg7k3+fXp4b57oy/ecS6ANrfxo395M7FaylSV3KrM/5YnvuG\r\ngSmVhb2+Pj9OAToaHBvyARkmsys2d5t6/tPRFaDq0AtJDMc5RrkWv1kC5Z5I\r\nSCwnGfJME6NEtGiS7sh8wLWm/9A1GKadMerxRs+fEiyNTLT9YnkjCtijhfuZ\r\nvFRfEqunAyqlFGfflGzTBhhI8KkZ2ss+Dmc/Qz+/TbJ8flKDCqrXDs8KJ+gM\r\nQiM2sSp5hBb08Zu/6b8MDZxfB6bgGl+nTE7SAqBTpmqeqJ3qYguI9XKDSrIl\r\n0RfYuJROUbbND0C5LbzCwsgmrtcsqKOl2Si5QkZ62Y879trzmsV3yB+ZJzvT\r\nz5pC2vZTVmOsuzkksV3LBQ/kGBG3I0sFKPCSJBvVoXPWCBKXfSM3GEgvEtuW\r\nASUUbIHfd54tZiax4LFVlijQRKAKWPxT8eiBvtVq0LuScvnVAz2nVOp/8GOX\r\nU99hw7scOekg+ssz+6vZskkUYYvswQ2CrVkRhjpvAgydWqLC+3rId+XNHuiw\r\nuZsmP9V998JmCJC0C8WM9l8Ry8BU5X18MtEa78/WLQzRNLu0pclbduJpqyZ4\r\nNE2lyXwPcV+oG98G2IYPraR5KkdaRBe+xYG7KZ+rS0mJAqaI9HdsMEJYsCEK\r\nND9BgYPDzWG8JXL5NghJZRbHIIygB9iCwJ4=\r\n=WT8b\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2207221643.0_1658564734376_0.031964108696306504"},"_hasShrinkwrap":false},"1.2207261725.0":{"name":"@bentoproject/date-countdown","version":"1.2207261725.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2207261725.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"b73520d61dc1a279ec10d2a27f58891e2e2d5d93","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2207261725.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-mwauJWHSY3nEoEYR4rztzdentiple4PdtCYPbj5W+J/a6cgAeSfUCLMm8mbaeBozkA6Ogu0YmG53t6mpTxjksA==","shasum":"698af0c439306489635333d04eee309d2a8da025","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2207261725.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC3n9sBauWvpkOEtW2lbtFIcVodbWmt886QAhqKa189jgIgNlluZi9c0zGvlEeUuAmxbGye8eSdnTGYcgUqv/LdDJI="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi4PZjACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpSCg//bTXA3DKWbtpqSblxmwK/9nAj2hiWkBRiEQNN7U96OFMdjZf8\r\n48cMDQIUpzQRCEhI+t+PTSLi8Ur+VUsQGBOmYWxcy7n8ikWBaoImS+zU8KIs\r\npinEur3XFsSmEZm5JbHeYqZHZnXFNXl3o3bHg61Vlq9x4QCna8qZg3yANusU\r\na/kXXzTZGPBc5HlA8V92oP3nNeSMkgqKGrFWLYBTsj2kEYeZUgl/x55UoaX7\r\n4/+4ezE8hZ/9AVQzE9Of8EtvSR7OiDGfTXjj3a8K1Cw48F4r6c6bQiW7LU1b\r\nor84A9cLme+LK/Avd8sv8G1xpcBjFAekLwOIar2M72/O9ctUj6Y+/eE3bMqz\r\nJeusumqrgf2JqWB+3H09W+aDNnkNhyO6OKtqUgKsjaq4OH0fUeNlHMUbQj5e\r\namCySjnqIxJ/FdTf5CLbay/bDsQiJxjYQhTPn0YWTnu2KFgsHT9kUUp2OfOt\r\nZsA8mpJm517MYv4ogOlhvAdoHM6VzJeM677eXU9zhdbJp0tW5tHuic3hX7Un\r\n6lSRdmyXsOhHmfzjkXE1o/Q2rR65kRdO6Q+fKhDCFizBPnBFLfdDE30lcgYQ\r\njh5XfFkllE4pPiRPylHkFFnsqVV70QAjTOt+wTeBGybnbSdi3vr0KdNQfs/6\r\nH0T1cwaw83upuwv/KFkNPaygcf2hTZIyMLk=\r\n=Pgye\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2207261725.0_1658910306816_0.05677783370214584"},"_hasShrinkwrap":false},"1.2207281718.0":{"name":"@bentoproject/date-countdown","version":"1.2207281718.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2207281718.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"5e3f3eee6148e0ebb57aabc48ef987e9b5528611","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2207281718.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-oGoKpoDyGsdt3XlZsOt/6L2tI3axV5fb+MUohdU1Rlthd7Tbm1tLKG8VHkCj8M284gTe6BX3BRAiab6BW+hdKA==","shasum":"9feb6f74659f2ea9a5cf81eb6fc31c4361c7efa0","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2207281718.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDqRWZtyfCjid8lbkNG25rN1h8IRts2SGDGbJ7kwe4GYgIhAL1ZPN8rIQo510LewEDGBPxDkS+1dBhAy/FfzaX/WRAQ"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi45o2ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqfgQ//XxjSX88dqW6sBpbr3LW+3Z/cNhaSei3wQQNoSUr9w/LcYjJ7\r\nJZO0nYwj1PMn75O2vENRqNQ+6xMVqlPbGOQLblDENeIiqj3lA11Uerh5UVhT\r\njKWCRblURAp41mDVvHMiQMOqH4E0IzWRpdSocJimwg0fccx4bdsVWQI6WJTV\r\nVbjqaXPmoHQ1VFH+amTV+0Zvep0AllzCsZfw0VSgANATIc2MtvhrLU4Q1h1W\r\nY1GKfcqZ7eEg1qSY4xaxg5cEpP8BMvzOD97hpuTqmipMxm4D4IVcj6VfscRV\r\nxjXp1sJDJLktrNyln7Xnw2mBZ+HiuZ6Jhw/VwTTefM+Clrlkbr/GdpmLVKgY\r\n0Tv0l2scwEdFha6YZMJNAukuMlOTwcTDM8mcNWRV2OaOKV6HiWn+TdLiDrER\r\n9Rwf417P3NvuJ2ytFRGU3NKsfe9qFnR1S5f9sR5flXe78eTj0WMy19s3iKCf\r\nls97HAaJK6PjD7equ4nWeLmO4zeJQsU3Cn2KznoXWFIdQR/hjh0VBnKWqv/T\r\n6IihVWXBDITDq5MjodsbKuagbIs7o91xhjVLBan9xTTicPSDnAMGuNKJAppD\r\n8qP1nr6r8w7WCIndI3taoFhMKJhc9lYSunT5JViI0zNzfS1mrJG7JRxxyvHT\r\nnlyt/QDYTtREJUNPRy86qnft1fjspwa3KwA=\r\n=3kMV\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2207281718.0_1659083318332_0.895304433746414"},"_hasShrinkwrap":false},"1.2208021808.0":{"name":"@bentoproject/date-countdown","version":"1.2208021808.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2208021808.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"b82b832cae23ff854449af280f1b02f4dfeb99f4","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2208021808.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-4aQtyDFwFVZ2oESlO62gt+5KKkPhKFVWrIPhoyAufbpoaupJ0WJz7pACYXnNS+i5QDw7NQfClNLmK88vDNIOwQ==","shasum":"73ebad8bc6152b5549b5870e11a0055052e4cca1","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2208021808.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCATlXPuuHu6YFXveKMxn1dUws7JQ99BZPaDK+Id5uT2QIgOmDqDiGZcI3zbmptnGX9CahDMKLBjWmNsLzadh5U4Bg="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi6jEyACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqiEw/5AFbReEPs/MVODzAZ7pUfSdHJ+5SMC8M4WtQZHam/U6PYCz4r\r\nyHONJkEowBU16Oz0OZf+njSvQ/goSZ1bxocZAVwKqrW83nX5I8nNzgLJ2HSc\r\nC6eJ2Y3RXmUX+MLCp4X75GPIchVVHfYDczXiRgs5Qn/Zd89pii+MRTrDG02t\r\nwYbIi6cj1EZSwu7x1zK977q1qLaual4eKyxsgVEQ0+D2YggBF5Hv9W2DUequ\r\nG1LNvZp2iWJ8JGfSvHScBq1Iw4epn6CipDQGQ/UmHefQ8EfxXc+TKS6qBrMO\r\n+KebpB+k4Mlu2Mwjl/rfNo1YZrcaheyFbP1Od46b2N62Of6vQjCdZen0pcdx\r\n4CXM4C+Mwmw8gfuoyGPE13B3dV0VqTEm0pdWx9IzWGSyPnJtTbtwD7Bn2Nam\r\nwSSi4uGzdzg0dU22mblZDJwAmAu2CJ4FcxRKd/6RFWDL5+G629VK/vcmeCgR\r\n8q1iT7btyIGcosmi7c7BRxb4MDbGw8iTtqgc4ik4/IgDSxsTncuQ8nKJeMfx\r\nTj5MI6aYvwEb1pclf4C+QHZOB/rEYhkij587xuHpqSOoL4RWkz3JWK4nnIbq\r\nOFzxcldfaHQrmfa4qSj7/kTGxXMfVKs44UuVfPofcei7gSNs0X5nhtGxlTSG\r\nkX4OcjXQ4IkWVbuH9Zj2NwvpFHoTXxIZEx0=\r\n=3Kvt\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2208021808.0_1659515185779_0.8236291140618692"},"_hasShrinkwrap":false},"1.2208042017.0":{"name":"@bentoproject/date-countdown","version":"1.2208042017.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2208042017.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"598aa15d3922507a106666aca29a90334c7b2c05","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2208042017.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-uypJF4JXjiYiVzF1bhm+mRPmtWmLOYkvcCfIP/LW/z08d7vVRLehQRTyw+d08MJltuP9KFH0zrQX/S5OjsTGaw==","shasum":"7c7e937f3579ac6200b3aa7878514926a369fb8b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2208042017.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEd9eSk443Pw0Rgqs8Dyfh5xXRSRgAD88TUtXKU02UaIAiEAgGLC475wWnnr1KoiyFuEcgOf+9rY4Y3WaISpeOdMHpQ="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi7NSMACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmopTQ//VF2weHVPT5BC7lLDV5ommEAsEILxlfC/gqNusnnChZTN2/zs\r\nze/sTZGHBcyfXUetuDG/IORw+Gn2UXoH2hh5EJdkXbYUzTRMWKK98rZ+On1T\r\nj/tUTNte/oA/GBOEZ/zSpzgNuiZrc6gCnBV03e1g0rQkg6/enE6qWS2+/j6u\r\nS6ZHT/0MF3DBSvI1uVoX8OmdfDurR4TbrTRR3FeyCmltEmHZX6qDjjkBtfZ1\r\nOjrBE6CmPE4sAUrzwjKT1S5FwuNcU2+vAzpgdjKXEJpVXUvAue0yBD39znE9\r\nZivFsH9U2OzqpVedETIRHhog/rXzl+XUee9jMKcuz30fMQpABNFcX1g+6FZ+\r\nHJr0urVy6ksUhgEcds6UFF2GUBu9ZT/9v6n0PDaRUr/wbOWxVFAmqC/oeFwj\r\nLmkq2fDt1AOhcErIcSuRV+GrNdNIcwrbmMLp8AmdkUixru5i7B3D+Q7IuU4S\r\nwJ3Ld9m4RGkBNP4Jd0kDN1ZYKMGuIzQipaiqbAZdVWmU9bq5ROkrb9IWzMLe\r\nLaRFRLmsbsyAGHQ9H7VY7SWJLTgBN2OUXt30fMAdTu/muRD32efrOWlCnJ6b\r\nMoq9kFk755ODaCtayohPiTmDo3FhGFsxFIxU4di4oPIoRb6aaZGS627VUWxR\r\nat75RdOo8+i0dVXpkiD54L6xsPwOV5lpuZQ=\r\n=NF1C\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2208042017.0_1659688076474_0.20839040663416086"},"_hasShrinkwrap":false},"1.2208051912.0":{"name":"@bentoproject/date-countdown","version":"1.2208051912.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2208051912.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"5f50e49dee3435f3a242126437de7cc8263c2ea8","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2208051912.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-ebRONRvqzZl2JrsHMlG4DO6XqL6EfK4muKwTc9/rL1i0wqRE/drYq7Nyn9q0Koq7zLSyELyTvm9OPz+hKWKwQg==","shasum":"5ebdbefba8c236cc444d1909a07ff7d0f469df75","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2208051912.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDyTeX3sDpFpbOdLmbrclcs9XKds44vuYf7MuzeA5RRUQIgaCyQUghhWsBUY7BxFN3cGFdy3NW9Ux+K5yjlQbj0F34="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi7iXdACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoRYw/9Gp7wpoQsDpbQf/uA7U5kGfR+5x4u/FlAMY1/zW5Fyt8DMG5p\r\nuwBI5iNynSn9YGIbrSJjQYv6ORsBpbNCyZWAUE3/dx7KpqGGIBJqhCy4tG7d\r\nmmipuzQhUuwccmur1fd/SNCvU20kT/cJBQVlnlkqg6FX2FaAhZNIiheNRIkq\r\nsI86o/9ji+JsR6cept2v9SBhvfAZ+iWJ6UmKhMsutPG64CNjPWaDzn/YG7G6\r\nkk+23bQaWN3Q/IxsihTPFLO9CanNdOuQ8nI+i21PoXb8dQYgJauRPdo+J5yJ\r\nYfnrzSrg2dT+vjqYnFnZYh9IDNJ12jYp1RrirT/poIM2nAif/dz1BpJ6aC3x\r\nnzqmZRgBZfqro+5G69o84c+Ov9VChzpCEovkzOmwHHJaP1Fko0Mhj+pcnQcv\r\n3aOjVpelv9wf/qWp8Nq7PEXUHBKkSu+caIh7n5c9d8XvL2ot1xlbOCnm4jIS\r\nFRXOa5GObq6Jg4AQUIZVr5VgjkBwav+LLAvnqh3Khgk8l/z5z+4BoNI78Hjw\r\nHwbufST7nm4UdLABS3DzfWnySvaYWGG53BbORk96VHtQH6oHygXXk9gbQ6F9\r\nubVFZPPGGokxpaN4juPV/bHFpkhdj+wu43svquG6+jRa+sRRfTjf3QxuBeIe\r\nAGr5bI218orNoptUJj4TC1C8dTiMEwQ5ZRY=\r\n=5wx3\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2208051912.0_1659774429407_0.674068279120394"},"_hasShrinkwrap":false},"1.2208081650.0":{"name":"@bentoproject/date-countdown","version":"1.2208081650.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2208081650.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"beb9a33429ef933995a664a1aa534cf7ac0984f5","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2208081650.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-O9fQ0N6H84pgcDIKEEzAZZ2Vuj6yBAebRaN7s4gw2CNuH89pLuuZsW5/+ZHh8+a7IUL1dRbDuylDzjaZjBySJQ==","shasum":"9e5366a0b2484148d828f0d7abbd22d46f292390","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2208081650.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIC0filIIwCcXPz9Nk/SV7SC3AUN8zbIQDx/Z7Tpn4zN5AiEAmteIj/OrxLMMclWsq38kWUVwCmPWYUbo6/tGHuGzeD0="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi8hppACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmopJg/+LhOMS+PjNLE+P0/NRzqzfkB2iEf72fu4X+JMK9K/Kw6Q+MQI\r\nJwNyJ3FiqHdoCPvTMmTmnZIbC6FK8jy5iCJgN0Z7UsQ9gWsZQ7EX6BhffcMA\r\nyT+Akg23hVjG7bv2+XJlalLqzFwfoZpPFBPfK4NKU4P18KBwUsUqRWTHxh/L\r\nyHxoe3N5w9dLVOz9gNDO/rquRMRJVFkmj4B0NVjN8irYRAAYzHmqNCfHh5xQ\r\nQX7Po8r0yr0zRT2mZerqWpNuXOrJyAHjVtnuPnnsYAeKMGnNBAHG+vSbvxwn\r\nhT052icHVztr4eO6Xoui6qR87a4WAwLkux6cVdB3ju/JDIGPm50RVyZslWrX\r\neCpJ8i+7fPZRzZhT0N7B3sVqmuCPFciisKuqrza2JARUuIAhu6qdYY77H9qS\r\nxxaKnMm4r0gK8odVr0z65bPTNGFe5m7WSj7+3Qmhc3KYyocg+UptvGgpaicB\r\nLnqOY+YqCtegp3Xhr3ezQJt/iOVH8t9pWw8npGXusU4dgVjVZ1fULI7WkAa+\r\nyhgFEjg46FUfvqiaUmDpwHVz1fynFTCH1iLUsBvFSZKWeoMNopiM/NXexkYv\r\nSnrEwsG7f1ua4KOKyUniKkk8lPbcm5dupeFLxNz63Lwsk3n4dMhWYeKLV0aE\r\nnpMG/Kn806XVaUHRshgy9ti/W3zTUjxEdqY=\r\n=OtnQ\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2208081650.0_1660033641199_0.5671798917452109"},"_hasShrinkwrap":false},"1.2208092047.0":{"name":"@bentoproject/date-countdown","version":"1.2208092047.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2208092047.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"5147b5f8b54805bbea52be75a64d125a06f88aea","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2208092047.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-QMV0S1WDAh5GVnAOZOWtDRNbSbgevpU6FX98UiqnEXPEZov9rRYvgmkMnLtw/LF5ZwQ4AVUW/Sz+V9xL6sPEGg==","shasum":"4c1efde7ad39a7cc797e9f542c39d881ad0ccc49","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2208092047.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDUSOww1AQSjCexubAsRFIM/kCE0/aGa5kT8PhwUZ98VwIhANt3GKG6riN9vN6yCEOg46vdlHC9+aoqQQu/ulkR1riM"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi82vLACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqQ+Q//X8YpzmyIleaKtmNGTv/hcgUvv9HdxHnJvjRe+MesbtSOjz5m\r\nGxQ8D4oFzVxu11Oy9/jlmC60k03WmhvxL9HIHyR1Gx/6RL6pBUG+28JAqbMp\r\nWXG5V5QS8buFyfmJ/OTyJ/3HZBA8h5RRvrGa4EN7uIU/+TMhvgfMeLwbemPI\r\ntXAInq8eJLIlub0OYRCzgSyCghY/0tMzC+cvVUotJm8783426IgWA/tj8fZq\r\n1fR2rQ/xIcYZxcsNDMyY3eAElxymBrSirDxuXe/TGBN0eFTlG5FM864dAknv\r\nq1mGzzgS/nPtDbA1BZ7JxOvC602Ig+FwPYa0/V7zUeUBfeV2Y9n89ce7CJ6U\r\nHtZ2IgTIo1bUxvgW7JDESW7GxXmiWdTLTdQN6HIVIIE0/CumAjo455TWQnpC\r\nAqu+zRuZOHk4QORRfpI5D9L3XMislRWrj8tpPkrm6X8Anpgx++TIpkcieUTq\r\nUsg2O5p1t+RzFhKaPJSDYd8AwS6zW2jnJ+tPKT500m+ZIrcwGjl0X8Mr+Qbw\r\noG2ulRskTvuiJWr5J0oyyOye+QbrAgTBtyQV1pBgZ4WROFzQP2H1ZWliGJc8\r\nzJQvpHYTboPAl2CuyaTJ0bqFYUmzXE868xNA+O4K/E2IUKm61qvQObeWlVCf\r\nvhzKqMHs29QtwB5ZV3KMdYawvFamuSE+PdE=\r\n=2Mbj\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2208092047.0_1660120010813_0.04113926486320718"},"_hasShrinkwrap":false},"1.2207281718.1":{"name":"@bentoproject/date-countdown","version":"1.2207281718.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2207281718.1"},"gitHead":"b2cc07c9f0ea3633ed63866b9243ad0bc964dfe1","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2207281718.1","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-QiihMk/kmdstJioajV+mHA+v9OEeuxN3ngT5SxpFtk3I8yoXwwePIdaqIZQt6AK36eOitNm9Asm4dK5WQFLE3A==","shasum":"c95a110a96750c7690e847b0220af00fbf5af233","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2207281718.1.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDwNsFyIkyNMYJb1Ofsrl6OalOtBOFrk7EqTY7zwNNFuAIhAO72ra/M1VkohtGYGMvRGNHb75jLfSlnzfLTGB8AFa2n"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi8+NbACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmrfwg/8D3/HlTjsIgMCtvUS74gOvWJqp6Q7rZ90+p1bJqobLIVNEpfW\r\n1LmaP6U9Eu2WQzTxnIF2931s/ctV/DKnYLboc7W543Wz7bkhOpUBhYgDQ0hE\r\nfPDdMe+hgE/XogNTkKme1I8rI2Ennqhc9VCroIGLCsPoXX09uLKo2kqUFAnB\r\naT1H9PSZodTd3Rj6rFQvY/aVUB+s8i1iqrhGUPsGBOdZwBBWAEXpfCJ8Blw2\r\nd3Fabx7jFngcPUhwrfMZtfjiD0kE4qRIS1owVkg6B1Aw00AfotLKpX+yPyI1\r\no8VRMwmxnaIvZYIRBf+G3azn7+rtJcmIjklfLb8jJg697tke2lfk1eRZCFV1\r\nSDDux5tuD52heYXcGeURlF2r1qddCTnQ7k6LhaOY557mekzKbLHsmUWBXWtM\r\nML724GSTm2+WfGCXgrivpP/TjwzLzxVIn0SZuh0qw1JTvD/s9+XgUOR+bnDE\r\nXxJx3tMLbiy2j+p3KMyWGK53f+9+QWRArQ1+tydTO/0Dyo9La/3O0QArb0Io\r\nRM+wZnX7umVSaUXjnhQWsH4jU4jHcH9tMXYloULAO8B57ZcDZMlor6YR8bZW\r\nMogO2I1TGnDI5JpZuikBGBq0yfZ3JrFSh34RwHnH7lpmXlNZ+BCr6QjWjXKO\r\n5/EevUWdWQcCSefLC/zaRn6CLsXbZsyXeXI=\r\n=k+gS\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2207281718.1_1660150619033_0.4696998812200812"},"_hasShrinkwrap":false},"1.2207281718.2":{"name":"@bentoproject/date-countdown","version":"1.2207281718.2","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2207281718.2"},"gitHead":"b2cc07c9f0ea3633ed63866b9243ad0bc964dfe1","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2207281718.2","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-bi37UhQPNeWnlRJNjpVhgsYMCgrRp6bmONg2NYGVQ5DrQmdnm1VDMY/G4K7VzRT3dJdZGP6CtPjdKoEucvVW5A==","shasum":"c65ffb492d7044a0a56c4b7292e2dcb237c677e2","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2207281718.2.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBoX1zKuhlm+fhPeiquuHr/65yjaRSqL6AoI/j71XrDBAiA6Z3Jy3HBzMhiLIgLfHSit2BiP4pwRtzhKcb5gFDLmdg=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi8/WiACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqZJhAAmwqTF6K7A937RI1I5MFE4AlXn3BPV1dZzQK9RzxIKLSKscQZ\r\nTP9ptUbjudiJAP/y/L6GpvWHCLr8lIvW/DO2EDPcXNo2JKTrqZDa8LPHU34B\r\njQIGjVIewrpihzbxZT36S0PzZ266RWqKkPA3mQNKu1IMEsvCgQrux1SRWY2S\r\norQg56E5fXVYb7SRCckNOB1iUd/wwlil/zb0hm3WrZlUMxADm7fe4y020dAh\r\nu25rPTIFik9ZPIY4GGx21Rae8Ff4RYeF1W15cf4kZI/vEMaPrxHfLgaCebHt\r\nmTkSzWw5fWUc0/+754VxFuBovRCm80CfYMLRm3U7pdGR1KX5lqFa/d9Hv+qM\r\nBkhwaJI39ZhlWgYY1aY7lwdJXmr0uvFiNZpGix4YSoJKufRggkkd17tzAR40\r\nYUQZ2/IlZ3OW2Og9O37imj2b5l5X8OFUvHBip8R/WhaP0KHXRBNRahnDix/b\r\ntKHskRNc5+Ql/fVTXc6PTQJrQb5hEsSmR4OCN00Wa++odQx4WqPFvh5tc0D4\r\nuD7wIoaz5EzZ+SD31+4lrYuUt91/9e99Xo4S5mPnIdJ0nadsrB5qQ7EkMkjF\r\n2+DSOFrNIaPQ3qz8bkTbwDSPgvZ1rqrcVG2CREL0HaeTnRPc0Sfu15k6tLWq\r\niU8AXKuAKd78DiP7VFeuK7aIkx3txVMQIxQ=\r\n=hYtj\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2207281718.2_1660155298502_0.08627479103010494"},"_hasShrinkwrap":false},"1.2208112015.0":{"name":"@bentoproject/date-countdown","version":"1.2208112015.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2208112015.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"83d345ea27d61c78ced5f68848c4f342e947fab2","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2208112015.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-iyHiw4oZCo1Et/O/ODFwZHQxxH1J7JsjK7rO0PVK0l4iADn1zAJkA8mj2B7eZ4VHScgGkPzhCf98xfgGMvzBgA==","shasum":"35672db9a87c95abe01c12aec006f4b765a6a916","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2208112015.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDFwv2fmuEO0LenqXqIOj9QnmLOLeCQX6eD+fjOyLBhJAIgZr+35e0DCh7ogK9Tn2nWSrcqmX3aAgqJ7FbO6n2ejfY="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi9g7KACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqoUw//bfYJoQO2jQYvR1B8rqamm41OGd8odPVU9a19lTH+4q8VxOEq\r\nkqoSgXLwVV/CBC/XkJNm1ujHax85mCid4eibigHcH0AWrFBXe5NLXqPonoAn\r\n9f/F0WZjqR7K9aOCzvOcY+dB01ZQhrUwJ9SPbHRlFYgUhAk/U+VvCNhIGaIX\r\nEKlrY200gXLlhR/OsQyMsebPpnx/lf8bh/3XSd2in8TDbuJrhYbCL0wH3WVq\r\nPPHlO1Z1TvRcsx6V7FA05OrWUctePgphTcz0LFSuWadoF8dV31Jt7pBvJwaJ\r\nI5dNs/TdtCROV+KVGq7zS/G1krdLLbaYkUf36LTRdqcBaQMIBxmRghlIEOGM\r\nqRTOWVV10CaHNonUxkvFN8kILn961CfupUDGCncgZvN3zVHJj6dfMGYdUgEV\r\njoA+mnqhr0SCZPS2zVTr8bIK1MMYp2W+aHo00ZDWu/QywdMPparQrhxvcm6F\r\nmLGAxTuKYuR7v+1k0Wj664NjDxcaAxj8fU2p4Rv0ywNLDutMCxN6GADPjcNg\r\nzcou75GqmxPXhgbA3hVCQzUVRwqONOrX+3y5sSOMyVQbmfgpLKeUGNI/B2Fx\r\n5tAhxGuvbFRm0BND5jdzr9n3Jy335gSTXdLI9nlq4aJxCTZ1U1aH8SHR8tgV\r\nrgyR9bWrVjQXOMa632gTt+Hz3qm5CsQVMYk=\r\n=spYa\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2208112015.0_1660292809761_0.4155821062819627"},"_hasShrinkwrap":false},"1.2208121708.0":{"name":"@bentoproject/date-countdown","version":"1.2208121708.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2208121708.0"},"gitHead":"c9c6de085436b10c2fcf8e6c10541d6d2658af93","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2208121708.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-oOEunTMh8Hpg4Q9WcmGITdrgho9cnTh6ECEVbdYy71eQtmTrZcYHgZ59kYNJl/52Rx/4ZipV3l2EPKRGf2Fucw==","shasum":"c6617cc4ac3c2fbbf521528cf374c0e86d015692","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2208121708.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIB7iCl0RIdBPk7loEyHC6PT88LgJIRkK+PocyeeydGcbAiAQ6ZpMRAdGPqUb1LzdsWIB6wHdmMjDWzroetiwfwc7MQ=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi92AKACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpLdA//T+33t/qQBS0PiKliABj6M0H0IL0aKh3D3jOr10TT62vJK4wV\r\nCv9CQ+sHAqtArmXDEnmTiLcxpzQ0rYAlj78bG/4mbMLy4u5bIgBCDgsESu3s\r\n3uni5IrGOGtQNBYVXoG1tn78T1OFbQ3j1kn378e4PQf5FukxeEfidTnqqE28\r\nSjso11KwEmJVdsThOZWD+ZX6hAZ5VrWb6i2eWI9J89TLz72qdg1KFS8sAYAc\r\nqZg6/U7Kz4ssbWZx0wLMzdL6+xbrxmAVTGpvOZrvZ+N5CQSVLAytbXO4rICT\r\n4/JQH0ENPaXmRKprx5oUmLNKEhgeMKCpLQfFHHWJChbCcFHB6Y0akyJx+qkj\r\n7pcbpOJranaG5XNqyyZM/ynZC6B+X6sQ+OxLdr68jHPtgzg21YpMLhAGRUeb\r\nN5uTl8Cf0O2Foghw8my0S6fRYdONLdX8AOdJtpVpk3LjTBYVqtaXSCxj0l54\r\nGBOADbppo/2rGkJeL7qR2hSoFPn1Ydt+KR+5voBb5lswSafCaG85D9Molmzn\r\nb3ZRqIv/bHhIxiX5/AmwzDAGheASNF4Oc4d0PueZHRv4N/JjBG1+mJICC2Lg\r\nJTSoQSwKaVieV/f87ZaBoFq1O4E4YOtJ+QcIfuTFwlPUVjCzAfkL26vgODNo\r\nwa39vN0UuqjlTCpcTywC2dYA38Y0DxzJXdg=\r\n=nk87\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2208121708.0_1660379146259_0.016904091891203565"},"_hasShrinkwrap":false},"1.2208051912.1":{"name":"@bentoproject/date-countdown","version":"1.2208051912.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2208051912.1"},"gitHead":"c9c6de085436b10c2fcf8e6c10541d6d2658af93","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2208051912.1","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-Rx1N7u2x2AQvPm6ruQL7iVwkQY25OXTZZMhvDWIdKvz4hFWXlR2nWN45f4aaFLb/QNVBl9Q9sjUF8wAE9Rjz4w==","shasum":"434d75fdd5046e3fb4b8bce8bce7cc157668bcb4","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2208051912.1.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDujPzGzitdHusOD37GSrh0faJbMX0OUAmTN77Ppv32EAIhAK7WAy2HRFzSFmHfm2fYObSeWoc1YW5XLYfNDAlvOZHg"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJi/CJ+ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqSjA/+NQBEBypchj682E2UeCE1S8VDKr4iGZbnrjtqwLkYhvfzH3ks\r\nbHGdyrtTCGZRY6sseKl6FOdKOpCHJ1pzyxFxjDQyIce86jxpnZGIPc2qmEEX\r\nydF2DN4NCkqh+85wyU5YrRbHDEbV2hcnIsnDweILZPltN9S1Oz7l3LCLLBDi\r\nna8v5oWH7PTtLqwWio+ziI1l+VDC5yJhbQvZYTvTG9ZywICQae8P/VfvHyV3\r\nGoKo1wIB3rZTOKPLbGOgLH9iE/ZaYnG1Hu/LufhselRCrgTNxIfp6wWHSwkG\r\nHVZwIPosqL5f8bI7HHwhuunwOMCw4I0XlBIMV+n9l2nxj8XYfyIlXiLSWFPT\r\nQfZavjdwYaS4/nyxxZfgY2It713QrFp21PKRjbQwLdoLGfn5ckuBVccvSRQ2\r\nGmBRmSoS6dRtXabVu77s7/zGU18irv6ZR+9zBXzK+Cy0tIUWAt0OYslVpY1Y\r\nP0jJhyTwQ70kAddn8/GmsbEvMWT9m1EmDY1B/n4hShMdBr+xZ7Prup8rUzrp\r\nyH8A5WCEKqqfkm0zxAPuA/fgzSP013qRoM6au9/pKMuAEfdpfg/O0qzQ69di\r\nYRwfmJamoArBHWEq/QC8GhQsr2hJ9JfitHWudSNwEOnZF1HcxWJpokKycBmP\r\nlbTmeZ10BhGqLswOtnYn2qyDA1rFFKm3Wo8=\r\n=XKIS\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2208051912.1_1660691070577_0.9296564467638626"},"_hasShrinkwrap":false},"1.2208172101.0":{"name":"@bentoproject/date-countdown","version":"1.2208172101.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2208172101.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"372d5623dc25138bb97bd48cd5f97f3be8008658","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2208172101.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-Ly7KxESCtH2jMI/8uMEgKogGLDHanliPjLSWASSI+MOix4QSuziTNrZbk7bGK1WbtrBLfAuUccrASXJz9cfBnw==","shasum":"466d8f9a154f11df65232ed19715b077c4a57864","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2208172101.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGf4T3hPaFfog7w44a7FaRMrfhqzE0tMCp8dc95LcA+4AiEAj64cCkHL/NlJKl6596ZybSyals1rsRVaN+SRTLUCIOw="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjBpA7ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrPiw/9FldWasMk47OgpyKSnS8USh5lysNJpM5dJf5cUP9diBICna45\r\nXoQ4vX77GTbHVIfV4kJDb6QE68kPjHounNPOcSaQYv7D2Htezgoa2m43bIMo\r\nRVX6iX3un5iIX1indQaVZQQNi8oJEKQzd3fTfdYnTC4FMG0IeCpUmX5ouf8p\r\nN4Tu2UB+zc1o5BHWZgZdQXh5vqWOn3f2c6zJ2f4Dryk/tozBYCSzvKLN/K+Y\r\nNLGPFHxO9vU67+0M9yn1k909egMo/01TH+d5NSEwFqF7Ti8b2EYh7vxc7DbH\r\ncSkBhR7+s+suiO4US5i3It6uB3otMgeda+Suum65NdO5X65FWVvhvUF0qnjm\r\nRHjMn4crA5NM21EL0JCXEdqfBr8cpv9K35VEL2s+tpDqX5ZVuDNutKJ5LR81\r\nHKQ2q8TicSqH9NOIXOMl+bTs87QJ6Cdkq+0i/yNGChNmKkK0J1ahZ5x/tXMo\r\n1V7wx9aRu/LUOLQdf0+vRjDPw0ms3Cdo+uzWry4dXbVXydQN8mdnYrERUMZB\r\ndLRkNQPVNxQWQUnHlZcBhysRTHNhFM5MVE8rjAhh2MMnjWsfcQr5t10ikBKy\r\nyYVM1gVoGP+s2vTzaU5/UmDWNDqbFjt6v/XSRF/3mKwpCDthcuvtaRSXc4z1\r\n71g1PYGJ5SYOhiYmGgYNXAsxNGedhuAkuxo=\r\n=+R2H\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2208172101.0_1661374523675_0.1581984791828357"},"_hasShrinkwrap":false},"1.2208242209.0":{"name":"@bentoproject/date-countdown","version":"1.2208242209.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2208242209.0"},"gitHead":"0775e3db3f5e3447749a9de6b4ef38433f6db4d3","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2208242209.0","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-s+Jmv/ouTnyUKWY62PRYCBbP2JfkmXXqVlE7cTXK13himgjg+ItO1LvVkDO5ZFh/1hezF2nVuPIU/yKkFzWllg==","shasum":"8f140c2b69b75ebbb070b70e5d62a882480bf69b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2208242209.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCID0Xv1xpcdC5tySe1KewVj/r2Aiocg5sIJWxQSgFje8hAiADXUUSYm0gaDHz1oER75XJ3rN/hsB6wLOxHovF6yq1+w=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjBzIpACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrxRg//b7xcIiErWK9KFHju2dCQWe95udC4w++RtjRJR+WBWWWMTb6U\r\nU8ryUppqeHsi42Bfg13U3sjUna3SVp6sbRRfHPHBWK4XNUKrpiWq2N80U8T4\r\nCplbfo+jswwNrzpraXqJ3XUtJb76pFAobdkkmAZzFZjT5V1PBJ+RdKRKmi+v\r\nl639oB46w5q6Uh3bD3sl4/OOWOGhm/XOhi2rt7axiRtVojvxmzapUspJuWKs\r\nWQD4WZEr5R3v78oV1XlfQhgY0rxRisnM3mqjOWNE6x8l21VCWqFz2RAIftq5\r\nn6JGWbw0GNUjD2GroRScMLD8aCPLtpmnfixpqUbrYsQC7BTYuaOTRLIloCbi\r\nsAgYcLo9hQSErPOEH/BtFgifFh9kLFimOUdT672J8wAzWgFOTWCsVYoYVJJH\r\nQEZqhmEz3PRcIgYJ955MiQi2W07NWP9RPUnsi4B9cNC24giscoBuYl3YvEk7\r\nMn09Q9Ai+hiqPL8rGGPC1EDwimiNt7A6YNevY1YI6SFOUSZXpXTbdSrxOFjq\r\nX9iwfAnnqV9fVyUWH1+srEMZ65Uqpmm0PhxDJj1jug7nnmMIjkS8YeSypBz5\r\nZta/d5i8kVb9E1O+T/RO3IreFFSxBDVXBdgt6HjMc7LibiIBwlJBwUnE1/nu\r\nWOFF7hXJ49eJYzU4nM6yulXpn+196aTknZ4=\r\n=3dsS\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2208242209.0_1661415977597_0.09681478210115335"},"_hasShrinkwrap":false},"1.2209072154.0":{"name":"@bentoproject/date-countdown","version":"1.2209072154.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2209072154.0"},"gitHead":"b0743385edcd11eb02b6e380c4fb5a18793960fe","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2209072154.0","_nodeVersion":"16.17.0","_npmVersion":"8.15.0","dist":{"integrity":"sha512-UETR4nhzs0Lr3a13bDuSkzPA9aDgKiGTDq0fMXSQaCF4dPG2RDxrAE15w8qpCrCdr4chlg19N2wuDwH+sXtyXQ==","shasum":"1b7bbc077959ddd0330802c435427a645636f91b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2209072154.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCQwvXQCy4gdBLiYsm0H2JTIgog/zERVzzetpQaFrfu/QIhAIGVWDLGoyE1NXyk4GEqOqVf9u3v6UOBIw7rjcqAH6v1"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjGabYACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpCkRAAny7Z3mE0YFHrzCI0ZOvba0RvJeZoRvjpGO3jOyzPXUj0Bk6l\r\nAfYFT0dQgFf3Ham1Qq+kT0POch3okfn7x739BxtNU8rZTRomecY/XEqAm4kb\r\nFVBx3n8rzLEsUYNiRXDKn1N7dGm6ODLMf28KkvBvMtsws0Vlybv/J7F23wFn\r\nbdbUr1qJ0JBtkz2Pu415Z6iEqzgfHgFLPtmnUknH2FonWavF/tHOto1mAvf2\r\nbz8IghoiXsBdUO43btawyj39U0OO84ip+Lf+5mXqBhfZTCISBcPMHdJN7BmR\r\nGb+erWBEN2aN5MFhbHZU+aogku5YMcEuSlheCskDhxgVbXdS0rDgLq234DiK\r\nyCot9+AdYYF2pZewchIsQlb37zfeuE/oleQ50ItkU6/XeQh6UWkbuXZOS2n7\r\nWa9GgaBcmNUoPVkvO5YaTNYyeEUwrZYb+VK8/JhXn0/tG6ZlxCCnAj0JSkmc\r\nXdVL8FvpEqB8Y11ur0epnGTwjNQH5f7atqYzofM6i8yvV+48DcWDGrYXfVPW\r\n7fS4CuYh+6WWTGDVSeKntB0iM3bh3IVLIjkytCwna1fBJM45qcmzLc4Katg3\r\nNwQ2sfcgzhQMs6jec2XowWNoWhNCMhEwACgN368B+bOuwp78gtWKPPPb+ojT\r\nryS2oTkCUi/QnKqwv7Ub+FauggaQONFGt2E=\r\n=ISv0\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2209072154.0_1662625496588_0.5141653287401218"},"_hasShrinkwrap":false},"1.2209131909.0":{"name":"@bentoproject/date-countdown","version":"1.2209131909.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2209131909.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"b912a3976adc47e6a81ae645cb98e51d1e778150","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2209131909.0","_nodeVersion":"16.17.0","_npmVersion":"8.15.0","dist":{"integrity":"sha512-VMqy/5/p7Wh1WZGcrsCDGDZo/+5qPWlEsZt42ADOED3Zzb7+0VdwzMq1begsiySsWKkE+lOKlXMtdzISHWlfUA==","shasum":"bac96938d66d84f453aef80241b32da59f764c8f","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2209131909.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCIKeBlQ69tCa/xmM3x3IMFoYO8lfZo8P70YB/A27vAQgIgcEz6qJdc5xFamm5t2G46W5a92CoPW8mUxuLw6UTsisA="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjIZQzACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoejQ/+Jqc0JI3iP3F+HUK2KD37Y3SiqdQ+zQDkzfvwYCqLQcooqlWB\r\n/ZQn5Wq0pQAfFWx/DEwwD5Ayw5+b1ZQDqcA1Ve6I6LCEYSHQ0rCJNLwmQgij\r\n6elAvlYzbROVJRyX8CPazvSlNhAlnlDkEL1Y2vxqvO4TpM03eLkMGDsLCwoh\r\n7X2KCj95dYOvX/vYHODLDcoSuBxa26U7oeMRyBmL775kzeucsRmeJ9CYX07s\r\nsQ/0KsF+dK9wl64XD+4vwOYYvevePqrIsy6oQlTEdPusEuHUzuZ/qfZro5Bc\r\ngp2HYMFHpxT6+8zuw3Pcn8ULdG271AuDzn9/2T42v4EeE4CVG3M/pRBO3Tmm\r\ngPIVG0G9R8wYkJjrlHX2xV2SFmMHuXFBXQbppnEBSig3PGzU8evrvWZFBwmh\r\n8e1sycGiJ+ZMalXyCiJb+a2vvK4/iOvvcrpYmulfAGyurSiBDjVVRryqs+/L\r\ncDCsfkiE4IR/lvc+Zl4AdcGyTQKZCXsw+dh8liwHUX/WSD22TrFDHfTmO6aF\r\n6aYlUVC25x0cq1KEL5uyG4/zqc5Lr0Ji/j6pImBMXX106XkNF5S+3QqLjn16\r\nTeSgrglZ5Yxf3MlKQjr+POe4tuhezvpvuQUM36hyrjLzKtmwgVxP5leq/MT3\r\nUURyeKd4/ulqWIgKXlM/ZlUTEFKo9OlfH3I=\r\n=ev7F\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2209131909.0_1663145011502_0.5660053006706365"},"_hasShrinkwrap":false},"1.2208242209.1":{"name":"@bentoproject/date-countdown","version":"1.2208242209.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2208242209.1"},"gitHead":"a64b6c7fbfdfb75c935b112118bddb3fff58ba57","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2208242209.1","_nodeVersion":"16.17.0","_npmVersion":"8.15.0","dist":{"integrity":"sha512-e6j8/y1H7EXEpC9SBr/zoJ2NwPJw/XqSwpPC99XCdrVkDC2xgE68HGdizq3Kyb+R97s1nFf7bfPUFHkM2OKiVg==","shasum":"f075c2b7472d70534296d487a806974995cc8a5e","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2208242209.1.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCA6hQ/xgryrL0e/Kc51xVGvqE7VNxU2nidnGn2QN6MFgIgL6/3BLTzO1VsSMwI1w1cb1fvBhc0VdEhVTHsYEf/8zs="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjI1XpACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqxVw//QIqU5PhQW66O7eOrepXI+QRXAX4/vWDpliF2l5qS30Bssd8z\r\n88gLzyRtJEw86dyI6GrgnyyzbAxXYurI7U4cK/a+OqCz5We/Ga2iujm8VYxi\r\ntgZHfR9wmYKDtDd5vXt49pccDxaWKtAz6j6ox40+BUi1whs+Q7h7Pv6y5Ogf\r\nnrU5VKV2NOkMAnaiPuiOISgSwbUXK+NBPJIqs4SmWpaxu2ITt31BW0nHJyh6\r\n6ybNV3WTaOB7beA53oAmmH5XQS93XI9vIvP/0zuyKaQsgT8cvJwSQ8Wv8Czu\r\nP+YV9iuxWS9ZEYoFU7j1bKkp9qFkjUQO86HGQyW1M8FjkzgsA95cJFNiP46I\r\nHOWXNo6by9yKq69b5nkpiVuVOQ6XBGVpYQs5uw9MSEBlx2gJMbf7GTBDtSxG\r\nfxS4Zzl8JWx6E4jC+onHs5lt/jQiX7a4MPUnnQXuFu7hgK8v8JU4D7MSOX4r\r\n4ZW8pWatBsvjoRi/EqfJR5w2J0FfDoYnzfcW4AJuPjZl5GDdNRz9knCaWcnl\r\nkylwWExxqTK2a9EAmGoN0Ip1e89sOcM+c+cAht5yzi9vkahPjPZcp2UO4Fxu\r\nvWphHEba2mbK9RM/gnwm9haXfj6xFZURWcn5zVKIQU+mZsE4zgfdpATJ4gZt\r\nj/vVjdl9byQx18VIYMqIF4Afxi1QMDyalLE=\r\n=3/s9\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2208242209.1_1663260137148_0.47633469560430863"},"_hasShrinkwrap":false},"1.2209142312.0":{"name":"@bentoproject/date-countdown","version":"1.2209142312.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2209142312.0"},"gitHead":"8484b3b1dc31fb138a231b2368acfe2cb4eb913d","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2209142312.0","_nodeVersion":"16.17.0","_npmVersion":"8.15.0","dist":{"integrity":"sha512-EgxMFNJykH5FCd9mKRy+GTN9HIZUzRdY7QzXA5AKBuN0T4qwT0rXsw3SHOSKP1ZtPxhTjOF2I1eMbwq1+dBggw==","shasum":"a100bf0f75486b687654c39ff701dd176860de07","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2209142312.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICU5PRJuzaiGr/6q4WI4ILcgXmm4BbX3vuaFUOjBhPlIAiByd/p/HQealbfPNRCB5ensUvx9MqdrJfhNeyzNU0UuGg=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjKjl7ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqQwBAAoaeNg1/OcyImTBeXgzHh96dpoRt1Zy06+SlAGWw+hV33mDyG\r\n6l2OVm1HvkmCy8PgKsk/tbChg3rIdcL5ZB+nY/7yfSxuntQ8C8sB7eMmHuz5\r\nYzJve5G1FQzXKE6ndWikBWQvgVBy3m80anx/qacejdRWwH3XWXCd88U9xDS5\r\n7PTlrAFMub/mkIRZWv+g7oWz8VrFpHhS96AhNImuwJA0S184SUD4h9U8AJy6\r\nsEIdEavAdd2MiqyxPDs3VzpGXg6TuMffce76w1RHYyLiVjr7NN7N9C2C6Cqp\r\n4MGd5BvkCJreP0kT++1nXPJ9kDg8VdRTc7Y8K64vmV4aT+nYRt0OSuZ3o44q\r\nj4rFdKF1Ve2zEbg2rqIKKU3xBQzPbb6CHbgBWanLP0DT0wMtzr0GH6/UmRuY\r\nfqkGT0ilMwic5kB6g+w38lx2EK4H6zVyHEW0e0kJihGiJJ8gLha0aV+NM+c+\r\niaajRdkkhpvb+01HjJ8rFlPGaxz2g4LwDASksjF3QxRz8ZaZ6Q/XEU7Tk5/v\r\n0w+lNkc/e2bmtx2xVzxrp2EyZTZuROQBNVTJXT4ok0hk+F+dXRTNjgJ5MIqn\r\nEtjTM7YBCIqU/mUjWjmpxlLkJrjiIQiAQbG6jn8SRsjTlVIcYwCiCgm5+az6\r\nWGVVsFXcen/uX7+3QPxFQeutZKg91JNB89o=\r\n=vXPf\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2209142312.0_1663711611298_0.5146714582930403"},"_hasShrinkwrap":false},"1.2210010655.0":{"name":"@bentoproject/date-countdown","version":"1.2210010655.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2210010655.0"},"gitHead":"b0c5acce5be2019b787b6f4bf7feb13b045ca7ff","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2210010655.0","_nodeVersion":"16.17.1","_npmVersion":"8.15.0","dist":{"integrity":"sha512-bOEhUkPDNEPd4/uTZ3gzB9wemGbFPSAaMV7TtzO78JZDkktDR7sFjnIy+3xDJv0NMiqS8HwFQUGZSdaZwNN1Gw==","shasum":"c4865a756f354f7f86de137db6fc212b6ba3c0b7","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2210010655.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHkLnJOL8NAuHu+sT7IDkdzNOJEDh15ZGc8CUC5IY11CAiEAzYt2Hn+mNLLB/5hVgyAJBQnrCfq1AxjL7g9bgWaI8SA="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjPGPoACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrTDQ//atu0n6S7shVBTRQTwn5D/mshVGm2Qa80cJUFMsed22FY3w24\r\nRpNhPHlT2fJ4v8sIrjWulSHDR9MzUON8++Xw8yj4psRSAysJBVrfUg/pdwvt\r\nzDSvze0BLc/7WPGRf/kwNZ5HMQpIDMd71dO/cWviJ/WjvY74FjVqz51T4E2K\r\nAn06fyJn0u2KLVspkqyGMNMEOWbPaAV7fvxWoonlwQDP6EqCTTBZQVp3YTXC\r\nP9AvpFoj1U580bhMPIRmIWYMtLEcldKpClW2X87Nl7kVRH2Pt3uxL24yJsFe\r\nBS5PgJx+fJk4DYXInbctudTFhrgMk+q1eC6lXUezpFoixV0ip5UL2CG2mezD\r\nAcZIa2dUho0rWUvHtOVYo7KlLaHrieEIWBWqPyJ/66aUWcPfqhmSOdIBKpmX\r\noalB+yRZgZ3c48aEdd7p+P8ObMD5RTzZ37rp/H8fDFS+iJpLIIK+JCZS8UU+\r\nmzF24uaa2C5t8JaopI+frkrzr4hMuptra+l13CK1H6UdbRALdw3dv2G4ly9o\r\nQJGFc391AOsjIaLxsmxJV6SE84JjIz5OrXHe6OmM36gdEozH4Kr8GzuK4h1Y\r\nJtCkyPr1/iNSK2hS5IDj1BVOf1vWASxXDLDnOyKz1LWesdzNagTJUlqIK0nJ\r\nI1YFkdOIQvdtdvJn1538HE802aB2r6uEERs=\r\n=rcx4\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2210010655.0_1664902119954_0.9648547468230029"},"_hasShrinkwrap":false},"1.2210041838.0":{"name":"@bentoproject/date-countdown","version":"1.2210041838.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2210041838.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"e79aecc1c4639b06a7f2843d961bb14f293a53ce","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2210041838.0","_nodeVersion":"16.17.0","_npmVersion":"8.15.0","dist":{"integrity":"sha512-B66GYmx+jIOdhkXwa5seH8+2AQ3DgEiGcML1xBenI3KyftW7jb9yORkQS6oVH34HBYMCHtChlxNZq4cbO0rpzA==","shasum":"fba28bf428803126b229e16e32788a827fa41e1c","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2210041838.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFWGS/R/X2rMcW/AOPbfln2rUuXP76G5N1kxWUPqOzl4AiEA4SXZSuEMi13WXAcdQRmF3DhtnEnlpDS6GWvguNVc6oY="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjPUBnACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmoztw/+O4XwCDJG0eufahAO7zf9/zyGFqWAbdpKnNRjR4hq07QlxDk4\r\npKQ0JCQK8jRamC1He0Y/Q/RbLUrePf6UUilrT46bdFhqKUTO+F5EpudcnHPw\r\nZd2dfB9boT7/7kOhNjMfzla6vvwD7luiF84BkdeG8eRz2AVm3mcfIYqEfpih\r\n1NxgYQutmgmiUnYWqYBkimQ12BQhlWHDnFZEugxKwT/jbqoO+Cqr8p3uRiyE\r\nV+tT2mNjSfwb2IsTmdn4hPoAbEMhzVOSv8+TA2JhkcRGpbSI/45rvx53eyOs\r\nF83otJ2rqgWoFc1/1zwE2RPkUZZ1+3A1X6i5egwA9oidJOuOgdLMNbbxFLwy\r\no/0wyHzMalgcDKhg1iDCFXSpBFCzlSoz7BS39YE7z3xSN8ZFgyuMLRkjx9yU\r\nkuP/Is0EUHmOK/J+2DygedFub9OiP5Es27i6wLCux/z32hb7tGlamLdxbDEn\r\n/quo4xzx592JNN0Fvu163On7Z1fS/q4xRgZ7zNnsBT2u68XOkYNiWhM13HWw\r\nMsKhvjNT3lmCQIsBbKpCh+XyrnC2vRXjQRjD8TyOzGk0Pveu+gFswQc/iVm4\r\ncG1vT/xvkBSpiKSfbSrhdIv+XJis66y6DI/xzuGRbkfaBV9l3jzsD4f384zk\r\nqnmwUmQz/XuTcGPa/HWaq7hvpMUCG0icN2s=\r\n=g0JA\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2210041838.0_1664958567763_0.8260104571016369"},"_hasShrinkwrap":false},"1.2210052034.0":{"name":"@bentoproject/date-countdown","version":"1.2210052034.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2210052034.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"8a0a0067f57f89d0566ee1db3d4bfeea072d3c56","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2210052034.0","_nodeVersion":"16.17.1","_npmVersion":"8.15.0","dist":{"integrity":"sha512-fwV1VEsybw+DVf+fLjfkoW/VGeS9gD3NZUsrZ4fGpBs0wkq2xRueabGmeK2AL79felhL19j89vB9+mGO+TBWSg==","shasum":"d9fbd0fc3150f50555aba2f8e96bd5e699ed1efb","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2210052034.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDxQufdXEh2xFfGZP/imuM6dFHeun4VYJjGg9sAgiIn2gIhAK1WLTw8yYntPolxucfHBvHKuBJFj6TF6kWaFxTo7j6D"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjPpDqACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmrsdw//Q3H0dz1M4E8G1IULSHYGzHAjiNvBi9M968Rq4m7WatrR9yVQ\r\n/Wxm9BX24n3dJ6i8gdXJHKgRP9FNjkpqCjSgp1rsVi8+2YfU3Kp9QT0qBH2N\r\nFI6Q7epGPJL1UF1iE8meXJI1TR6bBbxcd9RBpbuh6nbs+JBoNNYh1gqfEhzR\r\n/8vvF+V5pJmVpFGuttCtSfZTZpUbkWr1SaAy6YipAoyrNfGI9BxVNea80sSJ\r\n5biU0lvG+aB7yzzbYe6VJgh7d0w1j3F7bgXoiZy/0PLdHLfrcjrD5AZDk+MA\r\nYM9v1MKmQySD/tjGCworl26A+h0Hjl8qAHEdDyfyAfgzhtsWb1LPJ4fJ/2YR\r\nHhICwi+HLce7p4HjC0dg28O5BjChTVYmwbnNkuwh1TfEdm+4MRjSeNE+mZw6\r\ntw2Jt3zI0Wizy5uU47Oc3lhjDTpi+0j+O6lPch2VgKJ9gCc7xY/bxwXQmcOg\r\npabt1Dhuk8M/JWl7GYvQaZt7uYdeyz4El1IAbi0lhp4My+JRYt6kJ3QGltDU\r\n4WIqPQsSil5AXp+O2Q0t9DQO7LjG7ddHbCko9XloR+7H+pDKM0U8KyJXWow8\r\nkAFMspbVZk0n5P4DXjImlAfo0Teoa94Un1nwtgWPfTg+jxVJGwsLjxssvuHB\r\nf04c3C3/uLd5FHkCU4cuk01FlQsX2CK5heU=\r\n=E0ui\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2210052034.0_1665044714326_0.6809968094065131"},"_hasShrinkwrap":false},"1.2210071758.0":{"name":"@bentoproject/date-countdown","version":"1.2210071758.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2210071758.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"7c969ff5fd5406304f6a9867fa0db59b74e94524","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2210071758.0","_nodeVersion":"16.17.1","_npmVersion":"8.15.0","dist":{"integrity":"sha512-q25nWJ7z9YZlzTAYqr+6YKC+Xv8w6gDTURBU/ay4zeipxlCmMexhNd625Ta5DFC7hcH7JKc1UaaM5Bh5XDlsXw==","shasum":"c9fd72849adb991ce21c7c8b9ceea8b960f0f6ce","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2210071758.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIArpyzcCZ1Aimgs6lkWjp3eG+cQ8WMRDt+P+JjWmBJMgAiEAxTsFrx8RDKlr1Q6hBZw4dNN5EQ5mf446+Z/ELotzSmA="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjQTPZACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpLBA//UX5MKcLDfKfTySa5/wVAb+CqYjHcPuR2PIknroP3xyOF1Il+\r\nyzKFKnpow0S+NAd+VTgJrf/XoQezvOwzE7+pRZCjqZfVZRx/PQHP9dloaqH3\r\np0kEd0U7sGvsXnE9KnNAUzuqmh9ht6vyTIy7i2VpdcZgtJXXeFbhsSuyzpJ1\r\neYrx/qoRVozCIMNXP8/1sHEBH2XoNgdz+evCAIGjN1QVP/4WxutaGsJ7PuXz\r\n6s5Mk4KCp1Pp1QphYhiz7U67RHeEoJCNdnREl5UsYljkN93TCAYAtqcTwAAe\r\n7LzLD6QY1gcPY5AksnmWMbkDcwiPMdE0P2aK0qtAMnM+1B/lYNut59ji49In\r\n8hCEOLBOfG2euD8KIEHvzDnIqkDYQ3Ej4Z6RGxu/VTWrsXoYAYWu/DVNx2Rm\r\njbsU9KwWfhdjZ0saxPs8DSV9r+YGJonKAXkQRmyueEAtlSm4d4SY3ij1GUP1\r\nkf8/vp9GV4AgV9nofG98opnkblZwYl7gxySAtdXoi/Hf/a6bRZMBtCMb0MMJ\r\nZcdHrxMQ5lkDV9kJjsr767Hee86YneIqR/qHvAlczPfTsB0X9yW40Wir1Q/m\r\n1/ngq2BncaDiPI0DhcCKtvwcIpvgwHA6cN+QxYjEZOT/XJzhzVAB8N+a7/tP\r\nc5xxCjx9YZORzQ50uUuPFiDe0pxyTF0xnek=\r\n=zL4f\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2210071758.0_1665217497088_0.04235390703284714"},"_hasShrinkwrap":false},"1.2210112333.0":{"name":"@bentoproject/date-countdown","version":"1.2210112333.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2210112333.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"1d82bae06844d5413aeb632cfb2f3ef443548ad0","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2210112333.0","_nodeVersion":"16.17.1","_npmVersion":"8.15.0","dist":{"integrity":"sha512-4ClvvxJTSFI5/RcYO37Yil5CPfav5uk6utaHnSMFW/FiRLRSUM0lDXCh5ZIpWdo+GQJKeqEd1dy11sI5+8/ITA==","shasum":"fd14d62ffb8b3b675d47dd8e6ab4832d6bd7f237","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2210112333.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDKh39/B7TD21AnhfNfzNDS4X8+xUmdcSJDhllF2ZAGOgIgAg61AhHylVib9pn5teRE9FzebcptjeDPOjwQbZsutTc="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjRnmzACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqW2g/+NIXoXm4ewEVqSvdidqOb7V1TZVYSpgoEjE3tbYI7JCPSJfRx\r\nA1xDKoDpm94V/xI6dB6od2QMtZolMBK2aefsrIh5qbYQHPpi469Zuqigvm+z\r\nrjX1bRhG5XNoVRNH5Cbq/ZFAbVZsNqarYiuU9feDF+FFXIPjD2BZGn6z9B7H\r\nGmTnOA9B07n0xJkUm3pAmZAo3S/7n7ixOk7k7BpX/zbyb9bHv0end/rZFxoX\r\n8+82ez5cqrIkI5qaivouRrQOGKhJKmYR03NPbBKl0yP4rg0uHDG1NJRnJw9M\r\nONzU7TqfI6bBHxat04o8lckfc9xcfxVyOTMnhfkNJM3Dn+gfArb6w+T/QyxP\r\nciP8Xk1ghCfQjkDLXNO4A5/nJ5mntbNO+NQbHis11q3lbF17ES6XxxzD5vr6\r\nwXxS0SVmdQUH+nd8tAsH8rP0hh+yBTmZWZPtROhHz3sYqLWLOhWTVSIuhQsA\r\nwMjJSaIRCuYF5bXknSN3wtcik9P9wbEOOq+EbtotWDu7g/7jjCtLYy58aMH7\r\nbXccRE32Vgnwpp4VX5qsc4jHDobd1GQSXRH4Yh5VQlzf+iznQlrJwd3aszTq\r\nxXxJgcOBZrMBy1lSqbZK99iK2+akLpvstL4y/IfkcVOQYQqiNexk7ueLSHu7\r\nHAhpHBMzEIzNd7q9bS056LidTHFoUBxGfpE=\r\n=bOTk\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2210112333.0_1665563059763_0.7091007648753853"},"_hasShrinkwrap":false},"1.2210142102.0":{"name":"@bentoproject/date-countdown","version":"1.2210142102.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2210142102.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"4cbbe2b23e7b0c5b0c005c94a574ea48a45f7693","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2210142102.0","_nodeVersion":"16.17.1","_npmVersion":"8.15.0","dist":{"integrity":"sha512-lgmooNl83wzIRdykfmiDe7TZ9nWVOrpmtQpjduYXC/XKBNqXHty+ChwteB+cs5yIJbCl/p21d5yiS5S0po+TcQ==","shasum":"a2654adb535785414c50c7f53dfa2a376226e62b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2210142102.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGKUwL2pFZ+XBkBLSIWMzqRi5YB8izdw51QuoARHAq3FAiEA2h3jOz+KgY7YBi0nCwceN/c4H7AbD3Ec6zPxEtQJ0bM="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjSm4iACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqTEw/+MuZyzLzuVf3E+j20X/vjUw3+3usUNsbO0EXpbTNHn92Mm29j\r\n8dta/nF6cd3tvQ6sXC1yaiJRgYRlCna1zh9btDPhAioOAjtzblcjUd+xsj2/\r\nN2o+b31NsiyIK8n5ut9F1rq3YA8UYVGSm7VUDvYBds3qldxoE5NRr0xkX/z9\r\n+P7koHDZFyqHJ9LQd1qLs/7Pyk7iuSQuQt9XJh9mP+h8ZuGpKljoe6HC01Mb\r\nn6mOzllMOf3QvWY5KUEu3dXUWqXvtolaOIrkyNecwKeD/3zJg5r0n56uL189\r\nOhZ97JJiiBXeNhvDNHC2c+L+xj5pABjHIhpi5wjYEnPIdUxYRFjK8qs1tT9f\r\neZwv2OaibZbImfXWy+7MPfkYSGW6qlelWxVU2Zew0076RJ415O04hpmtnBPY\r\nSW7SkSVGjVjLG3145es18ILdT3iqefb/i3IlQmX8BMok3A0sm0meEQbJbcT6\r\n3YTisVUdKVqK3AqTzLiFMLl6aH3rcj3VoIrQxP4nJN0KAixvZefcWn33aHpz\r\njtzpjjqEiAgJ6ezMYpx8V0omGNsEAyw4HXp2SEFGxVBJf12uTJaOqgWtksBf\r\nU0wH4BUQkECHDjuHrz52koERXEtSXWHrEkmmQi04Fe20CoiPmaHlsVTbTFa6\r\nIFyg/C6KGzpb+95mtTnnQ3nk8bq+jL8loQ8=\r\n=PXNd\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2210142102.0_1665822241883_0.7873655958857935"},"_hasShrinkwrap":false},"1.2210172057.0":{"name":"@bentoproject/date-countdown","version":"1.2210172057.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2210172057.0"},"gitHead":"fde225e8d98aa5d96a939351e6e53cc7abb13cf6","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2210172057.0","_nodeVersion":"16.17.1","_npmVersion":"8.15.0","dist":{"integrity":"sha512-BYibabCvXvziCw9oN1oPj8WpWp/gsFAUjIte7VXhgdDVVGwpqoMVQMEwvLu/Qjh26Dmhmwb+MSvSG4g4zNFKZw==","shasum":"99b62c1ac7e8b691814d9fa7e2f61ec1a4f4f1aa","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2210172057.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCInME8p8alWnWFnaoTfVrpakxNNa570aUUPQCqXpXIigIhANSCTCbmy6dsareOhP5lHBuDIlK/yRC2bwGnqsVmemMq"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjTmNEACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrspA//RNVCFO7ao5giQi8b6B8RwnObeUx/cKZ+JhOe4sEW9Mm1j1Z3\r\niGEI3tKgOMbyGScHquDGOJuqBFeLLu1Pg3eqCNEja01mqw83kN0dAWJ6RZ6a\r\nyYaCfPbCDrFilL/73SCieYKPloVrg53Iq4f1wrL4FmrG6WZs/oftUwkhCco9\r\nv1vM7zDeadYXBCTPeG1FzySeHeAPmHMTgUhzEZ1xc6AHPxG/1ZGnxk/I2OSR\r\neUZU4o407CtjJEhgqd6OoKHk0f/Ed8d0Lkd3M9LW+2dfSv3GPn5ehtnvsV9y\r\nPRy5M9cUXyglHX2HDvG7VGvJD2TT7F9qFcXEb73uGS1d0RvaYRZI4eK4pR8g\r\nLJD2VUrmtFF5hIvBhy40A8hVksd2peSfFanZSs4WneaKzHd3SIY57qpX8CbJ\r\n+nhm4YzmJ6nL7TMmUjdsbA9FKR1F1nx4P/bEas9aTrxNB4gHkeOKyuLkgy/y\r\n4zTKuRlQrXFUsxWlp3jNF5nQ4NuMrjPTPd+8SD8t3B/Hr8SNT+n4OSNCtORS\r\nZ8pG9sys+lY0uo7pJyXhm7Tsa9YWkgAw37Us3PurmNgFq0UBFT5FJJghrj2j\r\nPpdxMxy96Lp8Bmvou/myCmgdTGBHLWDDImSxwQmwiXeb6pUzHgZkVZiT0s3y\r\njOWlH2mw6JDuJg3ocx31bs24y33mPGXj+tw=\r\n=/wuX\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2210172057.0_1666081604427_0.24255534107144783"},"_hasShrinkwrap":false},"1.2210191347.0":{"name":"@bentoproject/date-countdown","version":"1.2210191347.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2210191347.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"b2888af97582abcfae901ed340328b22e9caf2fc","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2210191347.0","_nodeVersion":"16.17.1","_npmVersion":"8.15.0","dist":{"integrity":"sha512-4QO3kc9xIGKB+ijTUZLZLXPy6uttE2bUc5vLSg3HqiLp2xJnTAAY5EK8kRPi78+pWrjp3FQBKxB1vUwWeGO1SA==","shasum":"a0512781784d09e3273f6eeb0058f6685e8505dc","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2210191347.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCeTe3gBshpx4Lo7Nusua8fSU7G5sI9ITqQLrWP2Oy4YwIgWMVnOgTlU8dVD6FoW0fWSJgnE9gwS3ejOPGJ0xDlUCs="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjUQXlACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmr1shAAmKGVTxnTQPKbZDV93SySUZtNcTYxIFU8u0Aj0HXPNiSNCBu+\r\nevxJ7GmrlvmndcM2uVL3Cjqi9+hZy7d5xLHmFb+i03GEQdhXz8piGmr5bd+s\r\nircp8SNRYyUChdCDfgi4WSiZEEra4/zNG8Fti0QXw+wVtyxWqxXzU34OlrKE\r\nd9XoQkSC9idrJYcAaiUav+lCBS2nsj2b5Kt191Y9cVQELIFEH84X/9d/VbPU\r\nwwNwBetIiZKZSULLc0yJG0CFKk2gd2QFdd6JF968K3Uh78SMgztp2gpwwowd\r\nlRJhwS7JneawXr5hOhv7J2BJ52CiFki8ayTVMapY4LH3vv/nW9EPKOiPkeyY\r\n/c164aNsZgdv3Bf7J6dcHr0hlLsPUKf5hOue/xIOf6GFAfsZlOWqzHdUzxRe\r\noe5z7hltjgxvY5qwbqUi99oqcrP+rexPanS4fBh/KFI60qLa2W07aVL5B2xx\r\n8wUeaLyR2OOBfCNCxIIls8hdicHVPN2ow6N0xJtehbOZST857lQqNRz2Tv25\r\nbf7x2YlH+sv98uCeEOvH09nunzX+yUXRoOI3e+t5iICLJV8xIPpmx1NPgRfa\r\n1MnBQd5/7WUnjrN//YEqWL4295GiOrhNx3QWGJaU7zQ13xg9PzGZRpdwlJO3\r\n9ekgbGvN1Z8v3k7wRMk8YmxSltGqifhKkGM=\r\n=2CEJ\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2210191347.0_1666254309627_0.5140690542570217"},"_hasShrinkwrap":false},"1.2210211855.0":{"name":"@bentoproject/date-countdown","version":"1.2210211855.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2210211855.0"},"gitHead":"07d99f82baf83d9f0162a6c7b8790cef43e820fa","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2210211855.0","_nodeVersion":"16.17.1","_npmVersion":"8.15.0","dist":{"integrity":"sha512-sb8t5SOJrODC2cZ7FmLBi+ClgkHwMI1iNZOwByaSRZray439sn3WOc3WvPMbv8w8EKiDY4djehu2huDtWmSyyA==","shasum":"64c373b396df9ba400e55d9433bbfdc9deaf5070","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2210211855.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCjmxSaOvAQ+7jzCZNnwf0bBb2e+5TxGojWk5IfrbDeFgIhANprTkSBtNgnpiZJdKf31KzsPbRVNv8VCeMp2JPDRQrR"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjU6iDACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq01hAAoi2Q08T1VDTIrgSzZJli4ASbGlzGabQDtnaPJplC+QmRTAFP\r\nvnPvBqYfQyowgVg4eGuDed/7luz92yFLKM06PokHYO60K0zPrt80YVFif3Un\r\nOU50ov5QylC597agFwgrJ0zLPgfpx6C2WTNPIs+paTMh+MbFXvt1SV59Py+c\r\nN85kkYAKLRk6sPFuCDgweXK8k6d7rJ9j5TYYCUSBGNIHlfrYJWXpBAY8kl0/\r\na9qE9v+87VhT6Vbf3Gr2+k9AMKC4hagO40SoOxSx1m02BX73rdId4sPvt3Gw\r\n6DQTmiC4//aj0CS2OCfT+K7uuLMlTmJOjanHO9O9nzeHcGHTiYtxfDmPqhbT\r\nRo1tUSCqXlrLt4cQWu4lqTIASIzUMa5IDmEocQVLod1MhWI5JJ9jcSXGCQbw\r\nOMXcH2mIxEFm9mVHioWXkyh4qFs++qMf0fajafH3QoRQ0Zl2K9/VEUbHZgxM\r\n5WNIq8HyHnXeUeH/OaLZlqQRobCwQkyPAVzS4hK3O5luN3zEgeFPApL3ibOo\r\n4eDGiyNtKRLa8Eb2KQoEy7bV7za0IW52zSne3HIHITMWWWjEV52stiHCE2Hg\r\nsSm+0/tngf0oa4Q9m7jinxLgqDYsn6GkD5iJRcJvBhPWJ3zu3OnUDUM/SYeG\r\nDrCIs+0vZ9LVmwhW1VrPPjwByKQQKoH33R8=\r\n=yROU\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2210211855.0_1666427011047_0.5624114356670238"},"_hasShrinkwrap":false},"1.2210251605.0":{"name":"@bentoproject/date-countdown","version":"1.2210251605.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2210251605.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"a1f66509b5a6104dc33409f285dac1ab133942f6","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2210251605.0","_nodeVersion":"16.17.1","_npmVersion":"8.15.0","dist":{"integrity":"sha512-5tj0lmdOBU5VGwvn6eNAA43fZ9OVRuUBWOGIdCKDHxPH5fyvg7UqojpvJoaN39bcs17UMVvRr3LYZdHuYeeEsw==","shasum":"608e38f43f6744338471b283c251cdf1679d4ae5","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2210251605.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCkYTfjEg6gmBxIYd5zjWFJrhXAC9pnDnCGdda0wY1qoQIgAsIIgsxrGnIDaq+K34v+qy71bGWB8fsjuCg9KQ1BsOI="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjWO9VACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmol/w/+PCt5DaZs7hD3/cgRBL419pDGwvO/Xg4zqJ66NgRlGIc9rLMp\r\nKuF90+ufVxy5xWCnij5IqbUH0A/3Mzf0y+LCTsURvrJ2y9rPX3VXohydK+dV\r\ntwxXxDbOF7v97poB1Ag1NTdcS5ty9qNNERYGKgPPGJhRG7zFsHNPdx7CGQqB\r\nWhIczPRyJCiFEWPx4tkfIRhlx5cqKCtl55m/zyqScAYCLRCbkl+MnXpT43Tm\r\nONR7aNCGO1ZgkL5fU/zjEjnBN8OCQsRUiEZGYs5L9prLAPCK/vwuwoDYsfeu\r\nj6TVXKfhtRUHdb4hUUxA0rcDipy9AfNHPQAnDonzABrkqOth6RIsQlSbJqmP\r\nf7mQ+VrDOJS58Kueme2EhCzsbyG6s2ibCr3ninULU8gay8bx8Wmm7vTyQ2c3\r\nBSBers8gr1RBC9rQEiAMB31H8W6SD5wQLk+wpB4SP3ypirt0JIQRivzE/+l/\r\nOjTxueSTAC59Om6rRJFys9fzkEC79dnC3PuMMqqXvxFi13jSilzZuOXT2TUu\r\nZzMcqhWNZngsw93gPdt7lCtWvpqQIbJtfzcBsWBy0SU2l2GPR2xTnP43t14S\r\nEAK8Qo2dj7QcijTTLDanDCM+QxHPYCoasCqyFsH2qskIBX2hEkCoIwZrfhyw\r\nUS3eOps6j/DlIWBq5rTKeFXeBL0p4tEy1yw=\r\n=UjAM\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2210251605.0_1666772821489_0.4764903844577799"},"_hasShrinkwrap":false},"1.2210272257.0":{"name":"@bentoproject/date-countdown","version":"1.2210272257.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2210272257.0"},"gitHead":"9664ef260a4ec8fcc997a65025bb11a20fea937c","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2210272257.0","_nodeVersion":"18.12.0","_npmVersion":"8.19.2","dist":{"integrity":"sha512-xg87Bau37IyfxEe/PzsFxbERScz/E+PZWsMKgMD/T2U8dzW2lx5O3Ux/cu9JMvFUddcdWDMUoi+/xrB3je1pXg==","shasum":"4e01f587e1f8adbbc5c75e825783cf2cb011ea67","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2210272257.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCUTf5UdTxlNdQnhXV5BiavYySFO3UIqUJl5z4DtsSp/gIgbBDUIu/uZ45zYjbT+PTJytmka5oCCmfi+cfZvrD8PcQ="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjW5IMACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq7ERAAoh32vUirAppNl5ifIKHVsvgRS4pcMgY/bst56+TkBoXjJrgc\r\nGYuq8ERtOmP8gc+GMpGKzo9f6bIkLY5sgh4TPtVw5glTjr9fqakkJpP3x3+O\r\nHDZgXcC5u+bvfmhS4VgRtmzW4fCPFb2zqaogce38q5Lk5lxJeJA66EZQh0n9\r\npDO4wMQzwf5aLVsWSkK9liRGLhJdCRenzstL8uuDC/44QBzvwWUhY2Yrei+5\r\nCKx/GPYX4uDT+Hw0udq7zQt9A5Onkk0WZgpPkDLq/O7gWVx2WdrKKZ6wxMhT\r\n5EfZJYM5tMJh9ntEeVU5nIKXAZv54TIWqUkzV5t9ttDeLwlSHe5Gty1LFPco\r\ndi5dgsLEreNGPGvsIcc1IENlBRyBnm0zWvMtYvlvVe+kNVA736sjoKjZclnl\r\ntHHnBz/p0pOxBCPEYcqjuFa5fHfO6+6t2tZ84iklPG34/d7c8NSIxfxRy6Ls\r\nzP81zX6rLhLM1fBjN3geWbov+zXchXigRXndPMEtVpH6As8xkB+Cc7CpdcxW\r\nx5oro81wqE2utzuY9KFaasxh6PNN9VCo04lTlXkn7XWEsBen9XvADfbE2H+f\r\nj7gHfufpbKhn9jM/EdWJc/dRXwerx/8jWKQfQeFHRSdLKX86Sh/PEMLSZoR+\r\n6+dos4014Vv37lxDYQB9r9sdb0eORlHjrNk=\r\n=RyoZ\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2210272257.0_1666945548394_0.9626959921727865"},"_hasShrinkwrap":false},"1.2211042305.0":{"name":"@bentoproject/date-countdown","version":"1.2211042305.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2211042305.0"},"gitHead":"592500a0e400703252086eb8ab7b1cd46d674ff2","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2211042305.0","_nodeVersion":"18.12.0","_npmVersion":"8.19.2","dist":{"integrity":"sha512-6hzmRO1S5Uul4uwd+XvPyCHxs3KCDuWGxNFrIQt3Ntn0RuVIaqzx553j3Hi2xlOwy+0oWRTbk2GGmPStONMNVg==","shasum":"0db18bc5fc7342460dbe3666cb9d5997a916167a","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2211042305.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICoWB9HP68oRSNhmulsqy2bTbaKtF4FS2nq5c4Ai7Ct3AiEA4javYR1QOCP5xm0cIuzQa1bVCHCfB9VoHLnfixx+CaA="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjZh27ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpeEg//Y0SAe3ofj36pnTODK3j+ulaC+yuuXdhbfVd+F26al1PIA62v\r\nmXQ6i+kqkEIjAv12XvlQWm8XhxaiZOIX9JXdwlAOJ0ptFdyANB1JsN5XZSvH\r\nnJWzCbdWvO2LZLq+6VDHZwu4gmCWr353jJckEWwIc41LvoAWXXii7MCVRyB0\r\nnIetzOcY3JgKZVCIceKguFIAX+Ja+vL6qYV/oBhYIsAlRJOZsjcqXKXhu+4/\r\nlrQm2k8XTMzeXxCQXCob0fqiatcVJfefrDp8mAiLyO4WxGmIZU0H+wvpdlb1\r\nQvTjfbsnyl8F0KfbEQJ0glvlZwz+T7bB/jLI6reLMm0HqIJkRafckBfupVuD\r\n7/UaJMSFywrloHlIIfffyA9WzoQtRtYxCeb0Ijp+un4WtM/65DM40mLC9ZTz\r\n2/nth4+CAeSrH4K8IFfrBqOF4rhbRysW5rbqbtejgjQ0BaCohPTEzAie82hQ\r\nRKPBEX3LYpY4UV+RbUaYjSIEMVqUd7kB/5oOxk9+GkzxcmrXW6pGsROGkRNr\r\npHlkf/QreOBCPIB0fdcIhq3Wma5UMwsOrAUOXrZrvZud5fwK7QgKREAplaCq\r\nNDet9aOzMD43EIgeT29wpaYwPZn+5Em/4tor32pGvFjE+i1sORCsb/5YvE0G\r\nKqpEMf3cw4dRghHbbK4TaEy4NnwY8wwgpYk=\r\n=7Nla\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2211042305.0_1667636667642_0.22270867815784623"},"_hasShrinkwrap":false},"1.2211060024.0":{"name":"@bentoproject/date-countdown","version":"1.2211060024.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2211060024.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"f6dce0a3fbdbc90de3eb1773dbfc31ff1e476460","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2211060024.0","_nodeVersion":"18.12.0","_npmVersion":"8.19.2","dist":{"integrity":"sha512-H9GCY6KFIWTlGrOSLQmbKERQdRRxCVkrF2kg6xAPAzogfpczz0LZTHJuFQk09Sgwe4GymmYEN9Fdlu6eGmE0fA==","shasum":"469977a0b71aeb59d2305872b41330745e1eafaa","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2211060024.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGN/Us3CASBEPXLyfOqx+e+000wPY+Np1rv7r4MZ49i8AiEAxCnLwqJ/5gTlZmNrV9KGikZB6zTds63bUnNhjFNqnrU="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjahJVACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmo6+BAAhajvh/nzsT6DQpMwjSC9cOvkB/q60e1SxinSK/6R9uDoqU/O\r\n9zXZ7mmK+6otXF9IbKgbWScscJh9OhR7ucN7X5KETPjtZcqMktHflEyWRRyH\r\nOZU9fqnlbtbfx3TWgGt7qSzP6IiGxur3ZCvi3xqY4wNXqIBsTvwvlqINZ0Az\r\nyeI+MzuhbKqt0h3J8iSgHX8ll95JZYsplnBJem+/EAfWE+m5vvGuMG8FnCwS\r\nRanoKl38E7dHK/u/8nnOrMojCXZtm3GuJKALadYmHaX8X1f3jGdpFycwIPc6\r\nNv2OVDkms18cPuNhurmqharIUW+ia+6DAm0GN/YnFRLN1e3fTyGkocbou3gj\r\n450vplqEUUY/l6yymBXd6mb94ErP44UNI7xKNfhO9ubchv3axIfoQB/QlUtT\r\neQU+tDSWhmGnSoJIqhb0XXKppoEKKMndGOnEU2mjnwCd/yRJ+W9EYzI3yB6c\r\ntiSvO188f0xaZZWxu3dio9nRXkndgLZBPSqrnKK76viT2+5xeZxoEunsqlQy\r\nAjnXZLJaG/4xcQ7oUXz3ojUdwRMnOdcsF1pOndcfaxAwL/JEAnMM8qJUqLYh\r\n5orJkpd+ICRrfi8xR1RUcjyRU3be96AVcz9Jtf8QYLpLftuLeDgesw/Qy4gU\r\nk0M+6SD3BBv4vXWdZygjYuXXA8b03jH9rUs=\r\n=X6vo\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2211060024.0_1667895893101_0.8673918272901648"},"_hasShrinkwrap":false},"1.2211111611.0":{"name":"@bentoproject/date-countdown","version":"1.2211111611.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2211111611.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"f9c1138144838b5c4612a779bf407d2b2413d105","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2211111611.0","_nodeVersion":"18.12.0","_npmVersion":"8.19.2","dist":{"integrity":"sha512-lqhbogkRAowx5NIdGsboNLZGkcvDsyjswlS2DRPcYPfHsoNjJahUVwpnTc5c/LQ+L2yiIX0I6iZuICZEvMgBfQ==","shasum":"183c55159375da5e172d4d5a86cf763f30cbeb4b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2211111611.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDYwdLEd5C8ca34I8pS6edeLo8mmKzL51p+LT/5G7v65AiEAyh7hT8ll0Pxmpnd46T8fl+Z99J5IID/EWj2QeDqFAVA="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjb1gOACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrRaA/8DsV88t+vn38680NZHZDNuN5SZju/BHI1KCfWvOMxgralJB7p\r\nssFeu4iaaZruBx90D7lVX3XBBlUxhuyo3hsUz0oVOMQcj1z5xt4Puamb6sxN\r\nTAC316eYuNcXbR99E5KISMiQqEL22cVkWw1a6eLRbw1tM4L9HsYex6AHB6Kw\r\n0Y6Uza7QVK0vFUJnHHI8QQLSd5LdHxSjZ6DVvyETW4tTooqw69Kp8KI1MFDw\r\nBcctmHdNbB0DNr614NCPM5TsTqYeF7RzE2gtDEH9pdxp6tZ5aDH1l+y7qqBQ\r\n4uLtZlLMRACJxnAPbtviDKSWld/PBiJOPvBn3dRdswz22sH4rsdElBBFS+JU\r\nRg7uuon4t/aA0C4zWGEKNy2PW2IHzGQIdTEVyweL9PJyeNptSXQG6wKrwhsy\r\njE/fZoH6Y6CmaqJqkfVVZKaw8KcZepYNYwzNEh4MMfsA2yookYs6RIVzJuyK\r\n9DdxRMX6A42wmJdXCym/RORmKZUGc8ym3T4O+v5rF97XMCzu08doLbF6fKsQ\r\nSzpPIcTBjzlz71QD7MiI0R6Ss4eclWvPvNe9SFq6AFXonsL3w9PxUjA/yXcX\r\ndia/jG6+cKpdsRx+sM/+rYG2SGK9+z5SGuCafl+0gb9fVMPglBi9VAJCst+j\r\nhicUEImxifwQXECPHApP67DVt5S/KJGCLhw=\r\n=djqU\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2211111611.0_1668241422509_0.324622757458477"},"_hasShrinkwrap":false},"1.2211151402.0":{"name":"@bentoproject/date-countdown","version":"1.2211151402.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2211151402.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"db41c24bd071b6322e0a5188c4bd74aa94cb9d5f","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2211151402.0","_nodeVersion":"18.12.0","_npmVersion":"8.19.2","dist":{"integrity":"sha512-DoQtOqZGLu0NT9QVOm5XjDeZvuFQEA+rKEtHr1OdqVYVxtVmqQKwmB8Qf6Cc4GEdObok+O2I42tPdQJuEMDXXQ==","shasum":"d697eabaee42503fe7d4922f64470f32f207e936","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2211151402.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICcVzQ2jrJeIc4BaGdzBD4J/JOuR+pgGsKvOhxHJxxQJAiARiBhcBUlg0NdxB8fjC0GmwMyVtpEBawwl3aAJi+WlGQ=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjdS0sACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmr1jw//WyPC1hhSvrefdw3Os1BLMCm/Yj0+4GzF26VcWVgyCeXHjeEv\r\nnoSJ2bee31aHPp8Blr2IelJ7imX5FvAUsP+WzQ6GIpUR50mwZw5FyOQ1gGRN\r\nFwpX2UQVt3hOyHXVDAyU4j+Q5/z+gdxHpQmyMY0lvRT+IHmMaXj9OLB+ivSd\r\nDbbFJF4VyXJSpqHxd6QQ9yvsLvOoureLDr89iEAYB686U30/ZySSGtAI5WyJ\r\nLzshSxT06rid7lthRpcn6ksqDABjZkb5ePqkAcgrBEXjuBRN+ndkhuGm1Ddl\r\nFod6D866A7RlVThRvK1cr/kURLX1L95OMu40uOUa1K/e4TScLGF1OocVTkrL\r\nQe464hRqBZuBGXQzKdjS5rX6VyRBVz+nAgxjaUAgKpCTu35FajZAv+0FGFV+\r\nbWUfkGMaAFMxvHY6KYF3zYI/xXK1IDJWNcGf4mn8xWfBWeKEXizYr2wbV7M+\r\nyjaYhq1WtL9SlpwqQ3SZOLjnCjLTXNYndqUekUDgvZ4CRD6A8JvlhyR/zmBb\r\n3UuHJ+GhjBogaSO1c33el1w1qAoI3CvRT1kuqg1ix3laUwL/SPzjqOefgmv3\r\n57ukbuhFqG2vjihEJR19/zmtjBMPEfcRWFN5ZRKZ4shevz6aCn8wPySDGBp8\r\nJ7Hv/dvclgZol2eTiZeWlmz+9r9YJ5/ofDo=\r\n=6Iu6\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2211151402.0_1668623659785_0.992422141872557"},"_hasShrinkwrap":false},"1.2211182146.0":{"name":"@bentoproject/date-countdown","version":"1.2211182146.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2211182146.0"},"gitHead":"d5bdbc6c36475eb2c4c14f2b02a112669f244641","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2211182146.0","_nodeVersion":"18.12.0","_npmVersion":"8.19.2","dist":{"integrity":"sha512-JIwvPboxdVAVeJKfjeOv7xIRRSM7nvpRqlbAy/OOWun3Gy2KmE+sgsIDJkPk9fIX7jGU+nvCYXZFiwIBKLIK5A==","shasum":"cbd2493aa17f02c94f449dfff870f2cc51e3ab79","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2211182146.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDfHv8nTcVKLoVpXO3K96t9loShRWIu7EUHOf2M0rLkpAiA2C2bQeCYqkeVEAnjs5ZhtCaubk5dD5vF3V6Q33xujZw=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjeJLjACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqK8A/9F+fyx0TpP+VBEr3S51onUKx4FrGIhEojGe6Mvj8nTG0xw7VA\r\nMxZscfd0VoqUtK9r6ct8OmuDdZU/tDeVUsvz7pMIIkcB9QL+RK2qSZiA4Zqi\r\ndS6mVjpgYd3Rao4OjOjleBuyEDRH6Fe4WM8+OaF7dnidB7dccSQ3RKz1pEPH\r\nOWn2GOiQkf19cDLzlqWflNd2sXwd9mzywSWGLt4UkL+h5eeIMY5QNY7EhCLO\r\nB3tAqR3rWVX7nCu9hUtMKwa0rlhXMOgl8bHQV+vtiNBllwCWX00HTV3FQuO8\r\n497K7+6sAgEfy8uwdNoj8EqrDwh7EyJbG5zj0TMP3M90GMEME/XtOZ3HFJK7\r\njbmKDCKfrRNMu12dp3Fj8i/GSBaSzmyqTfRnUCiSSUhkrXusmeIrCdcJsT+d\r\nlrtJ2/77m8nS6bl+Xe0BcgHoS0kaqtXD6GDiVWDFG5jaEZ/bVYAZsoVhgYIG\r\ngodXrSh+GrQeqkk0H3cFjDieJ/b/8OZL6rIHMBDMN5q+nkCWaQ5xVuQ3B0mt\r\nLfzgn1wiVL8k7Zw5K2o33hgaXR5me8Q1oBYIqwzGh/iqffbC93HnJqrZraA9\r\nzibgak+5QP9KEzLC7Zuu1oNiwKp4MRLnmvjrhdRV/4EzanHhzAgMntmeVJxT\r\njnjBus5Z3PLf9AFBrQd7tG4gRn9Zs97kxKE=\r\n=dzZu\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2211182146.0_1668846306793_0.7969888816656394"},"_hasShrinkwrap":false},"1.2211250451.0":{"name":"@bentoproject/date-countdown","version":"1.2211250451.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2211250451.0"},"gitHead":"3f47d465c6e6f4ea83045b32b2c9f56eccb943e5","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2211250451.0","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-UTA0B6hO/yhr64oLHsAzmBnQuhLJL0jntblQqCIH7lDaUYT3NG6Rtk/SaZaW95R0b5USyLqK6vkfOPgXbCb8IQ==","shasum":"53e3f7e442ba82ab83fe55ea50d8c48c7e4cd44c","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2211250451.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDRrlN4JSk+T7Fkbz5bA8D3oFNr3Idu2pMf9BQXdupHIAIhALIx3RsBuFkn2Kboe8HRAZFoRY1KzQt9rEvB4kozgRfa"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjgHuqACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmp4NQ//QBti8s4MZqpyLLQeK+jQf5iK2wF3z6aez3uTKgQM8MQlKGTL\r\nDHFdaLHz0kJKrpoAtEpaOoP6Da4CjRj4mMVnSNtzs6VUNGxWRy94uAc1BWyJ\r\nXQraJybhC037ySRR0vsvPeMOYSGlEj8w118WoNYicQLssNQKOoXuZXue5fQY\r\n+K5aX69cnx8L5NZgzlLGJODL43wqUtD8vi8ypaOJ8Ylmmq9vXlo/wBZvbv3q\r\n7xW2ZNWzBPaIgT+sk5bU6q4eLAL0QRDFKIeyeGzK4bFOb9vZfmsPBV7SnbSW\r\nN8sH+8bCYxFIbYUafz0nynxCTR5fQKNYjor0CdobztHxqDH1OSe/c4Lqf3K6\r\nOEC2Zu2fHE9UsNBd1gTl5mNthK464E57qzkN55IPcv8EeRhr3lEnxY3DiOsq\r\nucdqXtoAWjUsovQdgxkJJI0sHFgrGRzVJ9mwk7FUzmMZaI8sbOEBOHQuCd9r\r\nwxOLkODqfiZGpeVWZzpM46zMTRjqHcXJy6b76xeFxph46Z9hz+LQvO+DB4Pa\r\nVsFijlYaog4DPnP3pbJLSXCruzHak6lv9yaN7WiGJEzYplpp5pWQGWrkmgX3\r\nCCCmZBaVidWdUFgjJ6G5BQhcyj/1CzWlmQDLp8yUvbye/dANN+Gmv5NQu5h5\r\nOqODRoOnV4QtUcbmI1k2fMCKJchafD9YHjI=\r\n=f22q\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2211250451.0_1669364649860_0.7880393673684216"},"_hasShrinkwrap":false},"1.2211302304.0":{"name":"@bentoproject/date-countdown","version":"1.2211302304.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2211302304.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"8ec16ecf1bb95c1a6368ab455a6cfc7b1caddc46","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2211302304.0","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-Xf8NnazBiMjdwDzQH0f7yRJerd8VXeCVUp/7Kj1cfFKQzuxyxTw3klB6KELuDm8xVLuDmvFC5RWjNA6svq+fXg==","shasum":"daa7b95a62e320dd07acb7afc97696f9fa383dae","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2211302304.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHsrMH5OuJ0m/s7ZMF40OeO4K74bUMsRaHecvSy0jiWzAiEA9R3LssTjo9nempEwBA3qlCa4/8kTHeieBfpIaon9EbM="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjiGSSACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmpt2w//cA5iX4M8cSb71j9j4H/9zh14riBWimhSiX9w00sZeMlF99QG\r\nX3FWjttTjMrpKybW1pKe7TFQmclKfyzfQ13GBAloJ0y0Plt5Zs26O7iE/GkY\r\nE8D+3UaNaKEHaIBnL9K5j/7tBIXAIQw+dwMzPaQTy/Teet/KFRU2qCX4dKmR\r\nvBzwGyojHWEoqWNMAg5px0DX/WrSYA5c/8njmUPNkOzVVDt6pj2mP5Inhv2j\r\nlhGfRx2Fvc8/WGaVOua2gSPfAtGKvI0fZUQhz4+Rb9UHUsdiY6BiJGRwVuWM\r\nzjrODlYJn3GWAoh2AlfeeMzC9BYnGvDQsSYNYqYQQ50ynPcapj9yP7EuByTu\r\nQNp2UFcDWBPFVvidew1InGwKXKr52o8OKNE+0pMK6CCAQ1tiGqeXy+kfhPc6\r\nk0CEw8kSXiYfgb2DFcDT6Pesqv+T7k4f/hwbS+s10XpfrpX2EcRBiWXOxf0C\r\nMiD82SEbIcJJUkIYtuxsQdb4CGhjP8i4dRnmpM7rL8V6W7DJtZgTi6iF3I2w\r\neU8YfIptgMydV6IEyopp7pD7UPHr8Jdr+6nDHBE6aXsUkuKk8fvzNgN7vjLI\r\n1V98hfTQbMe3raO6a9hU5k4/gAYfCcO296TQX8vX5iNQLant0dOGf8ej+iy/\r\nQe/7QdvgM64hkBEkyCimHycbe5RsdpSmBIc=\r\n=lGF9\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2211302304.0_1669883026712_0.37859278526049445"},"_hasShrinkwrap":false},"1.2212071834.0":{"name":"@bentoproject/date-countdown","version":"1.2212071834.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2212071834.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"9e7a659da459058028a29b649ceae3a2dda7771b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2212071834.0","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-K9FlYIFsBqtsx0HP3Kh0ZfQcpZ1dI02puw9UHwXzd5FUyXq3cPrgzR//TvqwJAPgiVg/p5OQZN30T05UbgGNNQ==","shasum":"fdf26a66a747d773ac76aa43a72542f0e3abdfc2","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2212071834.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDzDAnF917t/1QCavQVjBqCsTeHDbYnG8KC15dBqFqmwAiEA71KQX5ffuteHRjlaSMiWDtozLrx7pG1uM1761zmYUlg="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjkOtpACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqAQA/+O9AMpxaZc10UGvcm+guRL01xgsYX8WDn1M4zQkpVvaFfCzHd\r\ng1+oavsOG4oIAHjPhO75V3vs83VvFle7YGY2yYRphASylZoRY8q3UJd+7VlT\r\nm05daMrDTN6I/rLumsXw5/b3kQrSTS13iSDe5HjfuVhcdPjPveOHgYKcgTkp\r\nYsPWgz0wzeBOWzJpCEUQcNohoqlJ3m5BSmtwD8EcNMWZhJJN1rHjHRoGz7Ro\r\nxcGKah9nR2bOv4ssZQnSNsJsOUEwTVcLlN2oZJj3ejF7mEJtC9WHhZFeUzwy\r\nWqzbnqeves/UKEv+olaZVrFsjCQYhpknRFrqYhlLtLYk6ESz7EP7ECeKls/E\r\n3Q3jbWekuJ+YFD4koryx6wYWA3ws+9faiRlithpK6dBEl4sDYOY5V8dgr9rd\r\nC7BpVE4ILW+bOOaC+rXmFNbssIi7uXfRAiiE6b5eF7g4C327sIkOoSFMys4z\r\nB/pg3XbOMZKhbAYmdDis6y4CoSTnLPQMtZeOahnhEf1vqmokm83zthT71lmQ\r\nZv7fY9d7THOzzAmkLqTXHPVzHYwyaPkoFA4DZ5WXkO7ZN86KsVT+sAHu+UaA\r\nFsLPX845HKeVsDc7Pf2SPicljfb1IG//0yep7RKhOgTQSdtENYsduw25Eprv\r\nIEzgxhKnM8CMs7AREINSOuE229SJuNuPcZM=\r\n=RsJe\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2212071834.0_1670441832830_0.4424996160418846"},"_hasShrinkwrap":false},"1.2212092023.0":{"name":"@bentoproject/date-countdown","version":"1.2212092023.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2212092023.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"16bff17f2a3e911f517c49d1fd2c74c8089e78e0","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2212092023.0","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-BL/20z+oQtgNLE4Pr/M0hmVKGoI+UjiGn5l5SLTzymOgLQNwPx++cI8oDc2SiQ6RhkHFe920+NySTpHX/oj+sg==","shasum":"85956c5f6ceaabf9861b8c1c22e925bc7dbe2dbd","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2212092023.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDnPj7fefDdCzjFCOzjsSmEwR5xLqjONrU42DnSSQ/ymAIhAK3sLk4v4h+cAFZ9TGmyMUzL7ZndLvPcZEBT+eNKaJIh"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjlEJJACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmo+eQ/7BRARctnhDIEQsClrHDSTplNjbDmqfKqjKt6s9+9ujI8A/zBG\r\nCGLbjkJTt63Zbblg62UXjFqupT++iev1KR2ZyKb9NixA4pjOU47oS/7VEdWX\r\n3kkZeGZ1yjI1K0E0YyRxkBOUIFl18TTrh7yfGRz494yuOSLc8/o4vreiHZaX\r\nnZ68cUjbHENo4KmRK0/iTG8amRm5xpStIN2C7Ua0PGu0sgp79xsTF8AhFjxn\r\nJUp4qdFjhgZjm8EhcRH2dx84QbvW+7uajfMjPKoc+0WloQSNDhQk4VodhW1x\r\ndJs3un3hOAopKlGwXBBcP+WRQbGpywV8EsvFBKjnCrFzG5TrDF/dxIgRC1bc\r\n9kYPqSZpZlphj9njtNHN188JzX4Z8HzYUvwi33FSKk2fw1rrx9yd3OsFq7WT\r\nAhSrQJ4bt1DCHJZqRrtp2a9pjCnzzJpdmwPIV75cLaQzKm+m01kJjOW9LK9y\r\ndg4whHV97F8Kd/OsFCPHRUnYgoGy/4nnnMTkz+E5TgcdNi4dMrFNXR1qXCtu\r\nxRD4cei2zbevG8EjDLkm1T2Uru5eNb3Gl4vC1eoCuoPb5kSANSiaYYKH3wiy\r\nk16ib3uvFpCTAcIiXkCWqBcKY1hD7En3po0OEVu24RbdKwMLfyZyw0Mb3qJo\r\npUUuT2+zH2Yzj6dvU5GBf5m/GxEEogufb4k=\r\n=4lSd\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2212092023.0_1670660680737_0.9382470294942988"},"_hasShrinkwrap":false},"1.2211302304.1":{"name":"@bentoproject/date-countdown","version":"1.2211302304.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2211302304.1"},"gitHead":"16bff17f2a3e911f517c49d1fd2c74c8089e78e0","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2211302304.1","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-ft+D/xizg9Dyue5yHoMaeoRNoRN4e7YIb2YlM5YAixKRiBRQ1Dk0uLWQ9t5O9UscJXIQC+SL42vSmJbkRxrxLg==","shasum":"2ea0e91554ce31358d233c1a0852169f3d65cfb3","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2211302304.1.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEI2vRsxrLz83fJceY+xZVQGOEfLH+v3M0E/2oaIwoNrAiEAxVucPsTiFk9YWLG9WCB1G5GQkoluomJ/S+Vs2FUld+o="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjmPQWACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoIPQ/+P9L7fZcPNTRn7l+g+hbXDyv5V/qtR6e8xcXxZb/V9TyORtWo\r\nL921jJhgHFvV0jEjgNbW8WduircSIxNSsV1ca4YJrEu0NQEZM71l9b/K9Oy0\r\nHlvcxcyk2RigcMauMR/OsH+OLrgz7HsdFPzeBYXTdIepPxEg7CxZKERQ+y50\r\npXz0ypQ/tiBifqjvvdpaU2Hj/vhixG07mS0da2gm4ZOhFsOYW8jYvp1BjFHq\r\nnonLlytwMThYM0sDndCfdQvN6tW7MjQSag3YhFVYr1TDmxLt+eI8xjtvHHYR\r\ndLOzk/TuVfGPvgaQL2mGh0oC2i+rX6uqMHEkhxQBWVaVFyXb77uC24FslXO4\r\n+SXVb/MxLJf9kzkEpDs0ms4sBlDjud5R0t7mBCiiEisYht4rqlMjugtFRIcq\r\nvWxIsS1xAqjiwgDkTbDHX5pFcn8q2lE6BFmsnBOn0//54u0Qr6yUg+DlXzHv\r\nPkhtwO4Q2IFlffBIONCRwSD9e7tsAEE9/XjhvLlUpiNnDZ9wNAiCkhPjkyjG\r\nW9Xm6nsQVN8y5c2JRHbDPPZkaRA2fdQpXuAZ3q4TaMa1aR+BiZzMD7Fq+gCy\r\ncPKJtpeCQ52VUpeSct6rqPz7YZ9uxITS64saYYmVgYV+ezAk3/6MvrE8d8Yf\r\ndgzl/Y3G9gdzz2VU75YD3s8CfAHTL6J/6QY=\r\n=rAjc\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2211302304.1_1670968341872_0.595221292672377"},"_hasShrinkwrap":false},"1.2212151632.0":{"name":"@bentoproject/date-countdown","version":"1.2212151632.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2212151632.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"6754eb8b2feb7d6eadedb57776b91613ad5d6dcf","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2212151632.0","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-6HqjaAJCeh3UBj+AEd1OGL+DD5BiFwVXjJ/IqgIw3QL+sB23Jd12iA8crrl/JDkynvx2XUK6VnJFBacjC8v4JQ==","shasum":"6fcada930faa2fe386827d264389917bda22311a","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2212151632.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICds7w0blZ4huok9ovgxw1Y3pyG96NX/709yLrePkFw9AiEAgxESJn/hSagSPjvwsPta/4Wo4xuPjgKHk5YVjv7Q9SQ="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjodotACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmr51A//R1SlABWVWqBJpBgfYr+6r3MhULdAMVWwhu/6YInhFOe+Xqj9\r\n27zSE4PcV4MLDnXbAuk0Oy/APAkfIYd/XfkiVYRDhm3+icCg65AhoNH1OMot\r\nA5V996rLpKqv5dRMezKk47e3gYWYptk0+XLcSm56rUKpJuZOoslAuptMNXwg\r\nZPwAdCbUk7KnjEROyx0jhlBXe9owZUN/DWhF+U9s6r92Cej2PB8blDmT4XWv\r\nnscVNVUAbeJHguIzO4PIY0zwBCfkl+8Gv9jBfnpmTZNnbFY+bvFAHgYI8vNR\r\nRdiNMk7LyVAZf6uOT11B0WfkQC0v7P7utB1F30knHf9/wtZ+Tyhxa211NoZ8\r\nGxK08B22wHVL4tZfhKP+X4hRTbJ5eijyNU/KafkwA2hjMP+YMqlX7p6vQyMm\r\nhFkW18d6HTfptAMe5cfiScGm/SiO2LbJzD499M5Rc0q4zJ+BMkahgxgy2FmS\r\ndZvUVyI3946cP0HF6vxc2/eD2mWoPxTx0wuW2blXHG1SEmIJFE5sVTnPcugy\r\nhOhtR6vdjXeeCVV76MbBq2+QO+8shsE9/jbUQrTIejI1Sv8rpAnI5C9y8w2E\r\nAE7MnqBX7fc4OAYf4JkSQrvIB6W3+Wx4fS5YKSxdX2GurnEuu20AmH0T8Mlu\r\nOxSdyenucwsClmKwa9isVckqHCTYKrzdyhQ=\r\n=+fOo\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2212151632.0_1671551533628_0.30618093893217657"},"_hasShrinkwrap":false},"1.2212151632.1":{"name":"@bentoproject/date-countdown","version":"1.2212151632.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2212151632.1"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"0daa515ff1e284cb2e31dc8fda7f29c073e60b60","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2212151632.1","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-QOpggug4rBzU0R+YpFcPXF8moMXzbnPvp/uPlJpGFMeuarUMCOhzYapGfKT7krQZL9KN0cTTauUW4mVqXgeTmQ==","shasum":"63ef5b53a648b840eaf35a20d686de938cdbea15","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2212151632.1.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDgoN/JjPxGd7YSO3U7ZcTOLsMf+a63yFMb8ndOZNC6VAIhAOKys0wigKpxfRtG6lc60LL7P2ypQbbfKujDc02dxg+I"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjohZ1ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmooeQ/7BCKL0wQhmhEdNOSglHNdz3x5yOUxXG3U60mdKY9F1bTH/we2\r\nP2BtDOt5swSwTOmk+qHpQne7/xaoqEETuJ5PRZtNIp5/vF+vAT6vbklbgv7t\r\noYET+p0jcHPrIIoLByTT3jPq3dMVqWpEfC25tvnbHf6PiAXefWi46tMZ2iHI\r\nUzmG3a1W17Ijq13ZTLqcyzQPrPRCDUGvycCZ3oyvNGDp2jLIcsnhIgSpM0fJ\r\nXglzWSI6+jkEHZ+Glk9GZnvBTl/pDbrjRq+gb7b23XDFoiIbc7MEPEUBKXfn\r\n09TPqn1IPHCd8Lj5yvTRfryPcKeluV0iEaeJ9uC1ylh8SqAeTyM8ZddzmbCm\r\nFT3Snp8I29hdyLTmtZ5Z1Q4lqKbaBldVtYlLf36LvwK8PrJcohu1VTiCMMnb\r\nuncH0B8LGYqqbsDE5eEk0uSeQwk5GNQk6JK16AvLPz7ZoderY/8I3+BxdJob\r\nrcrQxHdHHYRXYVxfqbJyoytMzndEWOtGzGItcF20rWZT0pBFx6JS+gIVy4Zo\r\n59ImRQtW9va1FoYru70+XuBM0EUQExJrE/bRSK91uvJW9PNC+YFspRYveCxv\r\naicIlsVocU4i8awo8/nt7Us53FWCuRU3Bx1un/P1LQvOfJJbmKesPVm1XGsI\r\nX1EY9K13GvDtTMuK/+E57R5Ez0bj32wYGfg=\r\n=PZ/V\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2212151632.1_1671566965169_0.048861676657223185"},"_hasShrinkwrap":false},"1.2211302304.2":{"name":"@bentoproject/date-countdown","version":"1.2211302304.2","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2211302304.2"},"gitHead":"910a4ee7a16075d9db8fd2c6c5bfb607f22bf54f","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2211302304.2","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-O6EMJR6J7J+WVpL9bKtFD9lZQSzyviClMSxRmq7Jye5zznXlTAsJaGbfqqf9bSa5zIVJbRITvlhknlLhlP132Q==","shasum":"d4cf205bef0c22a72f41b7746bd135f8299f8c90","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2211302304.2.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDWm4npqa/8pFTaxSpsXcqz409AEbodiJ0Q1HQRcNbFaAIhAJ/c+eQgOLPv6O+jbbsW64mwfSXxgkcLhJN6FAZE82pN"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjojfwACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoHxw//dmOxGo3atbrLEi0rdwNDhe0uvm2nmjgCYmTaemPB1CzYMXPM\r\nT8Vm44MXvIO9ZYhmaRSCvas7m5cEkwMVekOjvEJuLbk9gJUKKkME00Wt2/Ub\r\nCaXkCZTiuXDwpn5tseqx23xLeKM/7ENnYE27Hxjn5cp8NLg52MRXqEHe/uhi\r\n7V/Hwzb7xaReBwgqYttsxno/979xUTIrgtmg5YKylGn59lzFeyYRfq3jg2c7\r\nrTw5iXQIrK8TzEAbd+TnqZ9DqJsdJHt7ac2Rv/cfBjzuOHnTJr98BZVzNR+7\r\n0URJ8eoA4q47tinNjinbqkpFFkI3lJ9U84y17EnrcQgx2DmHYuFTCwSz8FR3\r\n5SJcCpOLfjmt1RUccgx+jZjIJXMygOiaXk10tqE5nvxBr6czqrZ46i68GCgK\r\nmcqK4W48zy+UCzbB9p/KuisxE4egqlY1qD4i7VBQlIpsRXyhAh9yYcvzOT9P\r\nZ4gdZzyBp7Ep/zcj8hajLkNioKDR4YSsPACC1zuRHsVnOpkvwQWO7c911GIt\r\nMWO9DN/Oq8SpAo640zUD/i/Dsa1yqKJgBvI2dU+bOyhkVNU4aYRFX/2mrKqS\r\nlpBC4Zzg0oavgMjJ+Xj+0bPFY4RT5tkApxKIHv9YFpPp7EWzj2U00T3kDy8h\r\n4naKlmzehvXPXv9tf3maqKma4WfoMFstyUY=\r\n=qJ5o\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2211302304.2_1671575536756_0.3046909101090878"},"_hasShrinkwrap":false},"1.2212151632.2":{"name":"@bentoproject/date-countdown","version":"1.2212151632.2","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2212151632.2"},"gitHead":"e3ba25e45c2728fd6b1c91daacfcf7d0870ba6e9","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2212151632.2","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-OHfz+RmSGYpTWLkwLBxBmOEEh3EHunyd3xYjR3yp0LPsUnU3Zk0kw98rhZDtfSNyici5TAyy7NU7Gfy2fSVMtg==","shasum":"a9e75be68bd92acfc74ddb9a0d70ae1f05755fed","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2212151632.2.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFPutVo3X2JEoEMc4sQl5oUabNyQF2ZxW0p8UuQAeR0WAiEA1IttoiT8zHxqIPRworjJ0HVcS4s2Yh1ukUrH0sA6SSI="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjtG/iACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoFrQ/9EzlsuWhJOcSFZ3VcI+XWvtDdRUc3OaSAOiChU9LKYrEHqdNZ\r\nGytZvk3MHOmDUcq2Feb3juqXX2jGLDjg76eGRh6EwuePzrzezGg3h/sQwtYj\r\nRClXgflvPuyftsvqoROZZzlPeMH9CPpJVGGzOMqBP98sTGRsHdrmy/Yi4LoE\r\n0XRWjYm1cL1b0fov2W04g7Myq3lFs2Y9MoCe/r6YYuNJZwVh4MexptQeOw4W\r\np2S0ZE5aQypzRDdD0nUug6rtSs/HzeT9MsOMkHcGrIMS6/BqPYqcQpwPF21K\r\nMAyQ9OfsLXef793UvtyIrLsr8JtxXnfiYY2kSgfN6JHK+1/wFM72cc8ksZJT\r\nXKWfFN45MqXPA30M9Y8O9AN0lpvG43HAzUoThkzFOrI1o32wle5Knfpn8g/j\r\neA/hde76edOkT2Vw3rtCkdIPndR2pKq6wEwdbrCD2kNo60QMkVCauUrKCiCM\r\nGtcP6KrWwkBaDwIz6TBRQpxyRW6LzNAgbvfYZ/PhuOji/BJxyNfnkjRGYKUW\r\n6yz2+RmSdFv8tSEOitcDGXK3VQDyo0aKbIIx6yie9HBlVa6qUary+WJYnMNP\r\naQ/NouqKyQWJOMxJfIIUSXmVxCvxWw7CUU+VbxjHrX1iPBSMeKMZc9LyIxqG\r\nd2KMl3pmfmLvhvwWGAIFEMbE4+EQhDmsUcI=\r\n=riYW\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2212151632.2_1672769506274_0.9415811660751865"},"_hasShrinkwrap":false},"1.2301031703.0":{"name":"@bentoproject/date-countdown","version":"1.2301031703.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2301031703.0"},"gitHead":"e3ba25e45c2728fd6b1c91daacfcf7d0870ba6e9","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2301031703.0","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-UAt0sCTIug5OtkzsSDtUlzykUGV3OJSvWfz0oBcVrty7UjdXMEelb5mo5lD9ZfdIn4OjaNbawIgLSWbnq7mhZw==","shasum":"0cb91dccf274ca0335127e338a07e64ec550a350","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2301031703.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDj54r+hWLkgZBTqAzYT+uPKgclslurgMkaqglcitm1QwIgFf2tyjdLMkKWO6C7g0tXGUtuGqtzBYwLAYZV6BtJgZ4="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjtJBGACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrYCQ//aWpC1t82hBs+a1R1V0QSaj1ZHrh3pfwSGX+QedJn1Lnm4Kcx\r\nkf9Q8pDk5pne45wwU+TITX8remgrdgW+J4RpSQW+bY1pYnPk2oCNLlx7DJYi\r\n2wXwjU++pDUx/iLIfJrZt2kJVNMVak0AjNzp0yykF7lx8xOu6lMb94bbkSYE\r\n8A5e4KHhcMzPiIZJ1bGM5WMstgkRmxL1GOH1wLBsxWRPK6Wtrrm6RYSt2oKQ\r\nWkZk1kwO3rPjYeHUNMdHwDXINEaVagJFKeqU1r4hwAJBX3Ac2COeyDWom8Ul\r\nHsm9/rWlo822XaiEi6R4r6q4cZqWLugso2kOjYhkCz04/srdGxEaNHzSeWGV\r\nU8OD+4s/dNkm8eO/FZ7lgomUS1eESoGwSWBo81b22hsoVs5nb8UcHDjWCniw\r\nlxVvgOjDhUcrjt9oFws8qmA74IeQiVG6sB/GetXeHC7e40mZFxa8DeO+aG0b\r\n48EyY0S5ngPcMDnEcFl0hU+XGHfDN+QXDC8avyIVb3arIJ+NZIEmyGALGlrX\r\n1ZWtJtVmo33HeHsen7iPEg7tAVTp+OyGk+mpvC8Hlts3c+2znMmgN/xElg3l\r\nPDnPd35/DcULb6VYbE6oGXGMYFYW3v04m0TJGRxQQUNyW74Yxkx3TYGEIpf5\r\nhIOJB1bbzVAk+ahPxWjA6GVzoHio2/7jU7g=\r\n=/C5x\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2301031703.0_1672777797954_0.13065318756640854"},"_hasShrinkwrap":false},"1.2301032153.0":{"name":"@bentoproject/date-countdown","version":"1.2301032153.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2301032153.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"418b16026c82f72bf8e885668d34a40fe043c9b7","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2301032153.0","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-5s2m8/anyRuK9IgLo8NmQBPZ/lANp8NdFgwH0JNJRi/H8aaWQdOJwrs8O9IMSyywHEpsPcaTFVfRHMJ2X6q/QA==","shasum":"adea7d4e57ae3acce635042bbd18e2b4aba90259","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2301032153.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCjPlnQSld5OL5n3raDJYDRcT/LOSs/D35DwgYkYYASRwIgTXUvRkGGKlj/WrM90GwPpeP6sxNA1LE2M8MRRu8jwi0="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjtTfjACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqB5A/9EX2SkjFExtK14RgWan2pwUJmxI7ytQWPbrLilJqeRICtHs/j\r\nr7sAKtKIozLR7zM6J3DSB95w/G80XNi2G0dPfy7CD0CnIB5rNi8elEyXY+9a\r\ngvuL42TbpLWlyqCK4P5hWRKs0O//1vAWC0V/C2yj0Gcpq/9iM/7kM+tMcqhs\r\nR5S7m58XPeybhG9gZLBKUfoXlI9mQcETKpUrmkVRmxE4DEKFqtSJ5MmTx9+J\r\nEgMSam2Px+emxY3NjpSUUrEnYdlNoyx2IXnkluAUid7RU/kQJg+6rAn56C/o\r\ndaZO9g5//8l+ESmP9qCo+xgOrwqXgZiyYP0xHcf16yr0DWV/dVAhExl7YeYY\r\nlIe5gIf2Ne+qYyJdEnLnzftGzWzb0HLaTW+0+VT3OBk8syfTCbczTL5eT7FK\r\njtqtzbtKMeqabA0CK54XYqazwcZbmKhxophKhkxYz8BfPN/GJWmNhwe8W7CF\r\ndKYuSWXHz7GCZDPxkWZPflmQBCOErOmDjB4t+fEM8EK+6YtdxvCv34UwRJ2K\r\nhEN3jxnY8I6+AsELpOggPCYgQa7Lp5lOM7EdTOCg4+oawqQ3UPDC1EwdkcLz\r\nZYTs+EfmXNw/MjuhXhc8xo83xFWLXLa0R9zVZr3ULFQ90zjOIE8Ipf9O4zPb\r\ntNQA20+tQgZT/FFW9TxAz7b7bBpI6e69VQc=\r\n=k09D\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2301032153.0_1672820706826_0.06912575396855258"},"_hasShrinkwrap":false},"1.2301041800.0":{"name":"@bentoproject/date-countdown","version":"1.2301041800.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2301041800.0"},"gitHead":"7026aa71b81896aaf30f29b822e1a578138e33e2","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2301041800.0","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-N9qE7guPbauCFuIbIM8iGwksGBJhTfSIp7kWsI3bzBXxh16wirzggHKQ4q8L4eR0Y7RzVKrorDCsSXEJdJ3tpA==","shasum":"a09d0938d7497a27dc402b4e674ebb3e43b5cccf","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2301041800.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDRNpY4K4iogKW4TNR4nREBhpwpmdsqJH4+SmpJfgfIbwIgbZXP39r7y0FfvsOTu2WlgF7D3DZxz2m9FTGfJRRTKfE="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjtomIACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmos1A/8DIsC6qq+VTuhKVnIeEgNyiRBf3fRjXHJJQK/23clq4Etks1I\r\n7go2rVu6TmKLgRXE5LqLwr+zca3O/dVWZ/6XcJ3q1bvYZ3Rk1QdGKZkJm4oN\r\nIfuL7Vhe994fDadDvgkkj2At/DR1VmmCsZ1oIyw/fazuv3t0d9bOeSNlJHSH\r\nqWztJLCjYFiuRMJL/SkZprqfsqoBMZVoFdRcPDOihP1e6fkw/nkk4lP2IzK6\r\n9aOV2rOFcKCpKP20ubmEd/gDAciGXegSJbneeuykXNu3AK2N32DSep0yGEk8\r\nIhvvGI6jvwk3Fd/pT4ctBA1zxf696UMaYoefBmQgG4VSujP85hoyEJEGYv3a\r\nj7HIDzxgKAx1G8cjVKO/0hQZ0YpW+Iq50U/ms0CCqyjUlk/UQpLB7o9sjeAx\r\nxKiqUhnrvzGWBPVYrswfjHOuzT4DOFaITBixWPYUaaG3a3CiMSoZBxTbsNXN\r\nUHgHOKggj9CNFqM3TSDAgmEW0pVd8lYjvuQZhui1nAnRbpdThDg5Dek/LR+m\r\nGItbvfymSQ7yAIgtpzh5Zb7dPNPnpiVrBOMaSxWMVNVXMrZiooI+Wcm5uwPE\r\nIzDMHLSZSg15Ve/dviGI6Rd1Vn6bDTSN3YiwpaUuIwRBlgdLDLvyxMiXZJCB\r\nxY/xyF/avR56TNmBzrFQ7t0FmdL1p1SMJ+o=\r\n=3k3T\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2301041800.0_1672907144437_0.24220988462794502"},"_hasShrinkwrap":false},"1.2301100345.0":{"name":"@bentoproject/date-countdown","version":"1.2301100345.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2301100345.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"12a8a2eb9a3656064439da35b736023090e7c78a","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2301100345.0","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-Es2Yx5uJp2S/iAihg7TwxEp3206myeG3ocTrJ4RT7oEaVFSZD8m2Xo0lgUY4sI8PYFDvD9Mz0oM5cxSP9M7FkA==","shasum":"1514b0fdef44039339cd18590d46aea3d9d2e10a","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2301100345.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC27DU/qvvEh2DJET8dYah9+iOrZ5tr5kZwUGZy+EcvGwIgSFzcJQ28tMTo1hy5Xk/TouOd5+VTUoa7Xz6Aisvp7VU="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjvSDrACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoywRAAoSh4MF8eMDtp1Qnbo5LKstGqML0LoISklKxoN2CnXvgZJ9iu\r\nfZIFDbjFGDifZsgoaF8CkpXxXqnZEuIN2RjNRkilIwUeGHGo1dDwKHvk+9o6\r\nGc6oyoVQ2F1wKlejzhMNhqvfOPClcIKVNFbLWs6XdCMZ2IE1Go3xcmxI4Qhg\r\n1USU5iUktmr2BtYRPcqsaQcDrgXWSg0LW49AHltfhdGnbMaUrgMs5OlKD9a0\r\nEZthNa+rhIhjQdJqXjr3/LjoFpTEdpKFSzj3d1TMSXNhczG5GmKXICVMia52\r\nusIkHLEKwkM8K8VVYWj/10Zxhx/jbsgRnrKBHUhBhR0oGCHBgQUkU1pfuUpY\r\nYqK4Zhd1jWI/+1f28NBzYPqMFpXNW1cTqZNu4vn57QRDY/kUaj9G2b2K9FXi\r\nsQ6yIHsxkRtNX+Wzi+d6nzuIDqVdCEZs8wKBIrdG008UGSwF4yOLqVk1/pJd\r\neDiC2wnZSpCNHpeD+WXylK8PM/ou50ijqdeqzFtRcjNpyKcDZEUQOaxKS6F7\r\nMukOQv05MDH3dpcQklA9pnR3RatoS1UPGBFdtaNY4uwZYM1rZ623RJJ6Dkqz\r\nAdabE3JhcdjjZRNHU4jXVZS11A4rj/0YI0c4hFWS7KS0P6aK465MIniv/Zxh\r\nYWVgmsV3D9MEJmqHPQ5mBAQ8VzmGPK/IbDk=\r\n=XG8K\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2301100345.0_1673339114827_0.3244072533430251"},"_hasShrinkwrap":false},"1.2301112346.0":{"name":"@bentoproject/date-countdown","version":"1.2301112346.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2301112346.0"},"gitHead":"290809452fa1006da1ea148fc925beb127bc65a4","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2301112346.0","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-NhBWvkXdyS+bYvs/rf1X7iHuYYZkD599BNNAhOWH70hbMdmE/l7qXpcvTBev1QAm5h8GlZhK4ESQo/OnU1uvmA==","shasum":"94dff0e548351972fcbd1e3675f99bee3d42635e","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2301112346.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDIDM4xqGNXHAnASOcBdLS8lettGShS+x3uVDoTybJGcAIhAOFQE1gNvldAip4w5JLlSFYfJfDZarGWwOnujZVNLGku"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjv8Q3ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmqu4A//X+Sro81oGtFr1eMud0k0qj01ygPeTkD1pDu9vpuiCfkp1J3c\r\nWPL5UqI5IeQzFWqjvp5f21ZRXwGvC0okEcEadRNX66JGZ2zTFFYRYyM3+mJh\r\nwm5yOjo1u9oiAoWLut2gw/d4oQCKdb6ZeObeTG0j0EGtOwEfw1NIU2hhybLj\r\nvtHmQUc3dvTJMxwxI9MtbuMgdEWZ4Pg7ha5PrfQz+5Dy6/Z3deZVkd1gwW5r\r\nAFcB+RLHhzgHMW5fuByxdN8qmTP7LHsZkQBXXEAi3Pkmk91G+dtPkl65MOWQ\r\nhts3soApdaxRW5OGcjXnIjv/oMtV67HUVeEbhJoRVLSwyUSoGeCf4sD3eHbk\r\nXv/GKKsooIl5sDhTJ2im+LsZCNvTebvku8tcYCQ+ZLdkJFj9m/Dbme0jCbsp\r\nuGhBI2X4adED7rvQMCeT9vkSFi1ZAnN2/6A8DQSleHSAeqt+QPyJ/2J76Tqn\r\nt+azniGqksdH84b11KWFIjAofkGCGXVDNPJtDq6hBap2xC6t8WHIbuZkPsN/\r\n+l0rjO31qcJbKeC6TPz0sjQrLplshYpFh+9IDAlZszMACC6oI+W738+x9N8z\r\nkzuPm8kQOYEJHexNBKoTYke+xwoCKCCB4hSP9UdU/aWfMPRWF1bWduUa9B16\r\nJsEugDlE5E1M881KXjtABz+g5/pcIcIgYFg=\r\n=5g91\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2301112346.0_1673511991764_0.3989566619547207"},"_hasShrinkwrap":false},"1.2301181928.0":{"name":"@bentoproject/date-countdown","version":"1.2301181928.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2301181928.0"},"gitHead":"8d4b04c8f4aed6f3fb83e6cdd785a334ecaa8a4f","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2301181928.0","_nodeVersion":"18.13.0","_npmVersion":"8.19.3","dist":{"integrity":"sha512-C5a273rFJD5c91A9MKn0NcoKV9T8jaL8ijvgG7Is5kaEPr/9Itc0KFj2p3kVIowQI2obNyQ1WuPLsQ8hS96gZA==","shasum":"994dd7eccf62ae458b2abb091baf20ef021bcf2b","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2301181928.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICUqDj7i2iIlGhOh0raJeIS38zbJD3CvRTiidMG8iE1GAiEAwNW670HttfM0CcIHfKGGVQvEupQF2wfIjSty9ud3fIQ="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjyP6TACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqJhg/7BE/UTWp2C1OEuhckdY4L7NxoYyZBYBUtghhScnmhxjBp91nu\r\n3kQlD/JoBLYM1vk+PFuxy9jW6m+5ZI1BeAHhmgkhyNmbYOpspi/m5ndgntYw\r\nMHil7SGhECOGBuPvKO75DNYjd44H4r0FeUCLlS90s/tpIng9E0tsW3LHMKL1\r\ntJ1nOjEL50X/0hCWFAG0tGojC/Oat+LQTmmhwLpQgy9JQh+QK6o80tWJNvBt\r\nKzxpoKSxtRWkqqJWA0h4h5U84ZXYWTG1Nqr9U7lk5YuQvt9VdrK04nTKAt6f\r\nuVy9D3Kq+5+v0RX4KEEFty8SITZQK6G+cQ5rXQxMH0YgIlKg3dWSHIv4kBYP\r\nIyhp3P7JOJ9sjyG77u1hTAvSHD0jYgkfm+rtNtpqsBxfDfk8Hnii1kPDXzsw\r\nkNPIrvtfpBys9PmG7kJjw+g4t9WMZd9fi4fAkrVgGrCLutxIOA07wHFaO4AE\r\n47rusw8S/cZf+n/kWnJbRiMIrC3mUt0uF/lpDrw30vIiVhE3o8hF+2ms3HdP\r\nh57NzfRDFjdH/2TBgbJewnWdmOtUP7pI2rpqc87yCAEcO62mmRDxpVF69Hww\r\nighRpwbL+ntqgENIxtYgmnj+6DOfrSM+Sq/MWWZdpVMbP/w8EOUZ2JMSgFnr\r\nsY5fUKlYIWVa4LC+qqJ3vDsSSyVlW20droE=\r\n=flGL\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2301181928.0_1674116755149_0.5227270229606189"},"_hasShrinkwrap":false},"1.2301261900.0":{"name":"@bentoproject/date-countdown","version":"1.2301261900.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2301261900.0"},"gitHead":"a6ea9dbc37fe6d4b0f68e25838c857835dd4f7e7","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2301261900.0","_nodeVersion":"18.13.0","_npmVersion":"8.19.3","dist":{"integrity":"sha512-ivauqO2YLoD5RSqitAgwS9Z4RIlSI3h1Ky9LLhozsAOwEXcNcTTUtA0XzeDJ9eTao5yaNNysXmILT4bYzD8yYQ==","shasum":"f0ff02dae7921199b127c3b11153bd2603e47650","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2301261900.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDoJiQOoOL+FdH06XkdGz+upvoGJQIFfsjxRHKHzVtO3AiA24MnLaAX8Nc1ZbTM5K8fgqEdRY0Y6rRDMM3qSuHtjOA=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj04q2ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqHqRAAkJY3UeetwS457V0kUKX6D8EjzvJ7IBO1zxojUJ8+lt85h67O\r\nBHDh358Vm9uB83qqEUJAQOppbx73wpr4T3bjj8bMkCmY370TWYYduxlsygQL\r\nAtW23MwIodBRr/eIKkUi55x+XbqpNxAKoPWYMZMK/Q+N410k8oy46sRhpG77\r\neX4DpoFzI7662ug0ncoLg96SBIRIHLfGjfwenKoxVPU+w6KRkwiSoO5F+hvA\r\n4PTxZdRlCFvM4MLK0X9GvR6/D0ZU34LBGgcWAoXagsBA2dRHWvucX7LsR1ni\r\nm7TP5MA73nuK1WvrPBTJS3j0f2vj2ScdSoBX193Yu/3q5tjS27NXvRMquXFX\r\nhEqHHO+2QqIMIXRD0GqgNCCFrClYU9rEvRZ0zys9u3c+N6X7kTZirfZIgni4\r\nza/LapNdBLo1XBq0S+gdQB5/yh6Z62QZqkhBIuQNY2yMgw0eMJZ44Zy7Wl9J\r\ncs9drNH42Zdwax+PvIFN1DZJvxsrIhTApNNujyY1mKfRsUQoEdjdD7kbZ8UF\r\nK7YV+hV8v511H4WdQcFe8pEX2SA/cjGtu4R2HkzTBI1/VgLiy6LB6VZWbpfV\r\nVbyjF6cTDlcQi3P3NA6TMOmq8c14uCxbD1HlZeIpDoSPBkizTvw1Lm9j8XrT\r\nhhUEk3FK9vLWz4WPua003sB3bbxRmhx0lwo=\r\n=Bqos\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2301261900.0_1674807990157_0.6228478155578707"},"_hasShrinkwrap":false},"1.2301301810.0":{"name":"@bentoproject/date-countdown","version":"1.2301301810.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2301301810.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"06d7a2baddf76737d7cde110a7b4bb9351feb38d","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2301301810.0","_nodeVersion":"18.13.0","_npmVersion":"8.19.3","dist":{"integrity":"sha512-YG6rkb9KPAXZ0+yCLKdNJVYX77qidt3czna8siiO+9iqrLabYYmZNyGmdRCIYfTcYVGRt/75csWJd9/84E3UgA==","shasum":"d1481f6f6330e6f72202e513fdea8af550de9317","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2301301810.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFXqWUxXnYD15qXgrSth8fWZ+xEi269Gpg7cKNikIePFAiBg9+YXiozVGfxyqT60S88L7e//+HA4B5fB3ffhoR7LXQ=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj2NCMACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmob6Q/8DgcY9b9uR3K6+O+fv4z/enWHlPfMPUHAqJT4NdnL5BmGWuxU\r\n1ADY6GZHboUtlqAfJrlHn0s6vguUXWJ3PHXPPBS4rIjT0Q1YNpiN9hH78eqQ\r\njA5UMSI7GwfwTfQw/vPld9T6EJWr0XsKdcKMafcv2gtHNNuuAzxKInUc8CsA\r\nBI9RPi67K25LSlGSpnl4jmfCND88glm/OOsQXPwxNxmdHnQ2LnVNVWYpE2y5\r\nKMnpd73y1uZEfnGpPWv1Lonj9kVaWq/yRtpHkHpFCpT/RnLUgiYvJ+Jt9u4r\r\n5hJriK/8/z/SpAUVaVV9UV9cd37I5/9lPXEZXhs8exc/uGv/wURUkmhi5I3W\r\n0IMT+FgzbMttnGAD7jyFueoD7N5Gaw0bEPUpByRyTXyFqjl1O1x2Cf+LIEO1\r\ndeqaEcyGajXxITJUjXr8aypXru23kbt0+UnuK0y55jd9k//BnE4YAY+qrinT\r\nTydsqE3tjRdYs99/wIj2HzuvwPF/eYwc5PYKs14vIM5WDiXjq7IRB4wnU1I/\r\n3eiw3u9CFbOJGCbgDpb9mRj4d8LAPJuVe//9Q8LPJ9BFBEPU4l6rbEHw0NgT\r\nF5MfP2iyRxOgkq6pLm4zN9XNR+8Dt2M2oD9zR6FYC9pv01NHSM/uKWZljVvZ\r\nRETjz7RUj41WjzmO6EhqJ0leK3ApC4CrGfw=\r\n=LMxo\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2301301810.0_1675153548727_0.33438338662965483"},"_hasShrinkwrap":false},"1.2302012254.0":{"name":"@bentoproject/date-countdown","version":"1.2302012254.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2302012254.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"e4c14ac075b71415995f07a6bcc3ca93a8af5cc0","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2302012254.0","_nodeVersion":"18.13.0","_npmVersion":"8.19.3","dist":{"integrity":"sha512-R3zrQWwpnkRHGN7EYejCjC8fd5EPeyMTy4acGUyAH0+z/5tM9kgeiE4PQ+bVaQ6LD3dqa6QW2li+MVNIPaNbNA==","shasum":"eabba1236e07ab4d133311ecd5bc298d086a34ae","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2302012254.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDc9HeWOBPElnK9K4mEa+OfUjmdEI+dNQ3X5q7Z4SWd/AIgaceaq094fz1P7zPPH+fLqw2W4hFps+OIf7t0uuatymo="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj23MxACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpbfQ//e0o95DIUM+MA67eIDwQCAMDIXVEAplJTKkoiku5mMzzH76Ex\r\nvS0exPQhFej50E8b0boFiyQgi4qtuRICN6JJzZwxXqdEOSKHKkwD6QnRhPrb\r\n2DUY7wGmkSeh+WfHhU7YLtz5pj08ZaKws2nKSg3NFzFOFWXgUB8zRYq2KEA5\r\nZmF+J4NHC3qjULldqCdZ4Q6hmVOPE6am1jMrTuslsZkvDMngFF2Kqsn4qI+/\r\nPWfUPAaTySP6nRMhaCSDyCQ06iqDGpAg8FmNBqoiRAkrldf54JAmOiWz7v/U\r\nli3eAWmXg8HWKatblSTdpHu5pOWaaWn1tEbGjAsuY8IQa8oINTYb42hJZWBf\r\nDO+y0EML73OwgRmhmKETYdcqq0ppBRi76KqIliLQG2URar3uTDZhfcTuKxOh\r\nTSfCCtQZ091+HFaERyhRFB7ozY+4ip4GOnBDC2EWGaW6k76IjzMH8z9iF8C6\r\nyB6s2oeK/ryvyjTQWMHsUY/bq38vJh/uk2hTscEwJorOs5MlWgoLrWN3o6+p\r\nCX1sJPSmn28an1bAPwT/mO0j8zIR7hbuHA/yiPPIxvw4VwRpsW9++S0aLK6V\r\n+10lhCwfrjCFPwS+4Xv3DEyewC69JQvTFCvW5MM6ezkUIfc/uw6dNnpNxhDY\r\nm9Fvfi3zT9S9dc1gY1SGZvVEOHtI/48WPOw=\r\n=XycF\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2302012254.0_1675326257460_0.6459258749846195"},"_hasShrinkwrap":false},"1.2302021743.0":{"name":"@bentoproject/date-countdown","version":"1.2302021743.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2302021743.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"a27cd72c15b628053806c94efc4c96730603dbd5","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2302021743.0","_nodeVersion":"18.13.0","_npmVersion":"8.19.3","dist":{"integrity":"sha512-GT3SyI6wgSo7+3smWS6XreSiL/2RATvxCHXf+8emTW7uyOqeq0Qz9ho22hNxCdYw8RYwFKvRkfIXu/Kcv9SRHg==","shasum":"8ab9e5e9189703180d0871fddcc8be1d7ca7e934","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2302021743.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGVzxptqANiTd24wMB0/9fL6W8gSNpfygbN/Ok1iLgNhAiEAxG0IGYOwxQG8jM/dY20nAhbku1l11u4xg/UertZRocg="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj3MUNACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoCaA//dfka7xb//J6UcTWdAdD01Nxe79kp21H/vlxhqQ+rkHOhld0b\r\n6rMu51t/Niou8sfCWYeY2m7GnAVUWEUPLjOMH5ndpd2PGcnSG6v5if+Qqc7e\r\nfWPk33t119vVYPJASME7h91qMKfi+Jp3GVBspOA7wjUEnem9X8QFMkmCmkJ1\r\nyMK7RzZPXrbxsbnCtx40QrvyPBcTqck7yDy+AjsWBxKpKI7TilHzX4zylZQs\r\nGNykAp/b3IoszIFjJa9dk6mfE2bcKTOe2ddeswSFGLcRcBfk6UeHMAAoGGw7\r\nHPBj0262L/d9HKW5IZSXQBGegQlft65MaoySKX1x6KwRiw0z1KTRLgCP3qz8\r\nJ8GfSJFiHv6ASt9U0w07I+UhoPVmVUMSW/NcB02c2abcQzQpYJojpLvMur+S\r\nP+Y1HcCsCcdl42AGN5fgjCYOlNaD8CYYpPX8j9knqUiTEqgfl8bpmFt6QVkh\r\njX/6zO9NOG1pranEB6ZeRSD6m104XVxYkanorjSAuWzuIszgpKdmBotc39B5\r\njlk0YtLpYWx/TWgNwC4ob7v3IbZB1fc7SJUVhHRs/SxGpvDYvVYD05J34d9r\r\naXqC0sGTSmDKlw1MalIgQoDZo7NJQQlqIEWumzI3ug4DyNiM9OwDDI2Sah2Z\r\noSYLTr3+1sSiO9lnLzsRT6Vvf79v9rJnKiM=\r\n=Lpzg\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2302021743.0_1675412749708_0.9498561293854317"},"_hasShrinkwrap":false},"1.2302031721.0":{"name":"@bentoproject/date-countdown","version":"1.2302031721.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2302031721.0"},"gitHead":"f8cbfb0c4e4db6b8dea923c0afdf75aa7888e4b8","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2302031721.0","_nodeVersion":"18.13.0","_npmVersion":"8.19.3","dist":{"integrity":"sha512-M4hIucob2JJwopjw8ujqibXcH9TCrlm2zCiyDcADByBgFRotR7rK6JnhsWVXeazRo3V9H2oj6hjJZzY0nhVE5Q==","shasum":"192f40ec21e8ad7f4145ca67c6ae3adbcf9b77f0","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2302031721.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQClDhoF8qLRwNRofUWX87xzX1x7Hh3wtGloj99MGDM7jAIhAIqs6LX9//95qiAAcP1GRRlIsi0/Ewn4XnFQBJHD2QmJ"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj3hY1ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqH5A/9HVbxfiH8+Y3+AtXpTNIQM+BQY3999qy5XZEaaldMZ1WRSzAm\r\nyWS1Udr0lhLQNP1YvntjnSwl0dFc7QfHaDSA6EG1eq8PwGSOdQJNR3ovJJ8h\r\nj7fFYmyS+bLoA7hWeAY/FgtnuNeUu5HOvw2cadcCls9iDSX3CwsEIn+Ywf50\r\nHPRz4HBsldIReXQuvCaEJmgJ/7ZhEdH+j/4POBSwGT60B/3xbnvfh4fHx3PT\r\ne+zjZBZ3qUSFH16fLnVSqgI2vqLLAByjzxq+T55T0Fs9WBzHmz32/augK7Xj\r\neRy7r1woiVqJkqwF2N+rwzJNNnB0H/j/wQcPhkcwKKLp54q36dwa+kqOflJj\r\nLVUZtT+OlYvPtDvbfwBYHy83bTjYHBAuQDF+cp8JMxMGSiWbX+6G4iGznv1d\r\nbQRxaGGvCkQ5w3XwgQj9SXXvIJ954MddAANIMNK/aeZTf7vFwiZWdXQTyKzX\r\na7f12qq36nPYm9JdRtx6xhiVK7kxjEWgZEHAlkf+EFIbOjYWsswuojJCUdV9\r\nU8S4+Sg9ClC+uEQTou6QGSR0DnO/2LcSq6kbOuW8Ku3rdhwWQTQeguCZbK6y\r\ntxmHUeH0vxIgbSRsr8b5AR+bA9d2QYwN3KJlWUJTFhTCppuzD9vDP6gOU75E\r\nFEifzCacW16bQubHxJmOnXxMb0XiIte/NJI=\r\n=0hoH\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2302031721.0_1675499061308_0.8700664122595003"},"_hasShrinkwrap":false},"1.2302171719.0":{"name":"@bentoproject/date-countdown","version":"1.2302171719.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2302171719.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"767b9ceecbb9759948c2b0db6f66c49097659f98","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2302171719.0","_nodeVersion":"18.14.0","_npmVersion":"9.3.1","dist":{"integrity":"sha512-H+i8xOpMBLeNHKblh52x+tGxi2LhcOoKVk3nr88hvfgDBlUN6iPdV4ElzXm5zUlAbpqaauk111oALmVa5y+H7w==","shasum":"3a6cc27d909220c6a40471936579c07f624f92cd","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2302171719.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDlCK/kUuKRVvgU9UeGp8GsVi6gQGepQ6mQ4ZXma3ziRwIgcPpgYk2S1fS/5ceOOWdIwec0nV+tuqZVkQe4OVsuWAA="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj8IrgACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmorxxAAoOAlu1rTYdVuamxDXwMCLMZIJIP4F7UJz+BKH8HPfefEeta5\r\ns+qzuAIAn4+m8peilr9qKhitjpDYhmbm3y7dNFa/1yiJUP7vdxAowsPv3jNp\r\nUrPqhC+H5jfyzH2c4XSWsIO0mSVKUoBtCT6GjwkDWtaH4Z/ZzY0Y3CRDZN/D\r\nTsGZOU04+flK42eHut7sug+UPUDYqgb1WabyYXsTBv6f012PJpDQfm65ib7n\r\n0XuOv0O1tjynr5aC+LH8sqz1TwU70+JV+qkeS2EzldRJFUZLKG4PJZd5WDro\r\nqjDIRCizpd15sfO75+8hU+5pbdpVbuDkXehZPnwfbnTqvDGMqZzyl5mD/lnF\r\ngpKbF+I/jkpa6IVTKV+5XL9UDMvvaE9XdzzQgzrb5KOGEYzYQsWv/dVtGeMP\r\naWKOnRc+3mHuT9l+9doOgqTQV32AbjtCz0SYRc02zmTyFoYOubFbwlqo5bHc\r\nbcjH+1WwCLq/kD1rkQWP0gs38dHgy1hg97D5jEPK50DIHBoOf9m2qr7kst98\r\nXbUoThl7kac3iqDtC5ZZ/kWz1qo4rW9Rpqgj9HZ4vh4odBvC+OK/+MuodgBk\r\nVl+RG9yu1xNMKUVTiK+T4Oh1yATPlHSMyYeser1GknCWDiAuEhE0mS4WHo4s\r\n7f5gvUfWNSOb9NC10qC2DRxX1al8eJZTpTU=\r\n=+MYq\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2302171719.0_1676708576480_0.5898181955016679"},"_hasShrinkwrap":false},"1.2302271541.0":{"name":"@bentoproject/date-countdown","version":"1.2302271541.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2302271541.0"},"gitHead":"13cfe7f4354a82bebe08fd29496c4c7de848a18b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2302271541.0","_nodeVersion":"18.14.1","_npmVersion":"9.3.1","dist":{"integrity":"sha512-rolPv1SMht+BFFRxQXwpD7iGSkzypanFcUPjnIWdG7Dy7QUkaI6QrxzNvw1mPcgfDDIua1BKm9muAMhWl1k4oQ==","shasum":"2279e56368f660b282ebf1f5ce262755b727cfd4","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2302271541.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIELFZe+m9m+6HhJ9TNh3WFyNMjWGWaw5cBDjy3/e0c8OAiA5TKljXg1rROBbnkdaLJwGcB6KMxYw94hMNM2KZ8qUlw=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj/ji7ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmorBg/+OnKUOoFfOGqu8wex1GqVr3PonKoaiSHFrHth7QT/AX+HRC7a\r\nXrQTJNgbS2bCKJGPceTL6naqNpX2AQpehwmRhwlAtHNix9twi/LUyvMUftyg\r\nDKHXgKJm5nrpl44fTS6bI9Eh5IH0czcuapaOd6fbVzI5k1qdr8Ym6gHzbR9k\r\nNs5TjXjqKMQzNqUdM+F5kWDVw7X/zcoLXvpiKNu70SjYZbvxAkRuygWkFM5z\r\nz81vNkNcNfJGO43lGorFwJtuF/yKcFWHyWTTZtiZkC+kPzQpgVMnjDXfycav\r\nmjN8ZUWO7tOkp3ScgM2/scXDScGU9H8olOzD8vzvHQaUTnm8UX5UoBZ0xWOh\r\nDGKAFP/6MhXGBK/0ZCOZ6ZZ6WWbujInGy4ZVc2aDSD8jHfpgpgE55lTfFjya\r\nX9o7CMEULqZJvTSEa1BxWOsx77BHnyLbP0AKy8LUagljCfBg9AQoFTDZjHTS\r\nxHsmb1Fus2nLF+aAti3i1gy2SV7mdDH78E3+d2M5qAhvARM7rGaaLiwK6mkw\r\n+Rj3TQ9fzAsij3Us7hIVGBK7x/4++lxTdfszsWdMTX/8YbKeHLdrDuR2a5Mt\r\nD3jYd2lCHrCAhh7WzYjKQiPFqnGKKtF6d0jsdlNAfI19VASXYSxpfGLbyqzs\r\njGSSNBem+ckgwxF5SrnW3Mw3TnshG+6NyNg=\r\n=JOyZ\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2302271541.0_1677605051355_0.15929581558317474"},"_hasShrinkwrap":false},"1.2303151529.0":{"name":"@bentoproject/date-countdown","version":"1.2303151529.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2303151529.0"},"gitHead":"d02f1bef730eec6d78d3f2fa5968ca88a60acf17","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2303151529.0","_nodeVersion":"18.15.0","_npmVersion":"9.5.0","dist":{"integrity":"sha512-oikp26byFCRyo2sj3nUXz+kUAiBaZjeHUdhTxwY5R0smC7GG/rrrw1FBBwKPu/1Ue/9pCM9vR6yvBldBlMVKmw==","shasum":"f19487f3a990dc87de66a05da062fd2f4d1c159c","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2303151529.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHxrlJw5uQVfMR4Z9om5osODnaS6xWOXKDKxiC+Wvb59AiBFN977VXoC39XbTrf2eNAkbsEFVmuWLHhaiiNK0MYstQ=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkEfGqACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoPtA/9HkBS5UwHOj4cSoqmhHHLUtymblte5iQw3PxYtNKXr6YeAGgC\r\nSKWFm3ui1pplxJwAT5KDy/qDCo46bRuaruDH3KRIrlrJbn5LRmxdShEjHGC3\r\nWlIvFiasqVjqWmIoQh4v1B3UJRocB0u1O/zIXCsNSrr9sFnfqlgcHWXc3x4c\r\nAD6t3Q/coAm0O5Wbf0mDpHha4+hFh5H9APAfyNTCSCC9ML3QLAaD3gbmt3dF\r\n+YGEjYqEfADfTLOfRiEePavi0ADFazjeU91osPTt08PHn4gH/+3n5igE7g30\r\na2JxFu+wxBWuBTzMmpwozcofprwhhZA4EwSQPezIZIdmU20OUF2Oho+oVtfU\r\nBWPK5tcZcNbb5x1Ivtoc5Xb0s4wENiqCFqxSLQRDOpUytMUdGy+kHh5SjgKM\r\nxwuYcnCyoZFBF28sNPj9d79/cE8zWAohZtczev3grQcOigS7QU2WGJIkffMn\r\nZLwC/3Fu0vuL4aj0DLNGvnzKIElXOZ0zB0Gwg6/j3yHUYgmrBF7hD22pl4Lg\r\nKQcZEmfx0dXRQNKLinzA06fsCWajINs1d/LhXzOVP/H0nW0cSR14ZcEcNqaj\r\nYgdWmf3GaJCPQDFuAX314eHDGQzecS0DVawajXncxQFlRJd+qGPeQKp4KBrp\r\nt2uE9fqwoXku3/y5pDrxkB3O34IP2XOcKD8=\r\n=jDMW\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2303151529.0_1678897577785_0.25708680547717133"},"_hasShrinkwrap":false},"1.2303151621.0":{"name":"@bentoproject/date-countdown","version":"1.2303151621.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2303151621.0"},"gitHead":"d02f1bef730eec6d78d3f2fa5968ca88a60acf17","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2303151621.0","_nodeVersion":"18.15.0","_npmVersion":"9.5.0","dist":{"integrity":"sha512-F0sVkZg55tuOy5sqIKb55RzbffnNAwLgI9/70HzvMqF1u6hLLZmb6KdhqpjrtvOIfnzRyl+TOUy032iGCbuQdA==","shasum":"193e7dc1a53c1afea9a421844425af2d049e3653","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2303151621.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCGWG9eG8s5YrOktvKDoiHHTslyQlRam/plgsNH/iqOYQIgFhAZGy9DpQ2lywznubf+R3xp52kpDyr9tgWJLWHDIGE="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkGrs/ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqXBQ/+IcAHKyrq1W79+spaXTJ5oq9vfGLxNFwFECAdWXNEvohDviPS\r\nbJ9yGEnxuYpf9nddR+RcN8FW8J31+vm4JMqWytwTYySdqyb9qkJP9dFGbT0T\r\nPBSAvehqjdyTF8YOb/0YqXvxONWpItUMd6HR78FB2SxIwTx50TH9PAxb5geN\r\nsDwOgscr6vtorG7RYkshgUaBBZCzew2TVEN/jGmCIATyquT7EqTVgONM5YPV\r\nuzafePwy4FCKBZvLIzEWVipCADhfr/leCLefrePz1vo2+eXOwZKOUqZP4IZF\r\n/1j+g6F4lO2l1Tte7qhJy6QQE6wT6nDfNHvfx9inBe0IIBaDu5N2ZcgktMe6\r\n774t+UMHqz4oAkDFg98j9+T46aUMYUpgmCFhzeoHaW+Lx8+za9k+bsQXQH52\r\nowlTferKsiAZlb1GwzZY0p8gxK+73z+hNvBJJVXhpoUFNrMY9Vk+cqd4tHjz\r\nLc8FqXHDC7uuhVHHCrOeTpB6swx6/TfMSkOHZ7J0NlUyl9+t6eKTMLvemzuA\r\ntKtW7AN7aysCrhj7lN+k/9lJEmMUf/fxySr11lNNZjUijdhbhIrGbucMcIO+\r\n0iEQUflzEOOSPpCADTTWzef6IskQ1HeKXPFkD7s2h5MW2D9Lrpa17kA7tYs7\r\nnefNU10e3ufYq+Gi3oVoRw+ZxMDNifimaCM=\r\n=J7Lk\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2303151621.0_1679473471336_0.24862317400379608"},"_hasShrinkwrap":false},"1.2303231800.0":{"name":"@bentoproject/date-countdown","version":"1.2303231800.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2303231800.0"},"gitHead":"bb614003484012cda74511a460e3958f01512a79","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2303231800.0","_nodeVersion":"18.15.0","_npmVersion":"9.5.0","dist":{"integrity":"sha512-XLctJK/aqm1E+I6IHdDSG21kMmzr5N/S53YP+dSlpUp8BP7FWWM8rW8XdPeUwZzcPg8yzCvJVHMSb7TMus2GRw==","shasum":"e568ae8a2279d9a2fdf48fadd9896a004aae71be","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2303231800.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFJsMeckq2L0xCGNwl8RpQ0P2J6IYDDqaMnAI4HHf/YJAiBU9BdF6ZvM9GvOseTO68RBHCMRZUIoGO3ZHJngvj100A=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkJArwACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq5PQ/9EU35BAXsed2h1HXSCMyyBDEjHueUe3Iz6IObsw8K+mufb5MG\r\nST+LmfU0qXeldxqmt11hiMZK0rnoufMCvGenU+Hmt5/ZLKRf3C8LIEdMOdAM\r\nUIvldkOQGXWy9p0so4S1zK46CrmzeRQNW0upZrHNfzmNysjEbxE3gMW31rJJ\r\nJcH1hYDysTDSe7AOP3Pjno5WXMWqdRg6sQp/i2U3gWuZrBKPxSpDEgYQgUVg\r\nhQHstydhwKpB4CdK0jnR5TgIAHJ9mFJ8459ZdEYFimkoMufuRafzuFVKg3Hg\r\nJdSzCuKtksdUH3itCByppWcbaw93GZ8qG32ySJDp18L+gLu+/q7/wV4C1t7e\r\nCgkr0G3RdkhNAczGsH6ouiuT1Tm/yiKsjYUQSHUVJR3jnoMhJ6vq6gkmcNCl\r\nAkuYN34EOGR34g72RRZIz2Zvp8jaAkmGkFws48F1GmbDchZHY6Tad5+OwRne\r\ntymsMgiTGvA9NuRMDZssQKI7wU6qnfeMsQtjfLBEp944gTeBn7onzAOIuSfs\r\nBBg/FzGaa1CRlj9zuKHO/4btKVBvkJYro9Yud1Zm6Y5MO2km5zZhdIM4ps2D\r\nMohEfuyLVYGA7TEt1TkByidQydb1Q3I5znlZxtSzToU6JAgG5ki/dEgkwdfg\r\nZokocZPvxnLGQhTCbUrKYfGushU64NWXOkc=\r\n=MB41\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2303231800.0_1680083696740_0.1095501613551757"},"_hasShrinkwrap":false},"1.2304040531.0":{"name":"@bentoproject/date-countdown","version":"1.2304040531.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2304040531.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"201864e5a81ca3bd8ba23d3a14d9ac4f88d7a66d","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2304040531.0","_nodeVersion":"18.15.0","_npmVersion":"9.5.0","dist":{"integrity":"sha512-YoyMDBjWb26viLXjTQeybbzTtuwiRFK1KfPJv2B2nJR+e/zQhGRNc5oS9rlu4tAPILYrB/n8WT2vUGa1fquebg==","shasum":"d4baf91f0b62a7530787c84f153739e4a24d1e27","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2304040531.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDafd3h9o3a8bNA9yjribU3hVG3ba91IkbOKu50fnlGZAiEAvFov2++mPWtfnp25lBa5tgCj13hlmfktpyUunJmFYvE="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkK97VACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoIHA/+OGwch9KHlzetMe9BfcHWmQutEOl8Ohean0Jf6lY8mwulXUUL\r\naWsVf3dvgf3lOc/f+z+ERMmbCPpNii/D1BCkLtZ7MUC32337Kq3nX/yDBzjy\r\nUu8QLlkFZetkhKG4bGSxa6wTocpQQ7JBewYlJ5ywjD4KKZ5wUqLzcHlhWJVc\r\ntO1nqW8P3wGUGXsP+iM+741mKyPqaUYrejiD+9obXn6rlm8yufM9g5FzQQxl\r\nK3QHra5AjHxBa8/+wiV8xkcHk/PgqH1nZzTNDA8dk7RL+6z2FzXG7fZ1FUu2\r\nXwysc/SkObeQ6eLDgHpswNvLtoTu7pbFu0QBiUn3awTUydtFEZrfr3y968/5\r\ng+WRuRHxn0SuQ65QJbualUIjc0OrwyLrAiPviUrB2xxgTkP6Pz9VbYtc3DrH\r\nAesaI5cOlvFeByTV1weiSqYpmE21/w5JQr3AKIBScKpwuseDtvOzVtDIpkOJ\r\n8TmuGDXcP1d8mqyjmWW+RDWJ8BAknVJZnOXFyVglX+ihd2jtr2Evbbof1W03\r\nG8yAQYm9xPkrcgX5hmJQEBaQAT65FP10Z0SltElx1eZJB3rVKbHYNVXy4KmU\r\nKOPCCo/MTs1TP7/GZSLXe5HLP9xFa0xnScJrHwNYERqt0NgVKzD04B5c7GaF\r\nQTR/3akDdkp9DYu7zD1m0iFLBgpA+5ug/cA=\r\n=x+d3\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2304040531.0_1680596693660_0.24451091495373367"},"_hasShrinkwrap":false},"1.2304062309.0":{"name":"@bentoproject/date-countdown","version":"1.2304062309.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2304062309.0"},"gitHead":"988ca302278a65b8d468409a444b029bc633cd01","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2304062309.0","_nodeVersion":"18.15.0","_npmVersion":"9.5.0","dist":{"integrity":"sha512-ckHSb9Q8WhjvDvWNJ4coSre3nTQRA58KtGbvhc72xppGGyIHMEYA//Z9dpO1U+nGJrAgjhmV6dTjBnen08Inxg==","shasum":"140d87d9a8789f244c1a4946d10710ed6ac8b1dc","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2304062309.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAH8Ciyl5ub2yHpEJh6b5izQyuCxFEM5j6CkhTAQObD1AiBzDVwt1znI4pY5A6/k0J7DmNqDNvLj5wLSpQZW9olXgw=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkL9MkACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq2Hg/+LsAcuQYtq7GRhkdnneFmzVzpVw4XT3Nqw9oGl4CekRJEZlfB\r\nbSo6Yo4JTmKTJ6MiZ/PHOlERyVpbGAjJX/2ky3Caj02O8Jrk4a+xVN9RueR6\r\nDAmf3wYhDYjaRll+pYKCWwEyvO1WEYJHDP0p9UoXEi25wqT8/IgDTw0ItKq8\r\nmHA8qZCC2ti8x2WLtIyYXGts7l8FT6ZvlrVWRl9LhWccN4ImKM8z+8AXKLiV\r\nfAwql9VDc7/oUuW6gB4K+wf7janljise4DtmPTxV8VJ863sJMi4w6NO2SPTZ\r\nVVaDGa4IlYnLriaExcpWTN5KEVJJtbqCt10tpNsKgNoqBt4p/mCmDPRvZNqP\r\nt6aORYfl+pLwJPze2YsKmWuZCegTa86J7M0EgHGEGXOMvQbdpedMK0GkJJIE\r\nyWRco/dBaZEZhfUfcUjCHvQ68z7qRw8/eU1TaBLiY9cMAoV6xX5Il6BanK9i\r\nRkESST7+/fKHhBh4xBYY+j6abzvzrvS0FMfrZzLUfpet27X4p5hm9+2WBffU\r\naeADw3c2MLmOXQgUAVLIYGR6s3utEuMBKoTqzUt9lEXmkwzkz+r2Pbk9zfl7\r\nyeDNwkMepRLcoOLm2Bk2ImRjG28Hhp6B213sq84Gk3GyH1gQK8zHrMGvzVxE\r\nS4lO8BtR07+pJFTjTpKJunhdoAcBLlnjlNs=\r\n=Cy85\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2304062309.0_1680855844337_0.8679473087681062"},"_hasShrinkwrap":false},"1.2304122229.0":{"name":"@bentoproject/date-countdown","version":"1.2304122229.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2304122229.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"a622b88bef291701e9f95f448f46d014e6e12d5b","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2304122229.0","_nodeVersion":"18.15.0","_npmVersion":"9.5.0","dist":{"integrity":"sha512-6EfN+PUW0SKCUWYn44QF2zuwcvPJBCAELCOG2PmdsjJJn89eSSnyNdr97971AnxWwdJEL6xvD44J3kUSUE8F6A==","shasum":"7ad2f93b28d93c0a61c332483bc9dbbdc783bb1f","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2304122229.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIA2h7/nrJK0BV9Z2hHEskQVLS9y29XZIOeVpMt8BtgJPAiABrLxPwXFuFht0gVXdmOvdXF2e6JLnXEBVQlJcPuQiaw=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkN7xRACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmqr6g/+JAuYr6DFDZw2sHzHHPQvv8cGyeBVYEcVaxz/ZzTVDG3HKjTk\r\nCr60gdlYa6gSZ5Ff7fPV4/Zc/q1vp7qAptlUeIKsZhz2+pL6lb/AMof1/Z1h\r\nSB1kOakBq8evjTj5bwPh4Qw8iUq2gC8Em17ZYW6rxHWYnk2gCuezuHDHB7qv\r\nxi0QwMy8kc288IJEMmvxrepV0OZsxdB8FL59MRXUAr3QAmwYbw1AnayzDcB/\r\nXCT9eF/esE7/A4uRrrCBGSbTwpmHZyHqT+Y7kerIVwoFym0Nv48Vjesk23ZA\r\n+hPyGF0UJHbbgkFnYL9Y5Tjid3huHIAg8opQ8D06OAiZQMGwm2LoR2Gka9rX\r\nSM55XLpKaPlWaYMkiq3PAj6uOGIuScD0ysiE4wXX3h/5vS9k8SlciQRfsaP7\r\nv36jAsWTc1HB98TnGnnuqZdfdcyxwbKUGvFCY+iM762S1NoplI1zHdRrAffr\r\njLJlHaaS2FM2QMeyJNxhp8s2WAJvkFfHlE6cdwnHtMVCjt3QZSWZIhkLDVY3\r\nO2UKsg7LfjYgUg9fcQqf9H+GGTJcUXhs/MBKopP91TPklRSZbCBeCgTIc2Gn\r\nU05yDSgVWxKaSWLDVy6nYmi1UzeFoAyAvJmiiWTXWI+eI1Ilg3VW0aJ8DN94\r\nRxjihRSW33C70sxriSzP05IViwbbhojZD/E=\r\n=nJ1S\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2304122229.0_1681374289142_0.30665408439121533"},"_hasShrinkwrap":false},"1.2304132133.0":{"name":"@bentoproject/date-countdown","version":"1.2304132133.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2304132133.0"},"gitHead":"453223019920559443567aa4d698b7ca016b28d7","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2304132133.0","_nodeVersion":"18.15.0","_npmVersion":"9.5.0","dist":{"integrity":"sha512-XPw+Wc+aCrOqC49H1M5OPwDkg9kioPfjHbZODK21DyWYt6suIygzoliRGutYNuOv4RK0ALTb5saJTlp/+8keRA==","shasum":"c2965321cb4313a47c8d71fa808741becd2a2b87","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2304132133.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIA/DC1HenzUYxDmy0+pNxggtyhYSUcUX/HH73BEAf0KKAiEA5ajK+98JzI+KD9YPczhztAbPZ8N16Imc66LZCDkaUM8="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkOQ3sACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqO5Q//aqzGCW1IGXxdI+mPEdubF+/1+/N/i7Ts5bRzLbQyJ0poSqYE\r\n9yVYdtY0OGy/Jef6k6gbOduLRMgeTJa5wmA2rP7GZuqw4YL92loZtlUdQ9sZ\r\nvYEHqCHjZZyt65CAL/OMoeKoqE4F0wPgQT7RqnBKYTy44GqJUsugymskezre\r\ntRO8qIKX9Aso4EOtGXtV0cdvP69Jd3afA+H3Wl0h7/sfMBUm078ntktbwZOY\r\nveM1YKLvfiT9hx8cogLJVdx27wMl8PibMuc5H+RsWR9mhtL1luVFZPiFtgD/\r\ncKqBS87MMAYPEEAyYBjy12qouk0xZvJjgltmg7WxL09QmDIkbPxNgaiiSLb9\r\nVlmtsTNor03irusRlMsXpucgNDhXwJ/XRF9EQnBujI6fUl5u1zwdFzm+vuK4\r\nK00nFr9gYo4YP5PbNlGTtvaEW95XQgZrG9HvcIwKJxIXX2qt9u8e6YKE00LB\r\nkAljf1+jY+Ogfht/2xV8Z/NUiDzASaYtsv/+Q6gS6tz9obW0w+BPZboUk2LP\r\noWNPHFVGPL465vSwC5nM43+0WTPdAV0aR4Zvdk0BceeW3irkoYBzSo2y3kM2\r\nvYEn8f0Dbktl2iV6pOffRjUnwGLFMkOhAWbUwnCr67GxPqwxXpdeUZR/skXl\r\nfzebpVSRvxcUB5hI10N5JAt5RbeT6fRAoEU=\r\n=Maap\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2304132133.0_1681460716371_0.24041239780252166"},"_hasShrinkwrap":false},"1.2304212144.0":{"name":"@bentoproject/date-countdown","version":"1.2304212144.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2304212144.0"},"gitHead":"74060fa076cb05cd0859ed848acd32302f1e46dc","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2304212144.0","_nodeVersion":"18.16.0","_npmVersion":"9.5.1","dist":{"integrity":"sha512-/S7U4EhgP0BrHssDibrYKu5rr7KpnAxbKG6L+xFnFHdAvczwYGCH35dmjdE25P5+P0V0APx7vibTZecSrqzhxQ==","shasum":"b2435414c70b17f9ae40b09d5b8ba761fb3bf046","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2304212144.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDeJhQybun+53J98LINGFyofwuS97l6f6idql46ULwiIAiB1mqai2x3iV6hNlXdWpkbJFtX14BS6joRFK1UyoNqxeQ=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkQ5pUACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqBxg//bM7i5WZW/QkE1o7edii2P2FaFD+y7ayFCWUM/I/jCvP+7A7p\r\n1gWexVSPZq9LM+YMb3l7paDd9w1KvRLfFRmwEKQw6Fu+0HVPgM93Xj9C6WYm\r\nYQ83MyvaMPZIX50t95scI3MuRv7z322xBgXzFpYYTuDO41e4ifgZ+HwoxT9m\r\nq13i1IMHOKvmJXWtW9+IeGFLWXc1kxu57WSNilt/Cx/5kFW894tpitaz3BYW\r\nMIl5aYkbUHNn62x0gIOA6J2Gt5iEYC/A32Uk/gMw58DBwSnpz5v6ILjUjyAv\r\nj46wwpPI/lj1F+1dIjM3+p+ZTlcSM1j9krzD/5drwrlZtpPWWdqsJCBgHfC7\r\n2I8aSOIg0Jobnt6Rl3MLbj7Wxzhp8ecP/iry/fCmZSAJRtzdf0S6ZX5quhgM\r\ni5DrMD1VfVrqBmMmQ3K7JuK5pTjzHlYkg55JyTwQ6mWM3097+hq+x/ibViPm\r\nQ0XHBwWqQjAIQKxabuIXflQBVgV7RKoG7v/HM2IA/94tEDtPH5d0507nt/Fg\r\najeACyqpTTcbGoZBFickNnAXMYFvShTAmlSWqkVyMUNUZiVQF0iITKtN6P23\r\nVA2EZ+Ecd9jQjJ6jTWn+3vLRDvrfdgLgs9n892TS/3JoZG7bnfic4GDD3ke5\r\nXalAYPCeW7TzUOiTwNvpLnhzxzz7LZFFY4c=\r\n=qbmO\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2304212144.0_1682152020359_0.36167710168702016"},"_hasShrinkwrap":false},"1.2304241924.0":{"name":"@bentoproject/date-countdown","version":"1.2304241924.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2304241924.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"f962c0db0e4934715d4bbce41c2220e6cc8bc1ec","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2304241924.0","_nodeVersion":"18.16.0","_npmVersion":"9.5.1","dist":{"integrity":"sha512-eD+XFhbd6yE5Z3X7ec/9gK/k/r7tglrUC8REYR9XEukPdV8I5mIul1sWsa+6iN62Ii8CVW+zow8cH5EXr5+5ng==","shasum":"676f0876abe1ddf70885d712c8bd4daa684d76bd","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2304241924.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHoXSSgPDhyitfySUVNM0Hj7urE6RH3HQGRgcIAddaHFAiA8elpiozh6jqgrF2iZ/bSpnBXqcuD585W1lfzb6Y0+GA=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkR46uACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoMJQ/9HogIiuBnRZ8wmzg1xbEJsxaHbbWixOn6Vfz08NDEtl2Xb+Xk\r\nReEVrnJsvi8sl+Ojf03SEOZjw9/gg2Hw2eafvwBf4bgKM+jC+xWyG98vUdGX\r\ntON9OVltUuHd4QD8fnUyW5FDT5Sy5iQD0v/UIai2EA5eLn4xtRVrnLMa5AD0\r\n570S73PM86sYTKyOtccMKZl+6lLbEPJPaFFNiN5vJo+6LMLKdebSAbghIZp/\r\nJYrhnteZunsfjTAj/ctFyAWehX83qvk0E5Odymoc1JyCimbsB96Jx7Dy5SYg\r\nhK7MG9LAHuOizy/SPV/kpVAYDy0L4f/loFvBRyFoT/kakwrsqm7M9V0Fa2Ei\r\nNbfrnzpPE8dHHDjXiA7zwC/93gm5TWLZWIdtAVqb8UQ5m7ccPx5ZSddkyPkw\r\nwmnR6CHhJEHTuROw8P6Y06CJ6WHsyEYVYMAEGduIe2/DeP3kzCn3nvdCtQ/I\r\niU2DfmtQVHsThe1pqADnmDH+U4xJfOOATxvR7jZMDxI2tOsng9xuGtRPwDTj\r\ntW5/GbjqstMCnNMu3iIjEexzXl8wAdbjs7wjt/zu5WdumFRzI4J6zASWZllQ\r\nAi9UWUIyL4GS1kHF34vZimGljSbzmcYc+FHXb//DRqXPhoGVbdEU7ePr/HTp\r\nj7Wg1XolYlmnZOCSBed+C883OMa0dFYMqmY=\r\n=W/tp\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2304241924.0_1682411181735_0.8126490389613508"},"_hasShrinkwrap":false},"1.2304262219.0":{"name":"@bentoproject/date-countdown","version":"1.2304262219.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2304262219.0"},"gitHead":"1e6e00ef42b6ca33dcb23d56bce6506f0b5b81b2","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2304262219.0","_nodeVersion":"18.16.0","_npmVersion":"9.5.1","dist":{"integrity":"sha512-wJUs8/L+U+lnk8s/5YNUgdqT3IdNO1sC1jYEplE6A88N7tcKz5RlWEFoKoeEzS/TGwr77EpR6CiuS7y/P03PnQ==","shasum":"77220223a96e875a1b14bc65260935b32bf10c82","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2304262219.0.tgz","fileCount":29,"unpackedSize":462211,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCkWblGs3gm+vK6zeNkmVvQxbDQpvmFU3/tlOtzLi1h4wIgBuFDqxlFqBNxrAioiLGP25cMWZmZLorJvo81UfadZjw="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkSjHeACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrWWA/+LOJRfrgunwG1C0H3o1YyQJzQnU2q6o/KxHRRysXuEvEKu6uJ\r\nwT4F4jtli6EIx3besrzccSWptYUP74Ek8ekMKSVF3ljePnDpst5emSKHHYMR\r\nU+GmzAa5oz1FKV8l7xhJ52Z81XmYXM01JxOFtKXnAtAYH9KdzioBYrR5uVkI\r\nh7WBcjoIejAA6+U60gU5Z8tISOt+EYzADUl+jjNN1LqB/cb6iinvv3+p0jNM\r\nFSmp7rCQDaKzqJ/Z7GzvQYDonUsENR2KzeawzrsQA5K+zlPRtFRRH2T5XDzH\r\nPPkjvISZn0VLFguaH9ZeVkMx8kvE+og1ZUuBAD86pqFVOpBzy4Vcj6vEdIPP\r\n0la42OvA5f65lvpGlDUDZeQqaD6K0CVyNQON0c1Sxmqs4Gg/Ha18NpppPUlB\r\nXNnqzYVr5EVCIc1PicTBLkyks3TLiay8Z8zhHcdRAn9tpGxJMC1DmolhUskd\r\nQTukHiT2j/dVcxDKw/o/AvGTepF2iiXGvgRlPq2cokb8ie75GaCaDtpo7Mzg\r\nc7okcmS1wFhQYuq3SmNt/zNTvlB56PvV9JblKQJNz0QCUGGFA2uSZoD7NC1S\r\nOu5WMEnPM014h085ZZWLhFpXmrS6g8wgodxAVf6dXzBvRTeUJKSbIvaBcKq2\r\nRPwGgMLDxYv8LZlEE+kkyRbYCzGZCAdBFRU=\r\n=A8qA\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2304262219.0_1682584030043_0.6667087072999596"},"_hasShrinkwrap":false},"1.2305022024.0":{"name":"@bentoproject/date-countdown","version":"1.2305022024.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2305022024.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"275d6cbfacfdba2a626c1c3d191df16325439dc2","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2305022024.0","_nodeVersion":"18.16.0","_npmVersion":"9.5.1","dist":{"integrity":"sha512-XoOCWRoq9F9YP44uC3smm5SwAF3d4tkR9dZsqZb+47yoBqdU1pFwWvpAJO06SBzPnMx4GVsPo8zimTeAAVNfjA==","shasum":"3c8b92b832f5804f75700344790cbe8d9517a490","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2305022024.0.tgz","fileCount":29,"unpackedSize":465887,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCHOwEngy1Yj0EdELAWBwtJkLK+PXzgmMv7qHdYM/Q9kgIgHcax5LKY6DuPnU3QRywZ35w5ulpniO8ckBN5SvMOO5M="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkUhrOACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmr6mhAAkX5qaon6sFLSWp4qptIKu5D5LC8vyGHxx9GZVQC3+OrInL2g\r\nZzQJoRA0D1QoRyQl7cxXLtLRmeQQoitfmKYDGsk7OAe8i76pPzncEBSrbVbY\r\nDEeWq5hAEIpASPKarP3webW0XHspHRIPOJO5f9Rk5IN1FNK3svBj1wpry5Cc\r\nYsePs88TL59qDNSwBeEA0o/Ly4jUzeYJAmkTJpk8CEq0t15eDt/GnBL2ACcc\r\n2NnrglYxgpIBIzFmPE4/OzNG7pK6NDbPUGXxF50NhvNomhKMtzJBWGjYU5LR\r\nFpKMHdBiqiCrmpGNKSeI0QLoxCh7hSPUc7KPPWSxTkWkNL1AbaVUO2cstidL\r\nQknST4SSAaEReYmMyLTK81fWq3LSgJEBSiDRcFDK6Z4yUR6rmzkuxMpWcvDo\r\nvOF71E91bt6JY0bizi16j9p7NZnM4EIV95p72UcLq6kFgwCWBWVOG2GMfeKc\r\nPSVljncsFvinfGfPzCRkfNWjbT74RGOGZKIITMoJr2EijcdhP68x/GJUip6h\r\nROhX+bmFhrJYbDLyJYmB7qBgUQnNigUdaHtSHECiBqwedUeJ5wqAzx7BcvE2\r\nGJTbLlKn19ScjtywNNA4JtJvf183tkjMZtO7+hnRB+n+KwYJFloFVPAscBxK\r\nMjw1Flln3N5Oi8ePtsOwuuMeO7PhBJpkKKQ=\r\n=gLUc\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2305022024.0_1683102414069_0.327011409146474"},"_hasShrinkwrap":false},"1.2305051745.0":{"name":"@bentoproject/date-countdown","version":"1.2305051745.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2305051745.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"a6aa8f04998e5f74539b892e6fde8143851f1ef6","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2305051745.0","_nodeVersion":"18.16.0","_npmVersion":"9.5.1","dist":{"integrity":"sha512-1KFZv/F6jAKYZReNI70ifKKA6vGsEyk+cbyF5q//gj4GumqCbbUXZr38PJzb5u1xH+uVqv2VoiNKdckcapSJfQ==","shasum":"7e7fd73665187f213361ded4f3d6a5a59dd7d766","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2305051745.0.tgz","fileCount":29,"unpackedSize":465887,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIET4WyRaB9v2FkVWqbww0+65ZsszSQSjiL5gx+u8p8POAiAD6zC7SfOnh8HDEZxc83jKagUpml/x6ZrxcZcaFyelcQ=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2305051745.0_1683361477699_0.4279635157889934"},"_hasShrinkwrap":false},"1.2305152039.0":{"name":"@bentoproject/date-countdown","version":"1.2305152039.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2305152039.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"4130d5e4016e588172d11ef0a84dea019bf08e0f","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2305152039.0","_nodeVersion":"18.16.0","_npmVersion":"9.5.1","dist":{"integrity":"sha512-ArAgYziBujTYxE686Sm+NDRn32g0X60VIB3e8LHB0gJVLL/3ohOrTSEdEM7PUO95od/Nj3IAof1StPm93BAvDg==","shasum":"969d1d08d61e33d366764b30541d1f16eaa3ac26","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2305152039.0.tgz","fileCount":29,"unpackedSize":465887,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDwGoPGQO9yELspBj2s/zm5iPkUaFfXZqym3fCxC9Zk0wIgaBfn3tXP21F/8q9kP/31fc7S5idUDOHCvOva+J25LOQ="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2305152039.0_1684225584811_0.06957523012966971"},"_hasShrinkwrap":false},"1.2305182038.0":{"name":"@bentoproject/date-countdown","version":"1.2305182038.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2305182038.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"885f40954f2783f7451ec4e195b909ce170466fc","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2305182038.0","_nodeVersion":"18.16.0","_npmVersion":"9.5.1","dist":{"integrity":"sha512-lE4jlFKPQ3btkQRGHxkLTZ5umVQhBlmDcnSCLTaq59Atf4PAIv7GO2v113KsuYqmIcl43MTs7W2/VO/0x7enhw==","shasum":"eb93cf29a7695b934cfb7dea38a5cc985802a381","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2305182038.0.tgz","fileCount":29,"unpackedSize":465887,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEuMmH8rA03bVPL63ALzauwYTzDhzB7bshcAVmY7ON/nAiBOfYJUMm0r2DTZp/HO6FjC4+4GxjUzNTdgfMLABk/yfA=="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2305182038.0_1684484844342_0.6839699174431746"},"_hasShrinkwrap":false},"1.2305221508.0":{"name":"@bentoproject/date-countdown","version":"1.2305221508.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2305221508.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"f6a823a49114a57cdbf351ab983baaf0bdf4bd1d","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2305221508.0","_nodeVersion":"18.16.0","_npmVersion":"9.5.1","dist":{"integrity":"sha512-y67LiAPqfFHm6H8uSFXO9+l4JW+BX3cFM6hH44yRizerA6j53ZVwm1oZpY0MbKW5R0cElC1pgWiIhrQ8YbIbgw==","shasum":"42cf552cef77b77c2fc1b051625bfb1edb1cf4b7","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2305221508.0.tgz","fileCount":29,"unpackedSize":465887,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCwIWWYsTkXVJNXvYqaxugSBQhSSdtmB0TOWMnJP0DxZAIhAIwQ9drcET+1UWLvaCkN+ReVUBHzQn41vsb4JK+xfYy5"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2305221508.0_1684830324347_0.33447642246620957"},"_hasShrinkwrap":false},"1.2305051745.1":{"name":"@bentoproject/date-countdown","version":"1.2305051745.1","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2305051745.1"},"gitHead":"c7c16e5e6f51fa01e6e31b5edddf60feacb1ebb1","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2305051745.1","_nodeVersion":"18.16.0","_npmVersion":"9.5.1","dist":{"integrity":"sha512-8cSxCRcA0a/gr01RX40JmTmv2DEP0+paeyve8UXfL1luNDs+BSJMm/mIIE23q+aWDTGfOPJXS/fl7Koktz4gqw==","shasum":"274fdf6cdac44c1de3d99dedbbb38048acbd64d2","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2305051745.1.tgz","fileCount":29,"unpackedSize":465872,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCID+c2gvRE2g6CKlghbPVNOllb0Gffrh9P5cYgxi7y2AjAiEAuYiMvHGGPiriyoJkeqfb0ClrDj81pguVAIwWogQdxuQ="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2305051745.1_1684882992028_0.15322754652250947"},"_hasShrinkwrap":false},"1.2305232041.0":{"name":"@bentoproject/date-countdown","version":"1.2305232041.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2305232041.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"c7c16e5e6f51fa01e6e31b5edddf60feacb1ebb1","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2305232041.0","_nodeVersion":"18.16.0","_npmVersion":"9.5.1","dist":{"integrity":"sha512-nQQFMxpIpi5V2B4imTtnOR23ep6RetZPLq8+mvoIhb9hMBK8Wj2UmBU+D9BKr9SDWTb4S/gazMwC1DePidTgJw==","shasum":"801e9b5fb14dc37ff46c1b6198b99a955390348d","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2305232041.0.tgz","fileCount":29,"unpackedSize":465872,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCOcNR53U6tyD+PQZxAQdqqDMLMvVr1vVlsz2yysoZIxgIgDEqsTvSUvFblQB1J0y/fjZO7BtR9RVHkKqhmrFtaqoA="}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2305232041.0_1684916793874_0.9404143615611866"},"_hasShrinkwrap":false},"1.2305241828.0":{"name":"@bentoproject/date-countdown","version":"1.2305241828.0","description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","author":{"name":"Bento Authors"},"license":"Apache-2.0","main":"./dist/web-component.js","module":"./dist/web-component.module.js","exports":{".":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./web-component":{"import":"./dist/web-component.module.js","require":"./dist/web-component.js"},"./preact":{"import":"./dist/component-preact.module.js","require":"./dist/component-preact.js"},"./react":{"import":"./dist/component-react.module.js","require":"./dist/component-react.js"},"./web-component.css":"./dist/web-component.css"},"repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","peerDependencies":{"preact":"^10.2.1","react":"^17.0.0"},"dependencies":{"@bentoproject/core":"0.2305241828.0"},"readme":"# Bento Date Countdown\n\nDisplays a countdown sequence to a specified date. Refer to the [returned time parameters section](#returned-time-parameters) for information on the available time parameters.\n\n## Web Component\n\nYou must include each Bento component's required CSS library to guarantee proper loading and before adding custom styles. Or use the light-weight pre-upgrade styles available inline. See [Layout and style](#layout-and-style).\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/bento-date-countdown\n```\n\n```javascript\nimport {defineElement as defineBentoDateCountdown} from '@bentoproject/bento-date-countdown';\ndefineBentoDateCountdown();\n```\n\n### Include via `<script>`\n\n```html\n<script type=\"module\" src=\"https://cdn.ampproject.org/bento.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/bento.js\" crossorigin=\"anonymous\"></script>\n<!-- Include bento-mustache.js to use mustache templates with this component -->\n<script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n<script type=\"module\" src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\" crossorigin=\"anonymous\"></script>\n<script nomodule src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\" crossorigin=\"anonymous\"></script>\n<link rel=\"stylesheet\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\" crossorigin=\"anonymous\">\n```\n\n### Example\n\n```html\n<!DOCTYPE html>\n<html>\n  <head>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/bento.mjs\"\n    ></script>\n    <script nomodule src=\"https://cdn.ampproject.org/bento.js\"></script>\n    <script async src=\"https://cdn.ampproject.org/v0/bento-mustache.js\"></script>\n    <script\n      type=\"module\"\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.mjs\"\n    ></script>\n    <script\n      nomodule\n      async\n      src=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.js\"\n    ></script>\n    <link\n      rel=\"stylesheet\"\n      type=\"text/css\"\n      href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\"\n    />\n  </head>\n  <body>\n    <bento-date-countdown timeleft-ms=\"200000000\" biggest-unit=\"HOURS\">\n      <template>\n        <div>\n          <span>{{days}} {{dd}} {{d}}</span>\n          <br>\n          <span>{{hours}} {{hh}} {{h}}</span>\n          <br>\n          <span>{{minutes}} {{mm}} {{m}}</span>\n          <br>\n          <span>{{seconds}} {{ss}} {{s}}</span>\n        </div>\n      </template>\n    </bento-date-countdown>\n  </body>\n</html>\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Web Component will render a mustache-template, provided by the consumer in a `<template>` tag with `type=\"amp-mustache\"`. This template may interpolate date-related parameters. See the [Returned Time Parameters section](#returned-time-parameters) for a full list of all the available parameters.\n\n### Layout and style\n\nEach Bento component has a small CSS library you must include to guarantee proper loading without [content shifts](https://web.dev/cls/). Because of order-based specificity, you must manually ensure that stylesheets are included before any custom styles.\n\n```html\n<link rel=\"stylesheet\" type=\"text/css\" href=\"https://cdn.ampproject.org/v0/bento-date-countdown-1.0.css\">\n```\n\nAlternatively, you may also make the light-weight pre-upgrade styles available inline:\n\n```html\n<style data-bento-boilerplate>\n  bento-date-countdown {\n    display: block;\n    overflow: hidden;\n    position: relative;\n  }\n</style>\n```\n\n### Attributes\n\nTo provide the datetime to countdown to, you must specify at least one of these required attributes: `end-date`,\n`timeleft-ms`, `timestamp-ms`, `timestamp-seconds`.\n\n#### `end-date`\n\nAn ISO formatted date to count down to. For example, `2020-06-01T00:00:00+08:00`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-ms`\n\nA POSIX epoch value in milliseconds; assumed to be UTC timezone. For example, `timestamp-ms=\"1521880470000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timestamp-seconds`\n\nA POSIX epoch value in seconds; assumed to be UTC timezone. For example, `timestamp-seconds=\"1521880470\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `timeleft-ms`\n\nA value in milliseconds left to be counting down. For example, 48 hours left `timeleft-ms=\"172800000\"`.\n\nUsed to determine the datetime to countdown to.\n\n#### `offset-seconds` (optional)\n\nA positive or negative number that represents the number of seconds to add or subtract from the `end-date`. For example, `offset-seconds=\"60\"` adds 60 seconds to the end-date.\n\n#### `when-ended` (optional)\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `locale` (optional)\n\nAn internationalization language string for each timer unit. The default value is `en` (for English).\n\nSupported values:\n\n| Code  | Language            |\n| ----- | ------------------- |\n| de    | German              |\n| en    | English             |\n| es    | Spanish             |\n| fr    | French              |\n| id    | Indonesian          |\n| it    | Italian             |\n| ja    | Japanese            |\n| ko    | Korean              |\n| nl    | Dutch               |\n| pt    | Portuguese          |\n| ru    | Russian             |\n| th    | Thai                |\n| tr    | Turkish             |\n| vi    | Vietnamese          |\n| zh-cn | Chinese Simplified  |\n| zh-tw | Chinese Traditional |\n\n#### `biggest-unit` (optional)\n\nAllows the `bento-date-countdown` component to calculate the time difference based\non the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays\n`1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `count-up` (optional)\n\nInclude this attribute to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` attribute with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n### Styling\n\nYou may use the `bento-date-countdown` element selector to style the Bento Date Countdown component freely.\n\n---\n\n## Preact/React Component\n\n### Import via npm\n\n```sh\nnpm install @bentoproject/date-countdown\n```\n\n```javascript\nimport React from 'react';\nimport {BentoDateCountdown} from '@bentoproject/date-countdown/react';\nimport '@bentoproject/date-countdown/styles.css';\n\nfunction App() {\n  return (\n    <BentoDateCountdown\n      datetime={200000000}\n      biggestUnit={'HOURS'}\n      render={(data) => (\n        <div>\n          <span>{`${data.days} ${data.dd} ${data.d}`}</span>\n          <br>\n          <span>{`${data.hours} ${data.hh} ${data.h}`}</span>\n          <br>\n          <span>{`${data.minutes} ${data.mm} ${data.m}`}</span>\n          <br>\n          <span>{`${data.seconds} ${data.ss} ${data.s}`}</span>\n        </div>\n      )}\n    />\n  );\n}\n```\n\n### Interactivity and API usage\n\nThe Bento Date Countdown component does not have an imperative API. However, the Bento Date Countdown Preact/React component does accept a `render` prop that renders the consumer's template. This `render` prop should be a function which the Bento Date Countdown Preact/React component can use to render its template. The `render` callback will be provided a variety of date-related parameters for consumers to interpolate in the rendered template. See the [`render` prop section](#render) for more information.\n\n### Layout and style\n\nThe Bento Date Countdown Preact/React component allows consumers to render their own templates. These templates may use inline styles, `<style>` tags, Preact/React components that import their own stylesheets.\n\n### Props\n\n#### `datetime`\n\nRequired prop. Denotes the date and time as a Date, String, or Nuumber. If String, must be a standard ISO 8601 date string (e.g. 2017-08-02T15:05:05.000Z) or the string `now`. If set to `now`, it will use the time the page loaded to render its template. If Number, must be a POSIX epoch value in milliseconds.\n\n#### `locale`\n\nAn internationalization language string for each timer unit. The default value is `en` (for English). This prop supports all values that are supported by the user's browser.\n\n#### `whenEnded`\n\nSpecifies whether to stop the timer when it reaches 0 seconds. The value can be set to `stop` (default) to indicate the timer to stop at 0 seconds and will not pass the final date or `continue` to indicate the timer should continue after reaching 0 seconds.\n\n#### `biggestUnit`\n\nAllows the `bento-date-countdown` component to calculate the time difference based on the specified `biggest-unit` value. For example, assume there are `50 days 10 hours` left, if the `biggest-unit` is set to `hours`, the result displays `1210 hours` left.\n\n-   Supported values: `days`, `hours`, `minutes`, `seconds`\n-   Default: `days`\n\n#### `countUp`\n\nInclude this prop to reverse the direction of the countdown to count up instead. This is useful to display the time elapsed since a target date in the past. To continue the countdown when the target date is in the past, be sure to include the `when-ended` prop with the `continue` value. If the target date is in the future, `bento-date-countdown` will display a decrementing (toward 0) negative value.\n\n#### `render`\n\nOptional callback that should render a template. The callback will be provided an object with properties/values related to the date expressed in `datetime`.\n\nBy default, the Bento Date Countdown component will display the [`localeString` form of the Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString) for the given locale and localeOption. See the [Returned Time Parameters section](#returned-time-parameters) for more details on how each property will be displayed.\n\n```typescript\nfunction render(dateParams: DateParams): JSXInternal.Element;\n\ninterface DateParams {\n  day: number;\n  dayName: string;\n  dayNameShort: string;\n  dayPeriod: string;\n  dayTwoDigit: string;\n  hour: number;\n  hour12: number;\n  hour12TwoDigit: string;\n  hourTwoDigit: string;\n  iso: string;\n  localeString: string;\n  minute: number;\n  minuteTwoDigit: string;\n  month: number;\n  monthName: string;\n  monthNameShort: string;\n  monthTwoDigit: string;\n  second: number;\n  secondTwoDigit: string;\n  timeZoneName: string;\n  timeZoneNameShort: string;\n  year: number;\n  yearTwoDi: string;\n}\n```\n\n## Returned Time Parameters\n\nThis table lists the format you can specify in your Mustache template:\n\n| Format  | Meaning                                           |\n| ------- | ------------------------------------------------- |\n| d       | day - 0, 1, 2,...12, 13..Infinity                 |\n| dd      | day - 00, 01, 02, 03..Infinity                    |\n| h       | hour - 0, 1, 2,...12, 13..Infinity                |\n| hh      | hour - 01, 02, 03..Infinity                       |\n| m       | minute - 0, 1, 2,...12, 13..Infinity              |\n| mm      | minute - 01, 01, 02, 03..Infinity                 |\n| s       | second - 0, 1, 2,...12, 13..Infinity              |\n| ss      | second - 00, 01, 02, 03..Infinity                 |\n| days    | internationalization string for day or days       |\n| hours   | internationalization string for hour or hours     |\n| minutes | internationalization string for minute or minutes |\n| seconds | internationalization string for second or seconds |\n\n### Samples of formatted values\n\nThis table provides examples of formatted values specified in a Mustache template, and a sample of what the output:\n\n| Format                                          | Sample Output                        | Remarks                |\n| ----------------------------------------------- | ------------------------------------ | ---------------------- |\n| {hh}:{mm}:{ss}                                  | 04:24:06                             | -                      |\n| {h} {hours} and {m} {minutes} and {s} {seconds} | 4 hours and 1 minutes and 45 seconds | -                      |\n| {d} {days} {h}:{mm}                             | 1 day 5:03                           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 days 5 hours 10 minutes           | -                      |\n| {d} {days} {h} {hours} {m} {minutes}            | 20 days 5 hours 10 minutes           | -                      |\n| {h} {hours} {m} {minutes}                       | 240 hours 10 minutes                 | `biggest-unit='hours'` |\n| {d} {days} {h} {hours} {m} {minutes}            | 50 天 5 小时 10 分钟                 | `locale='zh-cn'`       |\n","readmeFilename":"README.md","gitHead":"fcd19c6354383946b2d66b95efec56661b06e5b6","bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"_id":"@bentoproject/date-countdown@1.2305241828.0","_nodeVersion":"18.16.0","_npmVersion":"9.5.1","dist":{"integrity":"sha512-boLn+hbkY8SRjeUsRv2LTgSU0zz+X15Uo+mzUyUHEt8SHEPcaPe9BL+mELy+xwZ/0H70pinqpJlkSCz96ncbFA==","shasum":"988a1fc9ddf4054269dd60c455d9eeeaa36d7ff4","tarball":"https://registry.npmjs.org/@bentoproject/date-countdown/-/date-countdown-1.2305241828.0.tgz","fileCount":29,"unpackedSize":465872,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD7HHbboumziyrA3s3zoIQ3kfjz9oBsNP7vJJbfe+5NVwIhANjylx/sKIGkSNO3kLJacFTt2zTF7ZyC8kKEo3wov/WM"}]},"_npmUser":{"name":"bentoprojectbot","email":"bentobot@amp.dev"},"directories":{},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/date-countdown_1.2305241828.0_1685003151350_0.6138830447280894"},"_hasShrinkwrap":false}},"time":{"created":"2021-10-28T18:18:59.724Z","1.2110261518.0":"2021-10-28T18:19:00.035Z","modified":"2023-05-25T08:25:51.640Z","1.2110252343.0":"2021-10-28T21:47:48.349Z","1.2110281959.0":"2021-10-29T11:51:51.611Z","1.2110290545.0":"2021-10-30T11:21:02.291Z","1.2111011823.0":"2021-11-02T11:25:15.176Z","1.2110152252.3":"2021-11-02T22:03:51.610Z","1.2110212130.2":"2021-11-02T22:14:14.801Z","1.2111022043.0":"2021-11-03T11:21:46.489Z","1.2111180040.0":"2021-11-18T21:26:32.397Z","1.2111060251.3":"2021-11-18T21:41:37.418Z","1.2111182332.0":"2021-11-19T12:24:50.175Z","1.2111060251.9":"2021-11-19T16:30:46.797Z","1.2111191951.0":"2021-11-20T12:23:03.620Z","1.2111230244.0":"2021-11-23T12:24:20.043Z","1.2111230636.0":"2021-11-24T12:23:13.504Z","1.2111242025.0":"2021-11-25T12:41:45.084Z","1.2111292120.0":"2021-11-30T12:40:24.889Z","1.2111152338.2":"2021-11-30T17:54:11.515Z","1.2112010058.0":"2021-12-01T12:18:55.561Z","1.2112012300.0":"2021-12-02T12:30:04.027Z","1.2112021656.0":"2021-12-03T12:21:52.152Z","1.2112032204.0":"2021-12-04T12:20:27.576Z","1.2112062322.0":"2021-12-07T12:27:15.676Z","1.2112062322.2":"2021-12-07T22:28:40.276Z","1.2112080230.0":"2021-12-08T13:21:33.608Z","1.2112080230.1":"2021-12-08T15:57:46.716Z","1.2112082232.0":"2021-12-09T12:45:16.807Z","1.2111242025.1":"2021-12-10T00:11:08.281Z","1.2112091956.0":"2021-12-10T12:45:56.366Z","1.2112102136.0":"2021-12-11T12:31:00.100Z","1.2112132331.0":"2021-12-14T12:59:02.507Z","1.2112160003.0":"2021-12-16T12:19:12.940Z","1.2112162055.0":"2021-12-17T12:17:34.451Z","1.2112170012.0":"2021-12-18T12:17:56.052Z","1.2112201724.0":"2021-12-21T12:21:03.720Z","1.2112212349.0":"2021-12-22T12:23:18.373Z","1.2112221739.0":"2021-12-23T12:18:50.823Z","1.2112231523.0":"2021-12-24T12:19:56.248Z","1.2201042109.0":"2022-01-05T12:30:48.106Z","1.2201052144.0":"2022-01-06T12:41:00.999Z","1.2201061922.0":"2022-01-07T12:32:00.809Z","1.2201071715.0":"2022-01-08T12:21:52.267Z","1.2201101902.0":"2022-01-11T12:29:36.353Z","1.2112231523.1":"2022-01-11T19:25:21.470Z","1.2201120015.0":"2022-01-12T12:30:36.234Z","1.2112231523.2":"2022-01-12T22:39:20.809Z","1.2201122239.0":"2022-01-13T13:00:09.225Z","1.2201131702.0":"2022-01-14T13:03:49.651Z","1.2201141909.0":"2022-01-15T12:21:22.970Z","1.2201141909.1":"2022-01-25T19:49:39.150Z","1.2201141909.3":"2022-01-26T20:58:39.701Z","1.2201141909.4":"2022-02-01T21:37:36.211Z","1.2201212122.3":"2022-02-02T17:58:26.352Z","1.2202012258.0":"2022-02-02T19:12:43.670Z","1.2202022130.0":"2022-02-03T16:55:36.463Z","1.2202031816.0":"2022-02-04T15:46:51.370Z","1.2202042210.0":"2022-02-05T09:18:21.644Z","1.2202072236.0":"2022-02-08T09:20:01.132Z","1.2201262038.1":"2022-02-08T21:12:41.298Z","1.2202082004.0":"2022-02-09T22:17:01.729Z","1.2202092050.0":"2022-02-10T17:56:58.190Z","1.2202112230.0":"2022-02-14T21:05:55.752Z","1.2202142035.0":"2022-02-15T09:25:12.670Z","1.2202042210.1":"2022-02-15T18:23:07.778Z","1.2202152253.0":"2022-02-16T09:08:20.898Z","1.2202162256.0":"2022-02-17T09:29:22.240Z","1.2202180255.0":"2022-02-18T09:45:00.630Z","1.2202230359.0":"2022-02-23T09:29:43.558Z","1.2202232232.0":"2022-02-24T15:23:03.405Z","1.2202241911.0":"2022-02-25T15:18:03.403Z","1.2202252101.0":"2022-02-28T16:46:03.300Z","1.2202230359.1":"2022-03-01T22:05:16.452Z","1.2203041950.0":"2022-03-15T18:36:00.415Z","1.2203151539.0":"2022-03-16T08:21:34.243Z","1.2203172113.0":"2022-03-18T08:22:59.368Z","1.2203221937.0":"2022-03-23T08:25:06.590Z","1.2203231914.0":"2022-03-24T08:22:59.505Z","1.2203101844.0":"2022-03-24T20:09:11.309Z","1.2203281422.0":"2022-03-29T08:27:51.956Z","1.2204121632.0":"2022-04-12T18:15:10.161Z","1.2204122000.0":"2022-04-13T08:30:30.420Z","1.2204132005.0":"2022-04-14T08:32:05.840Z","1.2204142048.0":"2022-04-15T08:26:15.424Z","1.2204160405.0":"2022-04-16T08:23:51.548Z","1.2204182206.0":"2022-04-19T08:29:24.159Z","1.2204191429.0":"2022-04-20T08:30:46.642Z","1.2204211736.0":"2022-04-22T08:25:53.327Z","1.2204221712.0":"2022-04-23T08:24:06.472Z","1.2204252045.0":"2022-04-26T08:30:44.288Z","1.2204272205.0":"2022-04-28T08:30:35.516Z","1.2204281949.0":"2022-04-29T08:26:42.813Z","1.2204292129.0":"2022-04-30T08:24:40.134Z","1.2205031420.0":"2022-05-04T08:25:31.287Z","1.2205041533.0":"2022-05-05T08:25:29.185Z","1.2205051832.0":"2022-05-06T08:25:58.319Z","1.2205090810.0":"2022-05-10T08:31:10.916Z","1.2205101904.0":"2022-05-11T08:30:45.804Z","1.2205120110.0":"2022-05-12T08:30:03.755Z","1.2205161914.0":"2022-05-17T08:25:36.788Z","1.2205181800.0":"2022-05-19T08:25:42.274Z","1.2205191749.0":"2022-05-20T08:27:00.860Z","1.2205232225.0":"2022-05-24T08:25:24.238Z","1.2205120110.1":"2022-05-24T19:11:37.151Z","1.2205251942.0":"2022-05-26T08:26:16.113Z","1.2205270638.0":"2022-05-27T08:25:48.942Z","1.2206071918.0":"2022-06-07T22:26:54.566Z","1.2206072228.0":"2022-06-08T08:26:20.341Z","1.2206082301.0":"2022-06-09T08:29:11.583Z","1.2205270638.4":"2022-06-10T21:34:12.290Z","1.2206101637.0":"2022-06-11T08:25:27.547Z","1.2206131450.0":"2022-06-14T08:26:50.391Z","1.2206071918.1":"2022-06-14T21:26:20.233Z","1.2206162023.0":"2022-06-17T08:26:02.903Z","1.2206221455.0":"2022-06-23T08:27:05.720Z","1.2206291614.0":"2022-06-30T16:06:44.083Z","1.2207071723.0":"2022-07-08T08:32:35.902Z","1.2207181727.0":"2022-07-19T08:25:54.016Z","1.2207201724.0":"2022-07-21T08:26:26.124Z","1.2207221643.0":"2022-07-23T08:25:34.542Z","1.2207261725.0":"2022-07-27T08:25:07.086Z","1.2207281718.0":"2022-07-29T08:28:38.608Z","1.2208021808.0":"2022-08-03T08:26:25.975Z","1.2208042017.0":"2022-08-05T08:27:56.698Z","1.2208051912.0":"2022-08-06T08:27:09.555Z","1.2208081650.0":"2022-08-09T08:27:21.416Z","1.2208092047.0":"2022-08-10T08:26:50.974Z","1.2207281718.1":"2022-08-10T16:56:59.204Z","1.2207281718.2":"2022-08-10T18:14:58.670Z","1.2208112015.0":"2022-08-12T08:26:50.034Z","1.2208121708.0":"2022-08-13T08:25:46.426Z","1.2208051912.1":"2022-08-16T23:04:30.740Z","1.2208172101.0":"2022-08-24T20:55:23.923Z","1.2208242209.0":"2022-08-25T08:26:17.924Z","1.2209072154.0":"2022-09-08T08:24:56.757Z","1.2209131909.0":"2022-09-14T08:43:31.686Z","1.2208242209.1":"2022-09-15T16:42:17.322Z","1.2209142312.0":"2022-09-20T22:06:51.484Z","1.2210010655.0":"2022-10-04T16:48:40.118Z","1.2210041838.0":"2022-10-05T08:29:27.934Z","1.2210052034.0":"2022-10-06T08:25:14.499Z","1.2210071758.0":"2022-10-08T08:24:57.274Z","1.2210112333.0":"2022-10-12T08:24:19.938Z","1.2210142102.0":"2022-10-15T08:24:02.102Z","1.2210172057.0":"2022-10-18T08:26:44.591Z","1.2210191347.0":"2022-10-20T08:25:09.818Z","1.2210211855.0":"2022-10-22T08:23:31.259Z","1.2210251605.0":"2022-10-26T08:27:01.689Z","1.2210272257.0":"2022-10-28T08:25:48.694Z","1.2211042305.0":"2022-11-05T08:24:27.828Z","1.2211060024.0":"2022-11-08T08:24:53.254Z","1.2211111611.0":"2022-11-12T08:23:42.727Z","1.2211151402.0":"2022-11-16T18:34:20.023Z","1.2211182146.0":"2022-11-19T08:25:06.972Z","1.2211250451.0":"2022-11-25T08:24:10.099Z","1.2211302304.0":"2022-12-01T08:23:46.921Z","1.2212071834.0":"2022-12-07T19:37:12.994Z","1.2212092023.0":"2022-12-10T08:24:41.122Z","1.2211302304.1":"2022-12-13T21:52:22.104Z","1.2212151632.0":"2022-12-20T15:52:13.789Z","1.2212151632.1":"2022-12-20T20:09:25.383Z","1.2211302304.2":"2022-12-20T22:32:16.949Z","1.2212151632.2":"2023-01-03T18:11:46.545Z","1.2301031703.0":"2023-01-03T20:29:58.214Z","1.2301032153.0":"2023-01-04T08:25:07.091Z","1.2301041800.0":"2023-01-05T08:25:44.619Z","1.2301100345.0":"2023-01-10T08:25:14.966Z","1.2301112346.0":"2023-01-12T08:26:31.924Z","1.2301181928.0":"2023-01-19T08:25:55.296Z","1.2301261900.0":"2023-01-27T08:26:30.350Z","1.2301301810.0":"2023-01-31T08:25:48.888Z","1.2302012254.0":"2023-02-02T08:24:17.652Z","1.2302021743.0":"2023-02-03T08:25:49.887Z","1.2302031721.0":"2023-02-04T08:24:21.495Z","1.2302171719.0":"2023-02-18T08:22:56.661Z","1.2302271541.0":"2023-02-28T17:24:11.516Z","1.2303151529.0":"2023-03-15T16:26:17.970Z","1.2303151621.0":"2023-03-22T08:24:31.575Z","1.2303231800.0":"2023-03-29T09:54:56.909Z","1.2304040531.0":"2023-04-04T08:24:53.951Z","1.2304062309.0":"2023-04-07T08:24:04.509Z","1.2304122229.0":"2023-04-13T08:24:49.307Z","1.2304132133.0":"2023-04-14T08:25:16.547Z","1.2304212144.0":"2023-04-22T08:27:00.578Z","1.2304241924.0":"2023-04-25T08:26:22.074Z","1.2304262219.0":"2023-04-27T08:27:10.339Z","1.2305022024.0":"2023-05-03T08:26:54.243Z","1.2305051745.0":"2023-05-06T08:24:37.864Z","1.2305152039.0":"2023-05-16T08:26:25.044Z","1.2305182038.0":"2023-05-19T08:27:24.574Z","1.2305221508.0":"2023-05-23T08:25:24.477Z","1.2305051745.1":"2023-05-23T23:03:12.251Z","1.2305232041.0":"2023-05-24T08:26:34.087Z","1.2305241828.0":"2023-05-25T08:25:51.505Z"},"maintainers":[{"name":"bentoprojectbot","email":"bentobot@amp.dev"},{"name":"kristoferbaxter","email":"kbax@me.com"},{"name":"esth","email":"esther@amp.dev"}],"description":"Displays a countdown sequence to a specified date. Refer to the returned time parameters section for information on the available time parameters.","homepage":"https://github.com/ampproject/amphtml/tree/main/extensions/amp-date-countdown/1.0","repository":{"type":"git","url":"git+https://github.com/ampproject/amphtml.git","directory":"extensions/amp-date-countdown/1.0"},"author":{"name":"Bento Authors"},"bugs":{"url":"https://github.com/ampproject/amphtml/issues"},"license":"Apache-2.0","readme":"","readmeFilename":""}