wca-designsystem 0.0.53 → 0.0.54

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/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.0.53",
2
+ "version": "0.0.54",
3
3
  "license": "MIT",
4
4
  "main": "dist/index.js",
5
5
  "typings": "dist/index.d.ts",
@@ -9,12 +9,14 @@ export type NavbarTituloHeaderProps = {
9
9
  icon: string;
10
10
  isNavHover: boolean;
11
11
  color?: string;
12
+ onTrocarModulos?: () => void;
12
13
  };
13
14
  const NavbarTituloHeader = ({
14
15
  modulo,
15
16
  color = theme.colors.blue,
16
17
  icon,
17
18
  isNavHover,
19
+ onTrocarModulos,
18
20
  }: NavbarTituloHeaderProps) => {
19
21
  return (
20
22
  <S.NavbarTituloHeaderWrapper data-active={isNavHover} color={color}>
@@ -25,7 +27,13 @@ const NavbarTituloHeader = ({
25
27
  <h3>{modulo}</h3>
26
28
  </S.LinkText>
27
29
  </S.LinkInfo>
28
- <Icone fill={theme.colors.white} svg={trocarModulo} />
30
+ <button
31
+ className="acessar-modulos"
32
+ title="Acessar Modulos"
33
+ onClick={onTrocarModulos}
34
+ >
35
+ <Icone fill={theme.colors.white} svg={trocarModulo} />
36
+ </button>
29
37
  </S.NavbarTituloHeaderWrapper>
30
38
  );
31
39
  };
@@ -14,6 +14,11 @@ export const NavbarTituloHeaderWrapper = styled.div<NavbarTTituloType>`
14
14
  justify-content: space-around;
15
15
  padding: 10px;
16
16
 
17
+ .acessar-modulos {
18
+ background-color: transparent;
19
+ border: none;
20
+ cursor: pointer;
21
+ }
17
22
  &[data-active='true'] {
18
23
  display: flex;
19
24
  opacity: 1;
@@ -22,6 +22,7 @@ export const Primary: Story = {
22
22
  titulo:"exemplo",
23
23
  color: theme.colors.blue,
24
24
  modulo: 'exemplo',
25
+ onTrocarModulos:() => console.log('trocar modulos'),
25
26
  notificacoes: {
26
27
  abre: true,
27
28
  notificacao: {
@@ -22,6 +22,7 @@ type ConchaAplicacaolType = {
22
22
  titulo: string;
23
23
  subTitulo: string;
24
24
  info: string;
25
+ onTrocarModulos?: () => void;
25
26
  };
26
27
  export function ConchaAplicacao({
27
28
  children,
@@ -31,6 +32,7 @@ export function ConchaAplicacao({
31
32
  icone,
32
33
  info,
33
34
  subTitulo,
35
+ onTrocarModulos,
34
36
  titulo,
35
37
  sairFunc,
36
38
  activeLink,
@@ -58,6 +60,7 @@ export function ConchaAplicacao({
58
60
  modulo={modulo}
59
61
  isHover={isNavHover}
60
62
  links={links}
63
+ onTrocarModulos={onTrocarModulos!}
61
64
  />
62
65
  </S.NavbarWrapper>
63
66
  <S.ConchaAplicacaoMainWrapper>
@@ -13,6 +13,7 @@ const props = {
13
13
  links: LinksDinamicosMock,
14
14
  module: 'Exemplo',
15
15
  activeLink: 'Usuários',
16
+ onTrocarModulos: () => console.log('aqui'),
16
17
  };
17
18
 
18
19
  const Template: any = (args: NavbarType) => (
@@ -20,11 +20,13 @@ export type NavbarType = {
20
20
  activeLink: string;
21
21
  sairFunc: () => void;
22
22
  color?: string;
23
+ onTrocarModulos?: (() => void) | undefined;
23
24
  };
24
25
  const Navbar = ({
25
26
  isHover,
26
27
  sairFunc,
27
28
  links,
29
+ onTrocarModulos,
28
30
  modulo,
29
31
  activeLink,
30
32
  color = theme.colors.blue,
@@ -38,7 +40,6 @@ const Navbar = ({
38
40
  color={isHover ? theme.colors.white : color}
39
41
  >
40
42
  <div>
41
-
42
43
  <S.NavbarHeader className={isHover ? 'nav-hover' : ''}>
43
44
  <Icone
44
45
  svg={LogoHeader}
@@ -71,6 +72,7 @@ const Navbar = ({
71
72
  <NavbarTituloHeader
72
73
  isNavHover={isHover}
73
74
  color={color}
75
+ onTrocarModulos={onTrocarModulos}
74
76
  modulo={modulo}
75
77
  icon={CiclosEncerrados}
76
78
  />
@@ -16,7 +16,7 @@ export const NavbarWrapper = styled.div<NavbarWrapperProps>`
16
16
  display: flex;
17
17
  align-items: normal;
18
18
  justify-content: space-between;
19
- flex-direction: inherit;
19
+ flex-direction: column;
20
20
 
21
21
  .logo {
22
22
  margin: 30px 0;
@@ -69,8 +69,8 @@ const TabelaHeader = <T extends { id: string | number; children: Array<T> }>({
69
69
  <SelectCustomizado
70
70
  tipo="table"
71
71
  data={[
72
- { value: 'Maior', label: 'Ordenar por: Maior' },
73
- { value: 'Menor', label: 'Ordenar por: Menor' },
72
+ { value: 'Maior', label: 'Ordenar por: Decrescente' },
73
+ { value: 'Menor', label: 'Ordenar por: Crescente' },
74
74
  ]}
75
75
  onChange={(_value, option) => setOrdenarPor!(option)}
76
76
  value={ordenarPor ? ordenarPor.value : null}
@@ -168,7 +168,7 @@ const columns: any = [
168
168
  { key: 'name', header: 'Nome' },
169
169
  { key: 'price', header: 'Preço' },
170
170
  { key: 'exemplo', header: 'Exemplo' },
171
- { key: 'acoes', header: 'acoes' },
171
+ { key: 'acoes', header: 'Ações' },
172
172
  ];
173
173
 
174
174
  const Template: any = (args: any) => (
@@ -126,7 +126,7 @@ export const TabelaBody = styled.tbody<ColorsProp>`
126
126
  }
127
127
 
128
128
  &:hover {
129
- opacity: 0.8;
129
+ /* opacity: 0.8; */
130
130
  background: ${theme.colors.white};
131
131
  }
132
132
 
@@ -1,35 +1,35 @@
1
1
  export function pxToRem(pxValue: number) {
2
2
  const baseFontSizePx = 16; // Tamanho da fonte base em pixels
3
3
  const remValue = pxValue / baseFontSizePx;
4
- return remValue + "rem";
4
+ return remValue + 'rem';
5
5
  }
6
6
 
7
7
  export const commonColors = {
8
- success: "#03C668",
9
- alert: "#FFd638",
10
- blue: "#3532a4",
11
- blueNew: "rgba(58, 151, 237, 1)",
12
- red: "#DE0015",
13
- white: "#fff",
8
+ success: '#03C668',
9
+ alert: '#FFd638',
10
+ blue: '#3532a4',
11
+ blueNew: 'rgba(58, 151, 237, 1)',
12
+ red: '#DE0015',
13
+ white: '#fff',
14
14
  gray: {
15
- 700: "#87868a",
16
- 500: "#CBCBCB",
17
- 300: "#eeeeee"
18
- }
15
+ 700: '#87868a',
16
+ 500: '#CBCBCB',
17
+ 300: '#eeeeee',
18
+ },
19
19
  };
20
20
  export const stiColors = {
21
- blackSti: "#010002",
22
- redSti: "#911f20"
21
+ blackSti: '#010002',
22
+ redSti: '#911f20',
23
23
  };
24
24
  export const wcaColors = {
25
- blackWca: "#231F20",
26
- yellowWca: "#FFCB05"
25
+ blackWca: '#231F20',
26
+ yellowWca: '#FFCB05',
27
27
  };
28
28
  export const secColors = {
29
- orangeSec: "#E96C2D",
30
- magentaSec: "#FD3E81",
31
- purpleSec: "#632D76",
32
- greenSec: "#339642"
29
+ orangeSec: '#E96C2D',
30
+ magentaSec: '#FD3E81',
31
+ purpleSec: '#b930c5',
32
+ greenSec: '#339642',
33
33
  };
34
34
  export const fontSizes = {
35
35
  xSmall: pxToRem(10),
@@ -37,13 +37,13 @@ export const fontSizes = {
37
37
  meddium: pxToRem(14),
38
38
  large: pxToRem(16),
39
39
  xLarge: pxToRem(18),
40
- xxLarge: pxToRem(32)
40
+ xxLarge: pxToRem(32),
41
41
  };
42
42
  export const responsive = {
43
- sm: "576px",
44
- md: "768px",
45
- lg: "992px",
46
- xl: "1200px"
43
+ sm: '576px',
44
+ md: '768px',
45
+ lg: '992px',
46
+ xl: '1200px',
47
47
  };
48
48
 
49
49
  export const theme = {
@@ -51,12 +51,12 @@ export const theme = {
51
51
  ...commonColors,
52
52
  ...stiColors,
53
53
  ...wcaColors,
54
- ...secColors
54
+ ...secColors,
55
55
  },
56
56
  sizes: {
57
- ...fontSizes
57
+ ...fontSizes,
58
58
  },
59
- responsive: { ...responsive }
59
+ responsive: { ...responsive },
60
60
  };
61
61
 
62
62
  export type ThemeType = typeof theme;