@pagamio/frontend-commons-lib 0.8.243 → 0.8.245

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.
@@ -1,5 +1,13 @@
1
1
  import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { TimeInput as MantineTimeInput } from '@mantine/dates';
3
+ import { IconClock } from '@tabler/icons-react';
2
4
  import React from 'react';
3
- import { Input } from '../../../../components';
4
- const TimeInput = React.forwardRef(({ field, error, ...props }, ref) => (_jsxs(_Fragment, { children: [_jsx("label", { htmlFor: field.name, className: "block text-sm font-medium text-gray-700", children: field.label }), _jsx(Input, { type: "time", ...props, ref: ref, id: field.name, disabled: field.disabled, className: `mt-1 block w-full p-2 border ${error ? 'border-red-500' : 'border-gray-300'} rounded-md shadow-sm disabled:text-gray-400 disabled:bg-gray-50` }), error && _jsx("p", { className: "mt-2 text-sm text-red-500", children: error.message })] })));
5
+ const TimeInput = React.forwardRef(({ field, error, ...props }, ref) => {
6
+ const { value, onChange, onBlur, name } = props;
7
+ return (_jsxs(_Fragment, { children: [_jsx("label", { htmlFor: field.name, className: "mb-1 block text-sm font-medium text-gray-700", children: field.label }), _jsx(MantineTimeInput, { ref: ref, id: field.name, name: name || field.name, value: value ?? '', onChange: onChange, onBlur: onBlur, disabled: field.disabled, leftSection: _jsx(IconClock, { size: 16 }), error: error?.message, styles: {
8
+ input: {
9
+ height: '42px',
10
+ },
11
+ } })] }));
12
+ });
5
13
  export default TimeInput;
package/lib/index.d.ts CHANGED
@@ -20,4 +20,5 @@ export * from './translations';
20
20
  export * from './rbac';
21
21
  export { useImageUpload } from './shared/hooks/useImageUpload';
22
22
  export type { UseImageUploadProps, UploadResponse } from './shared/hooks/useImageUpload';
23
+ export { useAnyDrawerOpen } from './shared/hooks/useAnyDrawerOpen';
23
24
  export * from './feedback';
package/lib/index.js CHANGED
@@ -30,5 +30,6 @@ export * from './translations';
30
30
  export * from './rbac';
31
31
  // Hooks
32
32
  export { useImageUpload } from './shared/hooks/useImageUpload';
33
+ export { useAnyDrawerOpen } from './shared/hooks/useAnyDrawerOpen';
33
34
  // Feedback System
34
35
  export * from './feedback';
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@pagamio/frontend-commons-lib",
3
3
  "description": "Pagamio library for Frontend reusable components like the form engine and table container",
4
- "version": "0.8.243",
4
+ "version": "0.8.245",
5
5
  "publishConfig": {
6
6
  "access": "public",
7
7
  "provenance": false