@devtron-labs/devtron-fe-common-lib 0.0.38 → 0.0.39-beta-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.
Files changed (61) hide show
  1. package/dist/Common/Hooks/UseClickOutside/UseClickOutside.d.ts +1 -0
  2. package/dist/Common/Hooks/index.d.ts +1 -0
  3. package/dist/Common/RJSF/Form.d.ts +4 -0
  4. package/dist/Common/RJSF/common/FieldRow.d.ts +3 -0
  5. package/dist/Common/RJSF/common/types.d.ts +8 -0
  6. package/dist/Common/RJSF/config.d.ts +4 -0
  7. package/dist/Common/RJSF/constants.d.ts +5 -0
  8. package/dist/Common/RJSF/index.d.ts +2 -0
  9. package/dist/Common/RJSF/templates/ArrayFieldItemTemplate.d.ts +3 -0
  10. package/dist/Common/RJSF/templates/ArrayFieldTemplate.d.ts +3 -0
  11. package/dist/Common/RJSF/templates/BaseInput.d.ts +3 -0
  12. package/dist/Common/RJSF/templates/ButtonTemplates/AddButton.d.ts +3 -0
  13. package/dist/Common/RJSF/templates/ButtonTemplates/RemoveButton.d.ts +3 -0
  14. package/dist/Common/RJSF/templates/ButtonTemplates/SubmitButton.d.ts +3 -0
  15. package/dist/Common/RJSF/templates/ButtonTemplates/index.d.ts +3 -0
  16. package/dist/Common/RJSF/templates/Description.d.ts +3 -0
  17. package/dist/Common/RJSF/templates/Field.d.ts +3 -0
  18. package/dist/Common/RJSF/templates/FieldErrorTemplate.d.ts +3 -0
  19. package/dist/Common/RJSF/templates/ObjectFieldTemplate.d.ts +3 -0
  20. package/dist/Common/RJSF/templates/TitleField.d.ts +3 -0
  21. package/dist/Common/RJSF/templates/WrapIfAdditionalTemplate.d.ts +3 -0
  22. package/dist/Common/RJSF/templates/index.d.ts +10 -0
  23. package/dist/Common/RJSF/types.d.ts +3 -0
  24. package/dist/Common/RJSF/utils.d.ts +14 -0
  25. package/dist/Common/RJSF/widgets/Checkbox.d.ts +3 -0
  26. package/dist/Common/RJSF/widgets/Select.d.ts +3 -0
  27. package/dist/Common/RJSF/widgets/index.d.ts +2 -0
  28. package/dist/Common/index.d.ts +1 -0
  29. package/dist/index.js +381 -146
  30. package/package.json +4 -1
  31. package/src/Assets/Icon/ic-chevron-down.svg +5 -0
  32. package/src/Common/Hooks/UseClickOutside/UseClickOutside.tsx +15 -0
  33. package/src/Common/Hooks/index.ts +1 -0
  34. package/src/Common/RJSF/Form.tsx +28 -0
  35. package/src/Common/RJSF/common/FieldRow.tsx +31 -0
  36. package/src/Common/RJSF/common/types.ts +9 -0
  37. package/src/Common/RJSF/config.ts +37 -0
  38. package/src/Common/RJSF/constants.ts +5 -0
  39. package/src/Common/RJSF/index.ts +2 -0
  40. package/src/Common/RJSF/rjsfForm.scss +17 -0
  41. package/src/Common/RJSF/templates/ArrayFieldItemTemplate.tsx +33 -0
  42. package/src/Common/RJSF/templates/ArrayFieldTemplate.tsx +77 -0
  43. package/src/Common/RJSF/templates/BaseInput.tsx +16 -0
  44. package/src/Common/RJSF/templates/ButtonTemplates/AddButton.tsx +18 -0
  45. package/src/Common/RJSF/templates/ButtonTemplates/RemoveButton.tsx +10 -0
  46. package/src/Common/RJSF/templates/ButtonTemplates/SubmitButton.tsx +18 -0
  47. package/src/Common/RJSF/templates/ButtonTemplates/index.ts +3 -0
  48. package/src/Common/RJSF/templates/Description.tsx +12 -0
  49. package/src/Common/RJSF/templates/Field.tsx +30 -0
  50. package/src/Common/RJSF/templates/FieldErrorTemplate.tsx +25 -0
  51. package/src/Common/RJSF/templates/ObjectFieldTemplate.tsx +96 -0
  52. package/src/Common/RJSF/templates/TitleField.tsx +9 -0
  53. package/src/Common/RJSF/templates/WrapIfAdditionalTemplate.tsx +51 -0
  54. package/src/Common/RJSF/templates/index.ts +10 -0
  55. package/src/Common/RJSF/types.ts +4 -0
  56. package/src/Common/RJSF/utils.ts +59 -0
  57. package/src/Common/RJSF/widgets/Checkbox.tsx +44 -0
  58. package/src/Common/RJSF/widgets/Select.tsx +72 -0
  59. package/src/Common/RJSF/widgets/index.ts +2 -0
  60. package/src/Common/Security/scanVulnerabilities.css +2 -0
  61. package/src/Common/index.ts +1 -0
@@ -0,0 +1 @@
1
+ export declare const useClickOutside: (ref: any, callback: () => void) => void;
@@ -1 +1,2 @@
1
1
  export { useSuperAdmin } from './UseSuperAdmin/UseSuperAdmin';
2
+ export { useClickOutside } from './UseClickOutside/UseClickOutside';
@@ -0,0 +1,4 @@
1
+ /// <reference types="react" />
2
+ import { FormProps } from './types';
3
+ import './rjsfForm.scss';
4
+ export declare const RJSFForm: (props: FormProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { FieldRowProps } from './types';
3
+ export declare const FieldRowWithLabel: ({ showLabel, label, required, children, id, shouldAlignCenter, }: FieldRowProps) => JSX.Element;
@@ -0,0 +1,8 @@
1
+ import { FieldTemplateProps } from '@rjsf/utils';
2
+ export interface FieldRowProps extends Pick<FieldTemplateProps, 'children' | 'label' | 'required' | 'id'> {
3
+ showLabel?: boolean;
4
+ /**
5
+ * @default true
6
+ */
7
+ shouldAlignCenter?: boolean;
8
+ }
@@ -0,0 +1,4 @@
1
+ import { RegistryWidgetsType } from '@rjsf/utils';
2
+ import { FormProps } from './types';
3
+ export declare const widgets: RegistryWidgetsType;
4
+ export declare const templates: FormProps['templates'];
@@ -0,0 +1,5 @@
1
+ export declare const PLACEHOLDERS: {
2
+ SELECT: string;
3
+ INPUT: string;
4
+ OBJECT_KEY: string;
5
+ };
@@ -0,0 +1,2 @@
1
+ export { RJSFForm } from './Form';
2
+ export * from './types';
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { ArrayFieldTemplateItemType } from '@rjsf/utils';
3
+ export declare const ArrayFieldItemTemplate: ({ children, className, disabled, hasToolbar, hasRemove, index, onDropIndexClick, readonly, registry, uiSchema, }: ArrayFieldTemplateItemType) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { ArrayFieldTemplateProps } from '@rjsf/utils';
3
+ export declare const ArrayFieldTemplate: ({ canAdd, className, disabled, idSchema, uiSchema, items, onAddClick, readonly, registry, required, title, }: ArrayFieldTemplateProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { BaseInputTemplateProps } from '@rjsf/utils';
3
+ export declare const BaseInput: ({ placeholder, ...props }: BaseInputTemplateProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { IconButtonProps } from '@rjsf/utils';
3
+ export declare const AddButton: ({ icon, iconType, registry, uiSchema, ...props }: IconButtonProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { IconButtonProps } from '@rjsf/utils';
3
+ export declare const RemoveButton: ({ icon, iconType, registry, uiSchema, ...props }: IconButtonProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { SubmitButtonProps } from '@rjsf/utils';
3
+ export declare const SubmitButton: ({ uiSchema }: SubmitButtonProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ export { AddButton } from './AddButton';
2
+ export { RemoveButton } from './RemoveButton';
3
+ export { SubmitButton } from './SubmitButton';
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { DescriptionFieldProps } from '@rjsf/utils';
3
+ export declare const Description: ({ id, description }: DescriptionFieldProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { FieldTemplateProps } from '@rjsf/utils';
3
+ export declare const Field: (props: FieldTemplateProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { FieldErrorProps } from '@rjsf/utils';
3
+ export declare const FieldErrorTemplate: ({ errors, idSchema }: FieldErrorProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { ObjectFieldTemplateProps } from '@rjsf/utils';
3
+ export declare const ObjectFieldTemplate: (props: ObjectFieldTemplateProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { TitleFieldProps } from '@rjsf/utils';
3
+ export declare const TitleField: ({ id, title, required }: TitleFieldProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { WrapIfAdditionalTemplateProps } from '@rjsf/utils';
3
+ export declare const WrapIfAdditionalTemplate: ({ id, disabled, label, onKeyChange, onDropPropertyClick, readonly, schema, children, uiSchema, registry, }: WrapIfAdditionalTemplateProps) => JSX.Element;
@@ -0,0 +1,10 @@
1
+ export { ArrayFieldTemplate } from './ArrayFieldTemplate';
2
+ export { ArrayFieldItemTemplate } from './ArrayFieldItemTemplate';
3
+ export { BaseInput as BaseInputTemplate } from './BaseInput';
4
+ export * from './ButtonTemplates';
5
+ export { Description as DescriptionFieldTemplate } from './Description';
6
+ export { Field as FieldTemplate } from './Field';
7
+ export { FieldErrorTemplate } from './FieldErrorTemplate';
8
+ export { ObjectFieldTemplate } from './ObjectFieldTemplate';
9
+ export { TitleField as TitleFieldTemplate } from './TitleField';
10
+ export { WrapIfAdditionalTemplate } from './WrapIfAdditionalTemplate';
@@ -0,0 +1,3 @@
1
+ import { ComponentProps } from 'react';
2
+ import RJSFForm from '@rjsf/core';
3
+ export type FormProps = Omit<ComponentProps<typeof RJSFForm>, 'validator'>;
@@ -0,0 +1,14 @@
1
+ import { TranslatableString } from '@rjsf/utils';
2
+ /**
3
+ * Override for the TranslatableString from RJSF
4
+ */
5
+ export declare const translateString: (stringToTranslate: TranslatableString, params?: string[]) => string;
6
+ export declare const getCommonSelectStyle: (styleOverrides?: {}) => {
7
+ menuList: (base: any) => any;
8
+ control: (base: any, state: any) => any;
9
+ option: (base: any, state: any) => any;
10
+ dropdownIndicator: (base: any, state: any) => any;
11
+ valueContainer: (base: any) => any;
12
+ loadingMessage: (base: any) => any;
13
+ noOptionsMessage: (base: any) => any;
14
+ };
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { WidgetProps } from '@rjsf/utils';
3
+ export declare const Checkbox: ({ id, onChange, value, required, disabled, readonly, autofocus, onBlur, onFocus, }: WidgetProps) => JSX.Element;
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ import { WidgetProps } from '@rjsf/utils';
3
+ export declare const Select: (props: WidgetProps) => JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { Checkbox as CheckboxWidget } from './Checkbox';
2
+ export { Select as SelectWidget } from './Select';
@@ -40,3 +40,4 @@ export { default as Grid } from './Grid/Grid';
40
40
  export { default as ClipboardButton } from './ClipboardButton/ClipboardButton';
41
41
  export * from './Hooks';
42
42
  export { AppStatus } from './AppStatus';
43
+ export * from './RJSF';