@grapadigital/shared-app-modules 0.0.97 → 0.0.98

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.
@@ -125,6 +125,15 @@ declare const CommandInput: React_2.ForwardRefExoticComponent<Omit<Omit<Pick<Pic
125
125
  onValueChange?: (search: string) => void;
126
126
  } & React_2.RefAttributes<HTMLInputElement>, "ref"> & React_2.RefAttributes<HTMLInputElement>>;
127
127
 
128
+ declare const CommandInput_2: React_2.ForwardRefExoticComponent<Omit<Omit<Pick<Pick<React_2.DetailedHTMLProps<React_2.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof React_2.InputHTMLAttributes<HTMLInputElement>> & {
129
+ ref?: React_2.Ref<HTMLInputElement>;
130
+ } & {
131
+ asChild?: boolean;
132
+ }, "asChild" | "key" | keyof React_2.InputHTMLAttributes<HTMLInputElement>>, "value" | "type" | "onChange"> & {
133
+ value?: string;
134
+ onValueChange?: (search: string) => void;
135
+ } & React_2.RefAttributes<HTMLInputElement>, "ref"> & React_2.RefAttributes<HTMLInputElement>>;
136
+
128
137
  declare interface CommissionInterface {
129
138
  marginPercentage: number;
130
139
  commissionPercentage: number;
@@ -505,6 +514,13 @@ declare interface ProfileMetric {
505
514
  medianEngagementRateStories: number;
506
515
  }
507
516
 
517
+ export declare const ProfileSelectInput: default_2.ForwardRefExoticComponent<Omit<ProfileSelectInputProps, "ref"> & default_2.RefAttributes<HTMLInputElement>>;
518
+
519
+ declare interface ProfileSelectInputProps extends Omit<default_2.ComponentProps<typeof CommandInput_2>, "onValueChange"> {
520
+ queryKey?: string[];
521
+ onValueChange: (client: ProfileInterface) => void;
522
+ }
523
+
508
524
  declare interface ProposalInterface {
509
525
  businessUnit: "enterprise" | "artistic";
510
526
  origin: "inbound" | "outbound";
@@ -1,21 +1,21 @@
1
1
  import { a as g, c as s, B as M, H as u, b as y, d as w } from "./chuncks/scroll-area.CEAE-ZuD.js";
2
- import { L as H } from "./chuncks/_influencer-select-input.component.CbVEJ529.js";
3
- import { C as le, e as se, I as ne, f as oe, P as de, a as ce, b as ge, c as xe, d as be } from "./chuncks/_influencer-select-input.component.CbVEJ529.js";
2
+ import { L as H } from "./chuncks/profile-select-input.component.CsAq2YTg.js";
3
+ import { j as le, k as se, I as ne, l as oe, P as de, e as ce, f as ge, g as xe, h as be, m as me } from "./chuncks/profile-select-input.component.CsAq2YTg.js";
4
4
  import { jsx as e, jsxs as o, Fragment as L } from "react/jsx-runtime";
5
5
  import "react";
6
6
  import { C as k, a as N } from "./chuncks/card.Cpx5Pxqx.js";
7
- import { parseISO as f, differenceInCalendarDays as _, format as j } from "date-fns";
8
- import { I as he, L as fe, P as pe, T as ue, Y as ye } from "./chuncks/youtube-icon.component.R7s6jY4w.js";
9
- const F = [
7
+ import { parseISO as f, differenceInCalendarDays as j, format as _ } from "date-fns";
8
+ import { I as fe, L as pe, P as ue, T as ye, Y as we } from "./chuncks/youtube-icon.component.R7s6jY4w.js";
9
+ const P = [
10
10
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
11
11
  ["line", { x1: "12", x2: "12", y1: "8", y2: "12", key: "1pkeuh" }],
12
12
  ["line", { x1: "12", x2: "12.01", y1: "16", y2: "16", key: "4dfq90" }]
13
- ], P = g("circle-alert", F);
13
+ ], F = g("circle-alert", P);
14
14
  const T = [
15
15
  ["rect", { width: "14", height: "14", x: "8", y: "8", rx: "2", ry: "2", key: "17jyea" }],
16
16
  ["path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2", key: "zix9uf" }]
17
17
  ], A = g("copy", T);
18
- const $ = [
18
+ const S = [
19
19
  [
20
20
  "path",
21
21
  {
@@ -27,13 +27,13 @@ const $ = [
27
27
  ["path", { d: "M10 9H8", key: "b1mrlr" }],
28
28
  ["path", { d: "M16 13H8", key: "t4e002" }],
29
29
  ["path", { d: "M16 17H8", key: "z1uh3a" }]
30
- ], D = g("file-text", $);
31
- const S = [
30
+ ], $ = g("file-text", S);
31
+ const D = [
32
32
  ["path", { d: "M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8", key: "v9h5vc" }],
33
33
  ["path", { d: "M21 3v5h-5", key: "1q7to0" }],
34
34
  ["path", { d: "M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16", key: "3uifl3" }],
35
35
  ["path", { d: "M8 16H3v5", key: "1cv678" }]
36
- ], B = g("refresh-cw", S);
36
+ ], B = g("refresh-cw", D);
37
37
  const q = [
38
38
  [
39
39
  "path",
@@ -183,7 +183,7 @@ function te({
183
183
  }) {
184
184
  let c = "";
185
185
  if (x && typeof t == "string" && !v && r) {
186
- const I = f(t), m = _(I, /* @__PURE__ */ new Date());
186
+ const I = f(t), m = j(I, /* @__PURE__ */ new Date());
187
187
  m > 15 ? c = "bg-yellow-100 font-bold" : m > 7 ? c = "bg-yellow-300 font-bold" : m >= 0 ? c = "bg-red-300 font-bold" : c = "bg-red-500 text-white font-bold";
188
188
  } else r && (c = "bg-[#ffe0b2] font-bold");
189
189
  return /* @__PURE__ */ e("div", { className: s("px-2 py-1 text-sm", c), children: /* @__PURE__ */ o(u, { openDelay: 0, closeDelay: 0, children: [
@@ -198,7 +198,7 @@ function te({
198
198
  children: [
199
199
  a,
200
200
  " ",
201
- /* @__PURE__ */ e(P, { className: "size-3.5" })
201
+ /* @__PURE__ */ e(F, { className: "size-3.5" })
202
202
  ]
203
203
  }
204
204
  ),
@@ -210,7 +210,7 @@ function te({
210
210
  i ? "text-red-600" : l ? "text-green-600" : ""
211
211
  ),
212
212
  children: [
213
- d && typeof t == "number" ? `${t.toFixed(2)}%` : x && typeof t == "string" ? j(f(t), "dd/MM/yyyy") : b && typeof t == "string" ? t : `R$ ${t.toLocaleString("pt-BR", { minimumFractionDigits: 2, maximumFractionDigits: 2 })}`,
213
+ d && typeof t == "number" ? `${t.toFixed(2)}%` : x && typeof t == "string" ? _(f(t), "dd/MM/yyyy") : b && typeof t == "string" ? t : `R$ ${t.toLocaleString("pt-BR", { minimumFractionDigits: 2, maximumFractionDigits: 2 })}`,
214
214
  C && h && /* @__PURE__ */ e(A, { size: 15, onClick: () => h(t) })
215
215
  ]
216
216
  }
@@ -230,7 +230,7 @@ function te({
230
230
  ] }) });
231
231
  }
232
232
  function ae({
233
- icon: a = D,
233
+ icon: a = $,
234
234
  title: t,
235
235
  description: n,
236
236
  tip: r,
@@ -259,8 +259,8 @@ export {
259
259
  Z as IconBadge,
260
260
  ne as Image,
261
261
  oe as InfluencerSelectInput,
262
- he as InstagramIcon,
263
- fe as LinkedInIcon,
262
+ fe as InstagramIcon,
263
+ pe as LinkedInIcon,
264
264
  ee as List,
265
265
  te as ListRow,
266
266
  ae as NotFoundCard,
@@ -269,7 +269,8 @@ export {
269
269
  ge as PageHeaderContent,
270
270
  xe as PageHeaderDescription,
271
271
  be as PageHeaderTitle,
272
- pe as PinterestIcon,
273
- ue as TikTokIcon,
274
- ye as YoutubeIcon
272
+ ue as PinterestIcon,
273
+ me as ProfileSelectInput,
274
+ ye as TikTokIcon,
275
+ we as YoutubeIcon
275
276
  };
package/dist/constants.js CHANGED
@@ -1,11 +1,10 @@
1
- import { B as L, C as N, S as d, a as u } from "./chuncks/values.constant.DO4JqXro.js";
1
+ import { B as p, C as L, S as N, d } from "./chuncks/profile-select-input.component.CsAq2YTg.js";
2
2
  import "./chuncks/scroll-area.CEAE-ZuD.js";
3
- import "./chuncks/_influencer-select-input.component.CbVEJ529.js";
4
3
  import "react/jsx-runtime";
5
4
  import "react";
6
5
  import "date-fns";
7
6
  import { P as o, L as a, Y as t, T as e, I as n } from "./chuncks/youtube-icon.component.R7s6jY4w.js";
8
- const A = "Não há dados para atualizar.", S = "O filtro selecionado já está ativo. Por favor, escolha outro filtro antes de tentar novamente.", T = "Nenhum dado novo foi informado para realizar a operação. Por favor, atualize os campos antes de tentar novamente.", c = "Não foi possível concluir a operação. Tente novamente mais tarde ou entre em contato com o suporte.", I = {
7
+ const A = "Não há dados para atualizar.", m = "O filtro selecionado já está ativo. Por favor, escolha outro filtro antes de tentar novamente.", S = "Nenhum dado novo foi informado para realizar a operação. Por favor, atualize os campos antes de tentar novamente.", T = "Não foi possível concluir a operação. Tente novamente mais tarde ou entre em contato com o suporte.", c = {
9
8
  instagram: n,
10
9
  tiktok: e,
11
10
  youtube: t,
@@ -13,13 +12,13 @@ const A = "Não há dados para atualizar.", S = "O filtro selecionado já está
13
12
  pinterest: o
14
13
  };
15
14
  export {
16
- L as BUSINESS_UNIT_VALUES,
17
- N as CLIENT_TYPE_VALUES,
18
- c as ERROR_MESSAGE,
19
- S as FILTER_ALREADY_APPLIED_MESSAGE,
15
+ p as BUSINESS_UNIT_VALUES,
16
+ L as CLIENT_TYPE_VALUES,
17
+ T as ERROR_MESSAGE,
18
+ m as FILTER_ALREADY_APPLIED_MESSAGE,
20
19
  A as NO_DATA_TO_UPDATE,
21
- T as NO_DATA_TO_UPDATE_MESSAGE,
22
- d as SOCIAL_NETWORK_COLOR_VALUES,
23
- I as SOCIAL_NETWORK_ICON_COMPONENTS,
24
- u as SOCIAL_NETWORK_VALUES
20
+ S as NO_DATA_TO_UPDATE_MESSAGE,
21
+ N as SOCIAL_NETWORK_COLOR_VALUES,
22
+ c as SOCIAL_NETWORK_ICON_COMPONENTS,
23
+ d as SOCIAL_NETWORK_VALUES
25
24
  };
package/dist/events.js CHANGED
@@ -1,4 +1,4 @@
1
- import { h as o } from "./chuncks/format.util.CM-_4aqn.js";
1
+ import { h as o } from "./chuncks/format.util._bJLlJpl.js";
2
2
  const i = (t, a) => {
3
3
  const e = t.target.value, n = o(e);
4
4
  n !== !1 && a(n);
package/dist/hooks.d.ts CHANGED
@@ -2,6 +2,7 @@ declare interface Environments {
2
2
  readonly VITE_BACKEND_API_DATASERVICES_URL?: string;
3
3
  readonly VITE_BACKEND_API_CAMPAIGNS_URL?: string;
4
4
  readonly VITE_BACKEND_API_USERS_URL?: string;
5
+ readonly VITE_BACKEND_API_MANAGEMENT_URL?: string;
5
6
  }
6
7
 
7
8
  declare interface SharedAppModulesContextData {
@@ -4,6 +4,7 @@ declare interface Environments {
4
4
  readonly VITE_BACKEND_API_DATASERVICES_URL?: string;
5
5
  readonly VITE_BACKEND_API_CAMPAIGNS_URL?: string;
6
6
  readonly VITE_BACKEND_API_USERS_URL?: string;
7
+ readonly VITE_BACKEND_API_MANAGEMENT_URL?: string;
7
8
  }
8
9
 
9
10
  declare interface SharedAppModulesContextProps {
package/dist/utils.js CHANGED
@@ -1,18 +1,19 @@
1
- import { f as e, a as r, b as m, c as t, i as o, j as i, k as c, l as n, m as p, d as C, e as k, g as u, p as f, h as P, u as N } from "./chuncks/format.util.CM-_4aqn.js";
1
+ import { f as e, a as r, b as m, c as t, m as o, d as c, e as i, g as n, p, h as C, u as f } from "./chuncks/format.util._bJLlJpl.js";
2
+ import { i as k, a as P, b, c as N } from "./chuncks/profile-select-input.component.CsAq2YTg.js";
2
3
  export {
3
4
  e as formatCompactNumber,
4
5
  r as formatCompactPercent,
5
6
  m as formatCurrency,
6
7
  t as formatPercentage,
7
- o as isBusinessUnit,
8
- i as isClientType,
9
- c as isNumber,
10
- n as isSocialNetwork,
11
- p as maskCNPJ,
12
- C as maskCPF,
13
- k as maskRG,
14
- u as maskZipCode,
15
- f as preFormatCurrency,
16
- P as preFormatPercentage,
17
- N as unmask
8
+ k as isBusinessUnit,
9
+ P as isClientType,
10
+ b as isNumber,
11
+ N as isSocialNetwork,
12
+ o as maskCNPJ,
13
+ c as maskCPF,
14
+ i as maskRG,
15
+ n as maskZipCode,
16
+ p as preFormatCurrency,
17
+ C as preFormatPercentage,
18
+ f as unmask
18
19
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@grapadigital/shared-app-modules",
3
3
  "private": false,
4
- "version": "0.0.97",
4
+ "version": "0.0.98",
5
5
  "files": [
6
6
  "dist"
7
7
  ],
@@ -116,12 +116,9 @@
116
116
  }
117
117
  },
118
118
  "type": "module",
119
- "scripts": {
120
- "dev": "vite",
121
- "build": "rm -rf dist && tsc -b && vite build",
122
- "lint": "eslint .",
123
- "preview": "vite preview",
124
- "lib:publish": "pnpm build && pnpm publish --no-git-checks"
119
+ "peerDependencies": {
120
+ "react": "^18.3.1",
121
+ "react-dom": "^18.3.1"
125
122
  },
126
123
  "dependencies": {
127
124
  "@radix-ui/react-accordion": "^1.2.12",
@@ -146,9 +143,7 @@
146
143
  "date-fns": "^4.1.0",
147
144
  "lucide-react": "^0.555.0",
148
145
  "radix-ui": "^1.4.3",
149
- "react": "^18.3.1",
150
146
  "react-day-picker": "^9.11.3",
151
- "react-dom": "^18.3.1",
152
147
  "react-router-dom": "^7.10.1",
153
148
  "recharts": "2.15.4",
154
149
  "tailwind-merge": "^3.4.0",
@@ -174,5 +169,12 @@
174
169
  "vite": "^7.2.4",
175
170
  "vite-plugin-dts": "^4.5.4",
176
171
  "vite-plugin-lib-inject-css": "^2.2.2"
172
+ },
173
+ "scripts": {
174
+ "dev": "vite",
175
+ "build": "rm -rf dist && tsc -b && vite build",
176
+ "lint": "eslint .",
177
+ "preview": "vite preview",
178
+ "lib:publish": "pnpm build && pnpm publish --no-git-checks"
177
179
  }
178
- }
180
+ }
@@ -1,85 +0,0 @@
1
- import { B as a, C as c, a as i } from "./values.constant.DO4JqXro.js";
2
- import "./scroll-area.CEAE-ZuD.js";
3
- import "./_influencer-select-input.component.CbVEJ529.js";
4
- import "react/jsx-runtime";
5
- import "react";
6
- import "date-fns";
7
- function n(r) {
8
- return !isNaN(Number(r));
9
- }
10
- function d(r) {
11
- return typeof r != "string" || !r ? !1 : r in i;
12
- }
13
- function g(r) {
14
- return typeof r != "string" || !r ? !1 : r in c;
15
- }
16
- function $(r) {
17
- return typeof r != "string" || !r ? !1 : r in a;
18
- }
19
- function V(r) {
20
- const t = r.replace(/[^0-9]/g, "");
21
- return Number(t) / 100;
22
- }
23
- function N(r) {
24
- return r.toLocaleString("pt-BR", {
25
- style: "currency",
26
- currency: "BRL"
27
- });
28
- }
29
- const y = (r) => {
30
- const t = n(r) ? r : Number(r);
31
- return `${parseInt(String(t * 100))}%`;
32
- }, D = (r) => {
33
- const t = +String(r).replace("%", "");
34
- if (!n(t)) return !1;
35
- const e = t / 100;
36
- return +String(e).split(".")[0] >= 1 ? 1 : e;
37
- };
38
- function S(r) {
39
- return r.replace(/\D/g, "").replace(/^(\d{3})(\d{3})(\d{3})(\d{2})$/, "$1.$2.$3-$4");
40
- }
41
- function C(r) {
42
- return r.replace(/\D/g, "").replace(/^(\d{2})(\d{3})(\d{3})(\d{1})$/, "$1.$2.$3-$4");
43
- }
44
- function b(r) {
45
- return r.replace(/\D/g, "").replace(
46
- /^(\d{2})(\d{3})(\d{3})(\d{4})(\d{2})$/,
47
- "$1.$2.$3/$4-$5"
48
- );
49
- }
50
- function F(r) {
51
- return r.replace(/\D/g, "").replace(/^(\d{5})(\d{3})$/, "$1-$2");
52
- }
53
- function P(r) {
54
- return r.replace(/\D/g, "");
55
- }
56
- const k = (r) => new Intl.NumberFormat("pt-BR", {
57
- style: "decimal",
58
- notation: "compact",
59
- compactDisplay: "short",
60
- minimumFractionDigits: 0,
61
- maximumFractionDigits: 3
62
- }).format(r), B = (r) => new Intl.NumberFormat("pt-BR", {
63
- style: "percent",
64
- notation: "compact",
65
- compactDisplay: "short",
66
- minimumFractionDigits: 0,
67
- maximumFractionDigits: 2
68
- }).format(r);
69
- export {
70
- B as a,
71
- N as b,
72
- y as c,
73
- S as d,
74
- C as e,
75
- k as f,
76
- F as g,
77
- D as h,
78
- $ as i,
79
- g as j,
80
- n as k,
81
- d as l,
82
- b as m,
83
- V as p,
84
- P as u
85
- };
@@ -1,25 +0,0 @@
1
- const t = {
2
- instagram: "Instagram",
3
- tiktok: "TikTok",
4
- youtube: "YouTube",
5
- linkedin: "LinkedIn",
6
- pinterest: "Pinterest"
7
- }, a = {
8
- agency: "Agência",
9
- brand: "Marca"
10
- }, i = {
11
- enterprise: "Empresa",
12
- artistic: "Artística"
13
- }, e = {
14
- instagram: "bg-gradient-to-br from-[#f09433] via-[#e6683c] via-[#dc2743] via-[#cc2366] to-[#bc1888]",
15
- tiktok: "bg-black",
16
- youtube: "bg-[#ff0033]",
17
- linkedin: "bg-[#0a66c2]",
18
- pinterest: "bg-[#e60023]"
19
- };
20
- export {
21
- i as B,
22
- a as C,
23
- e as S,
24
- t as a
25
- };