npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@florianogomez/hrnet-datepicker

v1.0.6

Published

A modern, accessible, and customizable React DatePicker component for HRnet and any React project.

Downloads

11

Readme

📅 HrnetDatePicker

A modern, accessible, and customizable React DatePicker component for HRnet and any React project.

✨ Features

  • 🎯 Accessible: Full keyboard navigation, screen reader support, and ARIA labels
  • 🌍 Internationalized: French and English locale support
  • 🎨 Customizable: Light/dark themes, modular CSS
  • Performant: Optimized with React hooks and memoization
  • 📱 Responsive: Works on mobile and desktop
  • 🔧 TypeScript: Full type definitions included

📦 Installation

npm install hrnet-datepicker
# or
yarn add hrnet-datepicker

⚙️ Technical Requirements

  • React: version 18.0.0 or higher (React 19+ fully supported)
  • ReactDOM: version 18.0.0 or higher
  • Node.js: version 16 or higher recommended
  • Bundler: Vite, Webpack, or compatible (ESM and UMD builds provided)

Make sure react and react-dom are installed as dependencies in your project.

🚀 Basic Usage

import { HrnetDatePicker } from 'hrnet-datepicker';
import { useState } from 'react';

function App() {
  const [date, setDate] = useState<Date | null>(null);

  return (
    <HrnetDatePicker
      value={date}
      onChange={setDate}
      label="Birth date"
      placeholder="MM/DD/YYYY"
    />
  );
}

} ```

📋 Props API

| Prop | Type | Default | Description | |--------------------|--------------------------------------|-----------------|--------------------------------------------------------------------| | value | Date \| null | — | The currently selected date. | | onChange | (date: Date \| null) => void | — | Callback fired when a date is selected or cleared. | | label | string | — | Label displayed above the input field. | | placeholder | string | Locale default | Placeholder text for the input field. | | locale | 'fr' \| 'en' | 'fr' | Locale for date display and calendar UI. | | variant | 'light' \| 'dark' | 'light' | Visual theme of the component. | | disabled | boolean | false | Disables the date picker input and calendar. | | error | string | — | Error message displayed below the input. | | minDate | Date | — | Minimum selectable date (inclusive). | | maxDate | Date | — | Maximum selectable date (inclusive). | | dateFormat | string | Locale default | Custom date display format (overrides locale default). | | className | string | — | Custom CSS class for the input element. | | wrapperClassName | string | — | Custom CSS class for the main wrapper element. | | id | string | Auto-generated | HTML id for the input (overrides auto-generated id). | | name | string | — | HTML name for the input. |

♿ Accessibility

This component follows WCAG 2.1 accessibility standards:

  • Keyboard navigation: Tab, Enter, Space, Escape, Arrow keys
  • Screen readers: Complete ARIA labels and roles
  • Contrast: Colors meet accessibility contrast requirements
  • Focus: Clear visual focus indicators

🌍 Localization

Supported Locales

  • French (fr): Date format DD/MM/YYYY, week starts on Monday
  • English (en): Date format MM/DD/YYYY, week starts on Sunday

Fast Navigation

  • Month selector: Dropdown with localized month names
  • Year selector: Navigate ±10 years from current
  • Arrow buttons: Previous/next month

Adaptive Formats

Date formats, placeholders, and UI texts automatically adapt to the selected locale.


🛠️ Advanced Usage

  • Pass any standard <input> props (except type, value, onChange which are managed by the component)
  • Use className and wrapperClassName for custom styling
  • Use minDate and maxDate to restrict selectable dates
  • Use dateFormat to override the default display format

📄 License

MIT © Floriano Gomez