@ark-ui/solid 3.12.0 → 3.12.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cjs/index.js CHANGED
@@ -2288,30 +2288,20 @@ const DatePickerYearSelect = props => {
2288
2288
  const mergedProps = solid.mergeProps(() => api().getYearSelectProps(), props);
2289
2289
  return web.createComponent(ark.select, web.mergeProps(mergedProps, {
2290
2290
  get children() {
2291
- return web.createComponent(solidJs.For, {
2291
+ return web.createComponent(solidJs.Index, {
2292
2292
  get each() {
2293
- return getYearsRange({
2294
- from: 1_000,
2295
- to: 4_000
2296
- });
2293
+ return api().getYears();
2297
2294
  },
2298
2295
  children: year => (() => {
2299
2296
  var _el$ = _tmpl$$5();
2300
- _el$.value = year;
2301
- web.insert(_el$, year);
2297
+ web.insert(_el$, () => year().label);
2298
+ web.effect(() => _el$.value = year().value);
2302
2299
  return _el$;
2303
2300
  })()
2304
2301
  });
2305
2302
  }
2306
2303
  }));
2307
2304
  };
2308
- function getYearsRange(range) {
2309
- const years = [];
2310
- for (let year = range.from; year <= range.to; year += 1) {
2311
- years.push(year);
2312
- }
2313
- return years;
2314
- }
2315
2305
 
2316
2306
  var datePicker = /*#__PURE__*/Object.freeze({
2317
2307
  __proto__: null,