@clickpalm/react 1.3.5 → 1.3.7

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/dist/index.d.ts CHANGED
@@ -3816,6 +3816,7 @@ declare const Paragraph: {
3816
3816
 
3817
3817
  declare const StyledHeading: _stitches_react_types_styled_component.StyledComponent<"h2", {
3818
3818
  size?: "sm" | "md" | "lg" | "2xl" | "4xl" | "5xl" | "6xl" | "3xl" | undefined;
3819
+ bold?: boolean | "true" | "false" | undefined;
3819
3820
  }, {
3820
3821
  sm: "(min-width: 375px)";
3821
3822
  md: "(min-width: 768px)";
@@ -4041,6 +4042,7 @@ interface HeadingProps extends ComponentPropsWithoutRef<'h2'>, VariantProps<type
4041
4042
  css?: CustomCSS$1;
4042
4043
  children?: React.ReactNode;
4043
4044
  size?: 'sm' | 'md' | 'lg' | '2xl' | '3xl' | '4xl' | '5xl' | '6xl';
4045
+ bold?: boolean;
4044
4046
  }
4045
4047
  declare const Heading: react.ForwardRefExoticComponent<HeadingProps & react.RefAttributes<HTMLHeadingElement>>;
4046
4048
 
package/dist/index.js CHANGED
@@ -2564,7 +2564,10 @@ var CharCounter2 = styled(Span5, {
2564
2564
  var TextArea = (0, import_react13.forwardRef)(
2565
2565
  ({ label, id, htmlFor, errorMessage, maxLength, showCounter = false, ...props }, ref) => {
2566
2566
  const textAreaId = id || htmlFor || `textarea-${crypto.randomUUID()}`;
2567
- const [charCount, setCharCount] = (0, import_react13.useState)(0);
2567
+ const [charCount, setCharCount] = (0, import_react13.useState)(props.value?.toString().length || 0);
2568
+ (0, import_react13.useEffect)(() => {
2569
+ setCharCount(props.value?.toString().length || 0);
2570
+ }, [props.value]);
2568
2571
  return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(Wrapper4, { children: [
2569
2572
  label && /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(StyledLabel2, { htmlFor: textAreaId, children: label }),
2570
2573
  /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
@@ -3070,6 +3073,7 @@ var StyledHeading = styled("h2", {
3070
3073
  lineHeight: "$shorter",
3071
3074
  margin: "1px",
3072
3075
  color: "$black",
3076
+ fontWeight: "$regular",
3073
3077
  variants: {
3074
3078
  size: {
3075
3079
  sm: { fontSize: "$xl" },
@@ -3080,15 +3084,25 @@ var StyledHeading = styled("h2", {
3080
3084
  "4xl": { fontSize: "$7xl" },
3081
3085
  "5xl": { fontSize: "$8xl" },
3082
3086
  "6xl": { fontSize: "$9xl" }
3087
+ },
3088
+ bold: {
3089
+ true: {
3090
+ fontWeight: "$bold"
3091
+ },
3092
+ false: {
3093
+ fontWeight: "$regular"
3094
+ }
3083
3095
  }
3084
3096
  },
3085
3097
  defaultVariants: {
3086
3098
  size: "md"
3087
3099
  }
3088
3100
  });
3089
- var Heading = (0, import_react17.forwardRef)(function Heading2({ children, ...props }, ref) {
3090
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(StyledHeading, { ref, ...props, children });
3091
- });
3101
+ var Heading = (0, import_react17.forwardRef)(
3102
+ function Heading2({ children, bold = false, ...props }, ref) {
3103
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(StyledHeading, { ref, bold, ...props, children });
3104
+ }
3105
+ );
3092
3106
  Heading.displayName = "Heading";
3093
3107
 
3094
3108
  // src/components/Select/index.tsx
@@ -3275,6 +3289,9 @@ var import_react19 = require("react");
3275
3289
  // src/components/LabelledValue/styles.ts
3276
3290
  var Container = styled("div", {
3277
3291
  display: "flex",
3292
+ fontWeight: "$regular",
3293
+ fontSize: "$md",
3294
+ fontFamily: "$default",
3278
3295
  variants: {
3279
3296
  position: {
3280
3297
  vertical: {
@@ -3292,6 +3309,9 @@ var Container = styled("div", {
3292
3309
  var ItemWrapper = styled("div", {
3293
3310
  display: "flex",
3294
3311
  alignItems: "center",
3312
+ fontWeight: "$regular",
3313
+ fontSize: "$md",
3314
+ fontFamily: "$default",
3295
3315
  variants: {
3296
3316
  position: {
3297
3317
  vertical: {
@@ -3317,12 +3337,14 @@ var ItemWrapper = styled("div", {
3317
3337
  var Label4 = styled("div", {
3318
3338
  fontWeight: "$regular",
3319
3339
  fontSize: "$md",
3340
+ fontFamily: "$default",
3320
3341
  color: "$black",
3321
3342
  whiteSpace: "nowrap"
3322
3343
  });
3323
3344
  var Value2 = styled("div", {
3324
3345
  fontWeight: "$bold",
3325
3346
  fontSize: "$md",
3347
+ fontFamily: "$default",
3326
3348
  color: "$black",
3327
3349
  textAlign: "right",
3328
3350
  wordBreak: "break-word",
package/dist/index.mjs CHANGED
@@ -2384,7 +2384,7 @@ var Tabs2 = ({ defaultValue, colorContent, children, value, onValueChange }) =>
2384
2384
  Tabs2.Item = TabsItem;
2385
2385
 
2386
2386
  // src/components/TextArea.tsx
2387
- import { forwardRef as forwardRef8, useState as useState7 } from "react";
2387
+ import { forwardRef as forwardRef8, useEffect as useEffect6, useState as useState7 } from "react";
2388
2388
  import { jsx as jsx30, jsxs as jsxs12 } from "react/jsx-runtime";
2389
2389
  var Wrapper4 = styled("div", {
2390
2390
  display: "flex",
@@ -2494,7 +2494,10 @@ var CharCounter2 = styled(Span5, {
2494
2494
  var TextArea = forwardRef8(
2495
2495
  ({ label, id, htmlFor, errorMessage, maxLength, showCounter = false, ...props }, ref) => {
2496
2496
  const textAreaId = id || htmlFor || `textarea-${crypto.randomUUID()}`;
2497
- const [charCount, setCharCount] = useState7(0);
2497
+ const [charCount, setCharCount] = useState7(props.value?.toString().length || 0);
2498
+ useEffect6(() => {
2499
+ setCharCount(props.value?.toString().length || 0);
2500
+ }, [props.value]);
2498
2501
  return /* @__PURE__ */ jsxs12(Wrapper4, { children: [
2499
2502
  label && /* @__PURE__ */ jsx30(StyledLabel2, { htmlFor: textAreaId, children: label }),
2500
2503
  /* @__PURE__ */ jsx30(
@@ -2578,7 +2581,7 @@ var TooltipArrow = styled(RadixTooltip.Arrow, {
2578
2581
  });
2579
2582
 
2580
2583
  // src/components/Tooltip/index.tsx
2581
- import { useState as useState8, useEffect as useEffect6 } from "react";
2584
+ import { useState as useState8, useEffect as useEffect7 } from "react";
2582
2585
  import { jsx as jsx31, jsxs as jsxs13 } from "react/jsx-runtime";
2583
2586
  var Tooltip = ({
2584
2587
  content,
@@ -2591,7 +2594,7 @@ var Tooltip = ({
2591
2594
  }) => {
2592
2595
  const [uncontrolledOpen, setUncontrolledOpen] = useState8(false);
2593
2596
  const [isTouchDevice, setIsTouchDevice] = useState8(false);
2594
- useEffect6(() => {
2597
+ useEffect7(() => {
2595
2598
  setIsTouchDevice("ontouchstart" in window || navigator.maxTouchPoints > 0);
2596
2599
  }, []);
2597
2600
  const open = controlledOpen ?? uncontrolledOpen;
@@ -3000,6 +3003,7 @@ var StyledHeading = styled("h2", {
3000
3003
  lineHeight: "$shorter",
3001
3004
  margin: "1px",
3002
3005
  color: "$black",
3006
+ fontWeight: "$regular",
3003
3007
  variants: {
3004
3008
  size: {
3005
3009
  sm: { fontSize: "$xl" },
@@ -3010,15 +3014,25 @@ var StyledHeading = styled("h2", {
3010
3014
  "4xl": { fontSize: "$7xl" },
3011
3015
  "5xl": { fontSize: "$8xl" },
3012
3016
  "6xl": { fontSize: "$9xl" }
3017
+ },
3018
+ bold: {
3019
+ true: {
3020
+ fontWeight: "$bold"
3021
+ },
3022
+ false: {
3023
+ fontWeight: "$regular"
3024
+ }
3013
3025
  }
3014
3026
  },
3015
3027
  defaultVariants: {
3016
3028
  size: "md"
3017
3029
  }
3018
3030
  });
3019
- var Heading = forwardRef10(function Heading2({ children, ...props }, ref) {
3020
- return /* @__PURE__ */ jsx37(StyledHeading, { ref, ...props, children });
3021
- });
3031
+ var Heading = forwardRef10(
3032
+ function Heading2({ children, bold = false, ...props }, ref) {
3033
+ return /* @__PURE__ */ jsx37(StyledHeading, { ref, bold, ...props, children });
3034
+ }
3035
+ );
3022
3036
  Heading.displayName = "Heading";
3023
3037
 
3024
3038
  // src/components/Select/index.tsx
@@ -3209,6 +3223,9 @@ import {
3209
3223
  // src/components/LabelledValue/styles.ts
3210
3224
  var Container = styled("div", {
3211
3225
  display: "flex",
3226
+ fontWeight: "$regular",
3227
+ fontSize: "$md",
3228
+ fontFamily: "$default",
3212
3229
  variants: {
3213
3230
  position: {
3214
3231
  vertical: {
@@ -3226,6 +3243,9 @@ var Container = styled("div", {
3226
3243
  var ItemWrapper = styled("div", {
3227
3244
  display: "flex",
3228
3245
  alignItems: "center",
3246
+ fontWeight: "$regular",
3247
+ fontSize: "$md",
3248
+ fontFamily: "$default",
3229
3249
  variants: {
3230
3250
  position: {
3231
3251
  vertical: {
@@ -3251,12 +3271,14 @@ var ItemWrapper = styled("div", {
3251
3271
  var Label4 = styled("div", {
3252
3272
  fontWeight: "$regular",
3253
3273
  fontSize: "$md",
3274
+ fontFamily: "$default",
3254
3275
  color: "$black",
3255
3276
  whiteSpace: "nowrap"
3256
3277
  });
3257
3278
  var Value2 = styled("div", {
3258
3279
  fontWeight: "$bold",
3259
3280
  fontSize: "$md",
3281
+ fontFamily: "$default",
3260
3282
  color: "$black",
3261
3283
  textAlign: "right",
3262
3284
  wordBreak: "break-word",
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "Design System da Clikpalm",
4
4
  "author": "Enisson Shilo",
5
5
  "license": "MIT",
6
- "version": "1.3.5",
6
+ "version": "1.3.7",
7
7
  "repository": {
8
8
  "type": "git",
9
9
  "url": "git+https://github.com/clickpalm/clickpalm-designsystem-lib.git"