@hexclave/dashboard-ui-components 1.0.93 → 1.0.95

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.
@@ -3,8 +3,8 @@ import { VariantProps } from "class-variance-authority";
3
3
 
4
4
  //#region src/components/button.d.ts
5
5
  declare const designButtonVariants: (props?: ({
6
- variant?: "link" | "plain" | "default" | "destructive" | "outline" | "secondary" | "ghost" | null | undefined;
7
- size?: "sm" | "lg" | "default" | "icon" | null | undefined;
6
+ variant?: "default" | "destructive" | "outline" | "secondary" | "ghost" | "link" | "plain" | null | undefined;
7
+ size?: "default" | "sm" | "lg" | "icon" | null | undefined;
8
8
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
9
9
  type DesignOriginalButtonProps = {
10
10
  asChild?: boolean;
@@ -35,8 +35,8 @@ declare const DesignButton: React.FC<{
35
35
  } & {
36
36
  asChild?: boolean;
37
37
  } & React.ButtonHTMLAttributes<HTMLButtonElement> & VariantProps<(props?: ({
38
- variant?: "link" | "plain" | "default" | "destructive" | "outline" | "secondary" | "ghost" | null | undefined;
39
- size?: "sm" | "lg" | "default" | "icon" | null | undefined;
38
+ variant?: "default" | "destructive" | "outline" | "secondary" | "ghost" | "link" | "plain" | null | undefined;
39
+ size?: "default" | "sm" | "lg" | "icon" | null | undefined;
40
40
  } & import("class-variance-authority/types").ClassProp) | undefined) => string> & {
41
41
  ref?: React.Ref<HTMLButtonElement> | undefined;
42
42
  }>;
@@ -2,7 +2,7 @@ import * as React$1 from "react";
2
2
  import * as RechartsPrimitive from "recharts";
3
3
 
4
4
  //#region src/components/chart-legend.d.ts
5
- declare const DesignChartLegendContent: React$1.ForwardRefExoticComponent<Omit<React$1.ClassAttributes<HTMLDivElement> & React$1.HTMLAttributes<HTMLDivElement> & Pick<RechartsPrimitive.LegendProps, "payload" | "verticalAlign"> & {
5
+ declare const DesignChartLegendContent: React$1.ForwardRefExoticComponent<Omit<React$1.ClassAttributes<HTMLDivElement> & React$1.HTMLAttributes<HTMLDivElement> & Pick<RechartsPrimitive.LegendProps, "verticalAlign" | "payload"> & {
6
6
  hideIcon?: boolean;
7
7
  nameKey?: string;
8
8
  }, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
@@ -7886,6 +7886,29 @@ attempted value: ${formattedValue}
7886
7886
 
7887
7887
  // ../shared/dist/esm/schema-fields.js
7888
7888
  var MAX_IMAGE_SIZE_BASE64_BYTES = 1e6;
7889
+ var PROTOTYPE_KEY = "__proto__";
7890
+ function hasOwnPrototypeKey(value) {
7891
+ return typeof value === "object" && value !== null && Object.prototype.hasOwnProperty.call(value, PROTOTYPE_KEY);
7892
+ }
7893
+ var originalObjectSchemaCast = ObjectSchema.prototype._cast;
7894
+ ObjectSchema.prototype._cast = function(value, options = {}) {
7895
+ if (!hasOwnPrototypeKey(value)) return originalObjectSchemaCast.call(this, value, options);
7896
+ const prototypeEntry = Object.getOwnPropertyDescriptor(value, PROTOTYPE_KEY).value;
7897
+ const withoutPrototypeKey = {};
7898
+ for (const key of Object.keys(value)) {
7899
+ if (key === PROTOTYPE_KEY) continue;
7900
+ withoutPrototypeKey[key] = value[key];
7901
+ }
7902
+ const cast = originalObjectSchemaCast.call(this, withoutPrototypeKey, options);
7903
+ if ((options.stripUnknown ?? this.spec?.noUnknown) || typeof cast !== "object" || cast === null) return cast;
7904
+ Object.defineProperty(cast, PROTOTYPE_KEY, {
7905
+ value: prototypeEntry,
7906
+ writable: true,
7907
+ enumerable: true,
7908
+ configurable: true
7909
+ });
7910
+ return cast;
7911
+ };
7889
7912
  addMethod(create$6, "nonEmpty", function(message2) {
7890
7913
  return this.test("non-empty", message2 ?? (({ path }) => `${path} must not be empty`), (value) => {
7891
7914
  return value !== "";
@@ -8047,12 +8070,24 @@ attempted value: ${formattedValue}
8047
8070
  for (const key of Object.keys(value)) {
8048
8071
  await yupValidate(keySchema, key, context.options);
8049
8072
  try {
8050
- await yupValidate(valueSchema, value[key], {
8051
- ...context.options,
8073
+ const childOptions = {
8074
+ abortEarly: context.options.abortEarly,
8075
+ disableStackTrace: context.options.disableStackTrace,
8076
+ recursive: context.options.recursive,
8077
+ path: context.options.path,
8078
+ strict: false,
8079
+ stripUnknown: context.options.stripUnknown,
8052
8080
  context: {
8053
8081
  ...context.options.context,
8054
8082
  path: path ? `${path}.${key}` : key
8055
8083
  }
8084
+ };
8085
+ const validatedValue = await yupValidate(valueSchema, value[key], childOptions);
8086
+ Object.defineProperty(value, key, {
8087
+ value: validatedValue,
8088
+ writable: true,
8089
+ enumerable: true,
8090
+ configurable: true
8056
8091
  });
8057
8092
  } catch (e40) {
8058
8093
  return createError({