@trackunit/react-components 1.7.22 → 1.7.24

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/index.cjs.js CHANGED
@@ -69,7 +69,6 @@ const cvaIcon = cssClassVarianceUtilities.cvaMerge(["aspect-square", "inline-gri
69
69
  transfer: "text-transfer-300",
70
70
  in_repair: "text-in_repair-400",
71
71
  other_rental_status: "text-other_rental_status-500",
72
- primary_contrasted: "text-primary_contrasted",
73
72
  },
74
73
  size: {
75
74
  small: "w-4",
@@ -122,7 +121,6 @@ const iconPalette = {
122
121
  ...uiDesignTokens.utilizationPalette,
123
122
  ...uiDesignTokens.sitesPalette,
124
123
  ...uiDesignTokens.rentalStatusPalette,
125
- ...uiDesignTokens.contrastedPalette,
126
124
  };
127
125
  const iconColorNames = sharedUtils.objectKeys(iconPalette).map(key => stringTs.snakeCase(key));
128
126
  const isSafari = () => {
@@ -486,7 +484,7 @@ const cvaButton = cssClassVarianceUtilities.cvaMerge([
486
484
  variants: {
487
485
  variant: {
488
486
  primary: [
489
- "text-primary_contrasted",
487
+ "text-white",
490
488
  "bg-primary-600",
491
489
  "hover:bg-primary-700",
492
490
  "active:bg-primary-800",
@@ -563,11 +561,13 @@ const cvaButton = cssClassVarianceUtilities.cvaMerge([
563
561
  filled: [
564
562
  "group",
565
563
  "bg-primary-100",
566
- "text-primary_contrasted",
564
+ "text-primary-600",
567
565
  "hover:bg-primary-200",
568
566
  "hover:text-primary-700",
569
567
  "active:bg-primary-200",
568
+ "active:text-primary-700",
570
569
  "focus:bg-primary-100",
570
+ "focus:text-primary-600",
571
571
  "disabled:bg-transparent",
572
572
  "disabled:text-secondary-300",
573
573
  ],
@@ -614,13 +614,7 @@ const cvaButton = cssClassVarianceUtilities.cvaMerge([
614
614
  false: "",
615
615
  },
616
616
  disabled: {
617
- true: [
618
- "cursor-not-allowed",
619
- "pointer-events-none",
620
- "bg-secondary-200",
621
- "hover:bg-secondary-200",
622
- "text-secondary-400",
623
- ],
617
+ true: ["cursor-not-allowed", "pointer-events-none", "bg-secondary-200", "hover:bg-secondary-200", "text-secondary-400"],
624
618
  false: [],
625
619
  },
626
620
  loading: {
package/index.esm.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
2
2
  import { useRef, useMemo, useEffect, useState, useCallback, createElement, useReducer, memo, forwardRef, createContext, useContext, isValidElement, cloneElement, Children } from 'react';
3
3
  import { objectKeys, uuidv4, objectEntries, objectValues } from '@trackunit/shared-utils';
4
- import { intentPalette, generalPalette, criticalityPalette, activityPalette, utilizationPalette, sitesPalette, rentalStatusPalette, contrastedPalette, themeScreenSizeAsNumber, color } from '@trackunit/ui-design-tokens';
4
+ import { intentPalette, generalPalette, criticalityPalette, activityPalette, utilizationPalette, sitesPalette, rentalStatusPalette, themeScreenSizeAsNumber, color } from '@trackunit/ui-design-tokens';
5
5
  import { iconNames } from '@trackunit/ui-icons';
6
6
  import IconSpriteMicro from '@trackunit/ui-icons/icons-sprite-micro.svg';
7
7
  import IconSpriteMini from '@trackunit/ui-icons/icons-sprite-mini.svg';
@@ -67,7 +67,6 @@ const cvaIcon = cvaMerge(["aspect-square", "inline-grid", "relative"], {
67
67
  transfer: "text-transfer-300",
68
68
  in_repair: "text-in_repair-400",
69
69
  other_rental_status: "text-other_rental_status-500",
70
- primary_contrasted: "text-primary_contrasted",
71
70
  },
72
71
  size: {
73
72
  small: "w-4",
@@ -120,7 +119,6 @@ const iconPalette = {
120
119
  ...utilizationPalette,
121
120
  ...sitesPalette,
122
121
  ...rentalStatusPalette,
123
- ...contrastedPalette,
124
122
  };
125
123
  const iconColorNames = objectKeys(iconPalette).map(key => snakeCase(key));
126
124
  const isSafari = () => {
@@ -484,7 +482,7 @@ const cvaButton = cvaMerge([
484
482
  variants: {
485
483
  variant: {
486
484
  primary: [
487
- "text-primary_contrasted",
485
+ "text-white",
488
486
  "bg-primary-600",
489
487
  "hover:bg-primary-700",
490
488
  "active:bg-primary-800",
@@ -561,11 +559,13 @@ const cvaButton = cvaMerge([
561
559
  filled: [
562
560
  "group",
563
561
  "bg-primary-100",
564
- "text-primary_contrasted",
562
+ "text-primary-600",
565
563
  "hover:bg-primary-200",
566
564
  "hover:text-primary-700",
567
565
  "active:bg-primary-200",
566
+ "active:text-primary-700",
568
567
  "focus:bg-primary-100",
568
+ "focus:text-primary-600",
569
569
  "disabled:bg-transparent",
570
570
  "disabled:text-secondary-300",
571
571
  ],
@@ -612,13 +612,7 @@ const cvaButton = cvaMerge([
612
612
  false: "",
613
613
  },
614
614
  disabled: {
615
- true: [
616
- "cursor-not-allowed",
617
- "pointer-events-none",
618
- "bg-secondary-200",
619
- "hover:bg-secondary-200",
620
- "text-secondary-400",
621
- ],
615
+ true: ["cursor-not-allowed", "pointer-events-none", "bg-secondary-200", "hover:bg-secondary-200", "text-secondary-400"],
622
616
  false: [],
623
617
  },
624
618
  loading: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trackunit/react-components",
3
- "version": "1.7.22",
3
+ "version": "1.7.24",
4
4
  "repository": "https://github.com/Trackunit/manager",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "engines": {
@@ -17,12 +17,12 @@
17
17
  "@floating-ui/react": "^0.26.25",
18
18
  "string-ts": "^2.0.0",
19
19
  "tailwind-merge": "^2.0.0",
20
- "@trackunit/ui-design-tokens": "1.6.17",
21
- "@trackunit/css-class-variance-utilities": "1.6.16",
22
- "@trackunit/shared-utils": "1.8.16",
23
- "@trackunit/ui-icons": "1.6.15",
24
- "@trackunit/react-table-pagination": "1.6.15",
25
- "@trackunit/react-test-setup": "1.3.16",
20
+ "@trackunit/ui-design-tokens": "1.6.19",
21
+ "@trackunit/css-class-variance-utilities": "1.6.18",
22
+ "@trackunit/shared-utils": "1.8.18",
23
+ "@trackunit/ui-icons": "1.6.17",
24
+ "@trackunit/react-table-pagination": "1.6.17",
25
+ "@trackunit/react-test-setup": "1.3.18",
26
26
  "@tanstack/react-router": "1.114.29"
27
27
  },
28
28
  "module": "./index.esm.js",
@@ -1,13 +1,10 @@
1
- import { ActivityColors, ContrastedPaletteColors, CriticalityColors, GeneralColors, IntentColors, RentalStatusColors, SitesColors, UtilizationColors } from "@trackunit/ui-design-tokens";
1
+ import { ActivityColors, CriticalityColors, GeneralColors, IntentColors, RentalStatusColors, SitesColors, UtilizationColors } from "@trackunit/ui-design-tokens";
2
2
  import { IconName } from "@trackunit/ui-icons";
3
3
  import { CSSProperties } from "react";
4
4
  import { CommonProps, Size } from "../../common";
5
5
  import { AriaProps } from "../../common/AriaProps";
6
- export type IconColors = IntentColors | GeneralColors | CriticalityColors | ActivityColors | UtilizationColors | SitesColors | RentalStatusColors | ContrastedPaletteColors;
6
+ export type IconColors = IntentColors | GeneralColors | CriticalityColors | ActivityColors | UtilizationColors | SitesColors | RentalStatusColors;
7
7
  export declare const iconPalette: {
8
- PRIMARY_CONTRASTED: {
9
- DEFAULT: string;
10
- };
11
8
  ON_RENT: {
12
9
  readonly 100: "219 234 254";
13
10
  readonly 400: "96 165 250";
@@ -254,7 +251,7 @@ export declare const iconPalette: {
254
251
  readonly 900: "127 29 29";
255
252
  };
256
253
  };
257
- export declare const iconColorNames: ("info" | "success" | "warning" | "danger" | "primary" | "secondary" | "neutral" | "black" | "white" | "good" | "low" | "critical" | "working" | "idle" | "stopped" | "unknown" | "moving" | "active" | "excessive_usage" | "unused" | "utilized" | "heavily_utilized" | "unknown_utilization" | "site_area" | "site_classic_poi" | "site_classic_zone" | "site_depot" | "site_work_place" | "site_construction_site" | "site_unknown" | "on_rent" | "returned" | "available" | "pickup_ready" | "transfer" | "in_repair" | "other_rental_status" | "primary_contrasted")[];
254
+ export declare const iconColorNames: ("info" | "success" | "warning" | "danger" | "primary" | "secondary" | "neutral" | "black" | "white" | "good" | "low" | "critical" | "working" | "idle" | "stopped" | "unknown" | "moving" | "active" | "excessive_usage" | "unused" | "utilized" | "heavily_utilized" | "unknown_utilization" | "site_area" | "site_classic_poi" | "site_classic_zone" | "site_depot" | "site_work_place" | "site_construction_site" | "site_unknown" | "on_rent" | "returned" | "available" | "pickup_ready" | "transfer" | "in_repair" | "other_rental_status")[];
258
255
  type IconPropsSmall = {
259
256
  size?: "small";
260
257
  type?: "solid";
@@ -1,5 +1,5 @@
1
1
  export declare const cvaIcon: (props?: ({
2
- color?: "default" | "primary" | "secondary" | "neutral" | "info" | "success" | "warning" | "danger" | "good" | "low" | "critical" | "working" | "idle" | "moving" | "active" | "excessive_usage" | "stopped" | "unknown" | "black" | "white" | "unused" | "utilized" | "heavily_utilized" | "unknown_utilization" | "site_area" | "site_classic_poi" | "site_classic_zone" | "site_depot" | "site_work_place" | "site_construction_site" | "site_unknown" | "on_rent" | "returned" | "available" | "pickup_ready" | "transfer" | "in_repair" | "other_rental_status" | "primary_contrasted" | null | undefined;
2
+ color?: "default" | "primary" | "secondary" | "neutral" | "info" | "success" | "warning" | "danger" | "good" | "low" | "critical" | "working" | "idle" | "moving" | "active" | "excessive_usage" | "stopped" | "unknown" | "black" | "white" | "unused" | "utilized" | "heavily_utilized" | "unknown_utilization" | "site_area" | "site_classic_poi" | "site_classic_zone" | "site_depot" | "site_work_place" | "site_construction_site" | "site_unknown" | "on_rent" | "returned" | "available" | "pickup_ready" | "transfer" | "in_repair" | "other_rental_status" | null | undefined;
3
3
  size?: "small" | "medium" | "large" | null | undefined;
4
4
  fontSize?: boolean | null | undefined;
5
5
  } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;