@gustavo-valsechi/client 1.4.143 → 1.4.144

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.
@@ -126,12 +126,15 @@ function InputSelect(props) {
126
126
  children: value
127
127
  }
128
128
  ),
129
- focus ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "input-icon", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("i", { "aria-hidden": true, className: "fa-solid fa-chevron-up" }) }) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
129
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
130
130
  "div",
131
131
  {
132
132
  className: "input-icon",
133
- onClick: () => inputRef.current.focus(),
134
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("i", { "aria-hidden": true, className: "fa-solid fa-chevron-down" })
133
+ "data-focus": focus,
134
+ children: [
135
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("i", { "aria-hidden": true, className: "fa-solid fa-chevron-up" }),
136
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("i", { "aria-hidden": true, className: "fa-solid fa-chevron-down" })
137
+ ]
135
138
  }
136
139
  )
137
140
  ]
@@ -93,12 +93,15 @@ function InputSelect(props) {
93
93
  children: value
94
94
  }
95
95
  ),
96
- focus ? /* @__PURE__ */ jsx("div", { className: "input-icon", children: /* @__PURE__ */ jsx("i", { "aria-hidden": true, className: "fa-solid fa-chevron-up" }) }) : /* @__PURE__ */ jsx(
96
+ /* @__PURE__ */ jsxs(
97
97
  "div",
98
98
  {
99
99
  className: "input-icon",
100
- onClick: () => inputRef.current.focus(),
101
- children: /* @__PURE__ */ jsx("i", { "aria-hidden": true, className: "fa-solid fa-chevron-down" })
100
+ "data-focus": focus,
101
+ children: [
102
+ /* @__PURE__ */ jsx("i", { "aria-hidden": true, className: "fa-solid fa-chevron-up" }),
103
+ /* @__PURE__ */ jsx("i", { "aria-hidden": true, className: "fa-solid fa-chevron-down" })
104
+ ]
102
105
  }
103
106
  )
104
107
  ]
@@ -78,7 +78,7 @@ const Container = import_styled_components.default.div`
78
78
  top: 0;
79
79
  left: 0;
80
80
  height: 100%;
81
- width: calc(100% - 2.5rem);
81
+ width: 100%;
82
82
  cursor: pointer;
83
83
  z-index: 1;
84
84
  padding: 0 1rem;
@@ -99,6 +99,34 @@ const Container = import_styled_components.default.div`
99
99
 
100
100
  i {
101
101
  font-size: .9rem;
102
+
103
+ &.fa-chevron-up {
104
+ z-index: -1;
105
+ opacity: 0;
106
+ position: fixed;
107
+ }
108
+
109
+ &.fa-chevron-down {
110
+ z-index: 0;
111
+ opacity: 1;
112
+ position: relative;
113
+ }
114
+ }
115
+
116
+ &[data-focus="true"] {
117
+ i {
118
+ &.fa-chevron-up {
119
+ z-index: 0;
120
+ opacity: 1;
121
+ position: relative;
122
+ }
123
+
124
+ &.fa-chevron-down {
125
+ z-index: -1;
126
+ opacity: 0;
127
+ position: fixed;
128
+ }
129
+ }
102
130
  }
103
131
  }
104
132
  }
@@ -45,7 +45,7 @@ const Container = styled.div`
45
45
  top: 0;
46
46
  left: 0;
47
47
  height: 100%;
48
- width: calc(100% - 2.5rem);
48
+ width: 100%;
49
49
  cursor: pointer;
50
50
  z-index: 1;
51
51
  padding: 0 1rem;
@@ -66,6 +66,34 @@ const Container = styled.div`
66
66
 
67
67
  i {
68
68
  font-size: .9rem;
69
+
70
+ &.fa-chevron-up {
71
+ z-index: -1;
72
+ opacity: 0;
73
+ position: fixed;
74
+ }
75
+
76
+ &.fa-chevron-down {
77
+ z-index: 0;
78
+ opacity: 1;
79
+ position: relative;
80
+ }
81
+ }
82
+
83
+ &[data-focus="true"] {
84
+ i {
85
+ &.fa-chevron-up {
86
+ z-index: 0;
87
+ opacity: 1;
88
+ position: relative;
89
+ }
90
+
91
+ &.fa-chevron-down {
92
+ z-index: -1;
93
+ opacity: 0;
94
+ position: fixed;
95
+ }
96
+ }
69
97
  }
70
98
  }
71
99
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gustavo-valsechi/client",
3
- "version": "1.4.143",
3
+ "version": "1.4.144",
4
4
  "main": "dist/index.js",
5
5
  "module": "dist/index.js",
6
6
  "types": "dist/index.d.ts",