@availity/mui-feedback 0.1.18 → 0.1.20

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/CHANGELOG.md CHANGED
@@ -2,54 +2,73 @@
2
2
 
3
3
  This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
4
4
 
5
+ ## [0.1.20](https://github.com/Availity/element/compare/@availity/mui-feedback@0.1.19...@availity/mui-feedback@0.1.20) (2024-02-20)
6
+
7
+ ### Dependency Updates
8
+
9
+ * `mui-button` updated to version `0.6.2`
10
+ * `mui-form-utils` updated to version `0.9.6`
11
+ * `mui-icon` updated to version `0.7.4`
12
+ * `mui-popover` updated to version `0.1.2`
13
+ * `mui-textfield` updated to version `0.5.11`
14
+ * `mui-toggle-button` updated to version `0.1.8`
15
+ * `mui-typography` updated to version `0.1.6`
16
+ ## [0.1.19](https://github.com/Availity/element/compare/@availity/mui-feedback@0.1.18...@availity/mui-feedback@0.1.19) (2024-02-06)
17
+
5
18
  ## [0.1.18](https://github.com/Availity/element/compare/@availity/mui-feedback@0.1.17...@availity/mui-feedback@0.1.18) (2024-01-31)
6
19
 
7
20
  ### Dependency Updates
8
21
 
9
- * `mui-form-utils` updated to version `0.9.5`
10
- * `mui-textfield` updated to version `0.5.10`
22
+ - `mui-form-utils` updated to version `0.9.5`
23
+ - `mui-textfield` updated to version `0.5.10`
24
+
11
25
  ## [0.1.17](https://github.com/Availity/element/compare/@availity/mui-feedback@0.1.16...@availity/mui-feedback@0.1.17) (2024-01-25)
12
26
 
13
27
  ### Dependency Updates
14
28
 
15
- * `mui-form-utils` updated to version `0.9.4`
16
- * `mui-textfield` updated to version `0.5.9`
29
+ - `mui-form-utils` updated to version `0.9.4`
30
+ - `mui-textfield` updated to version `0.5.9`
31
+
17
32
  ## [0.1.16](https://github.com/Availity/element/compare/@availity/mui-feedback@0.1.15...@availity/mui-feedback@0.1.16) (2024-01-12)
18
33
 
19
34
  ### Dependency Updates
20
35
 
21
- * `mui-button` updated to version `0.6.1`
22
- * `mui-form-utils` updated to version `0.9.3`
23
- * `mui-textfield` updated to version `0.5.8`
36
+ - `mui-button` updated to version `0.6.1`
37
+ - `mui-form-utils` updated to version `0.9.3`
38
+ - `mui-textfield` updated to version `0.5.8`
39
+
24
40
  ## [0.1.15](https://github.com/Availity/element/compare/@availity/mui-feedback@0.1.14...@availity/mui-feedback@0.1.15) (2024-01-12)
25
41
 
26
42
  ### Dependency Updates
27
43
 
28
- * `mui-form-utils` updated to version `0.9.2`
29
- * `mui-textfield` updated to version `0.5.7`
44
+ - `mui-form-utils` updated to version `0.9.2`
45
+ - `mui-textfield` updated to version `0.5.7`
46
+
30
47
  ## [0.1.14](https://github.com/Availity/element/compare/@availity/mui-feedback@0.1.13...@availity/mui-feedback@0.1.14) (2024-01-09)
31
48
 
32
49
  ### Dependency Updates
33
50
 
34
- * `mui-form-utils` updated to version `0.9.1`
35
- * `mui-textfield` updated to version `0.5.6`
51
+ - `mui-form-utils` updated to version `0.9.1`
52
+ - `mui-textfield` updated to version `0.5.6`
53
+
36
54
  ## [0.1.13](https://github.com/Availity/element/compare/@availity/mui-feedback@0.1.12...@availity/mui-feedback@0.1.13) (2023-12-27)
37
55
 
38
56
  ### Dependency Updates
39
57
 
40
- * `mui-form-utils` updated to version `0.9.0`
41
- * `mui-textfield` updated to version `0.5.5`
58
+ - `mui-form-utils` updated to version `0.9.0`
59
+ - `mui-textfield` updated to version `0.5.5`
42
60
 
43
61
  ### Bug Fixes
44
62
 
45
- * **mui-block-ui:** merge main branch ([8ec0ca6](https://github.com/Availity/element/commit/8ec0ca617a5b279f3657122e2c7c6b20281e3ebc))
63
+ - **mui-block-ui:** merge main branch ([8ec0ca6](https://github.com/Availity/element/commit/8ec0ca617a5b279f3657122e2c7c6b20281e3ebc))
46
64
 
47
65
  ## [0.1.12](https://github.com/Availity/element/compare/@availity/mui-feedback@0.1.11...@availity/mui-feedback@0.1.12) (2023-12-21)
48
66
 
49
67
  ### Dependency Updates
50
68
 
51
- * `mui-form-utils` updated to version `0.8.1`
52
- * `mui-textfield` updated to version `0.5.4`
69
+ - `mui-form-utils` updated to version `0.8.1`
70
+ - `mui-textfield` updated to version `0.5.4`
71
+
53
72
  ## [0.1.11](https://github.com/Availity/element/compare/@availity/mui-feedback@0.1.10...@availity/mui-feedback@0.1.11) (2023-12-15)
54
73
 
55
74
  ### Dependency Updates
package/dist/index.js CHANGED
@@ -43,6 +43,7 @@ var import_api_axios = require("@availity/api-axios");
43
43
  var import_react_hook_form = require("react-hook-form");
44
44
  var import_jsx_runtime = require("react/jsx-runtime");
45
45
  var SmileButtons = (0, import_material.styled)(import_mui_toggle_button.ToggleButtonGroup, { name: "AvFeedbackContainer", slot: "SmileButtons" })({});
46
+ var FormActions = (0, import_material.styled)(import_material.Grid, { name: "AvFeedbackContainer", slot: "FormActions" })({});
46
47
  var SmileButton = ({ disabled, Icon, label, value, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
47
48
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_mui_toggle_button.ToggleButton, {
48
49
  "aria-label": value,
@@ -166,29 +167,24 @@ var FeedbackForm = ({
166
167
  error: !!errors.feedback,
167
168
  disabled: loading
168
169
  }),
169
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_material.Grid, {
170
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(FormActions, {
170
171
  container: true,
171
172
  direction: "row",
172
- marginTop: "16px",
173
173
  spacing: 1,
174
174
  children: [
175
175
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_material.Grid, {
176
176
  item: true,
177
- xs: 6,
178
177
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_mui_button.Button, {
179
178
  color: "secondary",
180
179
  disabled: loading,
181
- fullWidth: true,
182
180
  onClick: handleClose,
183
181
  children: "Cancel"
184
182
  })
185
183
  }),
186
184
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_material.Grid, {
187
185
  item: true,
188
- xs: 6,
189
186
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_mui_button.LoadingButton, {
190
187
  disabled: !smileFieldValue,
191
- fullWidth: true,
192
188
  loading,
193
189
  type: "submit",
194
190
  variant: "contained",
@@ -210,8 +206,9 @@ var import_mui_icon2 = require("@availity/mui-icon");
210
206
  var import_mui_typography = require("@availity/mui-typography");
211
207
  var import_material2 = require("@mui/material");
212
208
  var import_jsx_runtime = require("react/jsx-runtime");
209
+ var FeedbackHeaderContainer = (0, import_material2.styled)(import_material2.Grid, { name: "AvFeedbackContainer", slot: "FeedbackHeaderContainer" })({});
213
210
  var FeedbackHeader = ({ appName, handleClose, loading, sent }) => {
214
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_material2.Grid, {
211
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(FeedbackHeaderContainer, {
215
212
  alignItems: "center",
216
213
  container: true,
217
214
  direction: "row",
@@ -246,6 +243,7 @@ var FeedbackHeader = ({ appName, handleClose, loading, sent }) => {
246
243
  // src/lib/Feedback.tsx
247
244
  var import_jsx_runtime = require("react/jsx-runtime");
248
245
  var FeedbackContainer = (0, import_material3.styled)(import_material3.Container, { name: "AvFeedbackContainer", slot: "root" })({});
246
+ var GiveFeedbackButton = (0, import_material3.styled)(import_mui_button3.Button, { name: "AvGiveFeedbackButton", slot: "root" })({});
249
247
  var Feedback = ({ analytics = import_api_axios2.avLogMessagesApi, appName }) => {
250
248
  const [anchorEl, setAnchorEl] = (0, import_react2.useState)(null);
251
249
  const [sent, setSent] = (0, import_react2.useState)(false);
@@ -260,10 +258,9 @@ var Feedback = ({ analytics = import_api_axios2.avLogMessagesApi, appName }) =>
260
258
  const open = Boolean(anchorEl);
261
259
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, {
262
260
  children: [
263
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_mui_button3.Button, {
261
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(GiveFeedbackButton, {
264
262
  onClick: handlePopoverOpen,
265
263
  color: "secondary",
266
- size: "large",
267
264
  children: "Give Feedback"
268
265
  }),
269
266
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_mui_popover.Popover, {
package/dist/index.mjs CHANGED
@@ -2,7 +2,7 @@
2
2
  import { useState } from "react";
3
3
  import { Popover } from "@availity/mui-popover";
4
4
  import { Button as Button2 } from "@availity/mui-button";
5
- import { Container, styled as styled2 } from "@mui/material";
5
+ import { Container, styled as styled3 } from "@mui/material";
6
6
  import { avLogMessagesApi } from "@availity/api-axios";
7
7
 
8
8
  // src/lib/FeedbackForm.tsx
@@ -17,6 +17,7 @@ import { avRegionsApi } from "@availity/api-axios";
17
17
  import { useForm, Controller } from "react-hook-form";
18
18
  import { jsx, jsxs } from "react/jsx-runtime";
19
19
  var SmileButtons = styled(ToggleButtonGroup, { name: "AvFeedbackContainer", slot: "SmileButtons" })({});
20
+ var FormActions = styled(Grid, { name: "AvFeedbackContainer", slot: "FormActions" })({});
20
21
  var SmileButton = ({ disabled, Icon, label, value, ...props }) => /* @__PURE__ */ jsx("div", {
21
22
  children: /* @__PURE__ */ jsx(ToggleButton, {
22
23
  "aria-label": value,
@@ -140,29 +141,24 @@ var FeedbackForm = ({
140
141
  error: !!errors.feedback,
141
142
  disabled: loading
142
143
  }),
143
- /* @__PURE__ */ jsxs(Grid, {
144
+ /* @__PURE__ */ jsxs(FormActions, {
144
145
  container: true,
145
146
  direction: "row",
146
- marginTop: "16px",
147
147
  spacing: 1,
148
148
  children: [
149
149
  /* @__PURE__ */ jsx(Grid, {
150
150
  item: true,
151
- xs: 6,
152
151
  children: /* @__PURE__ */ jsx(Button, {
153
152
  color: "secondary",
154
153
  disabled: loading,
155
- fullWidth: true,
156
154
  onClick: handleClose,
157
155
  children: "Cancel"
158
156
  })
159
157
  }),
160
158
  /* @__PURE__ */ jsx(Grid, {
161
159
  item: true,
162
- xs: 6,
163
160
  children: /* @__PURE__ */ jsx(LoadingButton, {
164
161
  disabled: !smileFieldValue,
165
- fullWidth: true,
166
162
  loading,
167
163
  type: "submit",
168
164
  variant: "contained",
@@ -182,10 +178,11 @@ var FeedbackForm = ({
182
178
  import { IconButton } from "@availity/mui-button";
183
179
  import { CloseIcon } from "@availity/mui-icon";
184
180
  import { Typography } from "@availity/mui-typography";
185
- import { Grid as Grid2 } from "@mui/material";
181
+ import { Grid as Grid2, styled as styled2 } from "@mui/material";
186
182
  import { jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
183
+ var FeedbackHeaderContainer = styled2(Grid2, { name: "AvFeedbackContainer", slot: "FeedbackHeaderContainer" })({});
187
184
  var FeedbackHeader = ({ appName, handleClose, loading, sent }) => {
188
- return /* @__PURE__ */ jsxs2(Grid2, {
185
+ return /* @__PURE__ */ jsxs2(FeedbackHeaderContainer, {
189
186
  alignItems: "center",
190
187
  container: true,
191
188
  direction: "row",
@@ -219,7 +216,8 @@ var FeedbackHeader = ({ appName, handleClose, loading, sent }) => {
219
216
 
220
217
  // src/lib/Feedback.tsx
221
218
  import { Fragment, jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
222
- var FeedbackContainer = styled2(Container, { name: "AvFeedbackContainer", slot: "root" })({});
219
+ var FeedbackContainer = styled3(Container, { name: "AvFeedbackContainer", slot: "root" })({});
220
+ var GiveFeedbackButton = styled3(Button2, { name: "AvGiveFeedbackButton", slot: "root" })({});
223
221
  var Feedback = ({ analytics = avLogMessagesApi, appName }) => {
224
222
  const [anchorEl, setAnchorEl] = useState(null);
225
223
  const [sent, setSent] = useState(false);
@@ -234,10 +232,9 @@ var Feedback = ({ analytics = avLogMessagesApi, appName }) => {
234
232
  const open = Boolean(anchorEl);
235
233
  return /* @__PURE__ */ jsxs3(Fragment, {
236
234
  children: [
237
- /* @__PURE__ */ jsx3(Button2, {
235
+ /* @__PURE__ */ jsx3(GiveFeedbackButton, {
238
236
  onClick: handlePopoverOpen,
239
237
  color: "secondary",
240
- size: "large",
241
238
  children: "Give Feedback"
242
239
  }),
243
240
  /* @__PURE__ */ jsx3(Popover, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@availity/mui-feedback",
3
- "version": "0.1.18",
3
+ "version": "0.1.20",
4
4
  "description": "Availity MUI Feedback Component - part of the @availity/element design system",
5
5
  "keywords": [
6
6
  "react",
@@ -47,13 +47,13 @@
47
47
  },
48
48
  "dependencies": {
49
49
  "@availity/api-axios": "^8.0.3",
50
- "@availity/mui-button": "^0.6.1",
51
- "@availity/mui-form-utils": "^0.9.5",
52
- "@availity/mui-icon": "^0.7.3",
53
- "@availity/mui-popover": "^0.1.1",
54
- "@availity/mui-textfield": "^0.5.10",
55
- "@availity/mui-toggle-button": "^0.1.7",
56
- "@availity/mui-typography": "^0.1.5",
50
+ "@availity/mui-button": "^0.6.2",
51
+ "@availity/mui-form-utils": "^0.9.6",
52
+ "@availity/mui-icon": "^0.7.4",
53
+ "@availity/mui-popover": "^0.1.2",
54
+ "@availity/mui-textfield": "^0.5.11",
55
+ "@availity/mui-toggle-button": "^0.1.8",
56
+ "@availity/mui-typography": "^0.1.6",
57
57
  "react-hook-form": "^7.48.2"
58
58
  }
59
59
  }
@@ -14,6 +14,8 @@ export interface FeedbackProps {
14
14
 
15
15
  const FeedbackContainer = styled(Container, { name: 'AvFeedbackContainer', slot: 'root' })({});
16
16
 
17
+ const GiveFeedbackButton = styled(Button, { name: 'AvGiveFeedbackButton', slot: 'root' })({});
18
+
17
19
  export const Feedback = ({ analytics = avLogMessagesApi, appName }: FeedbackProps): JSX.Element => {
18
20
  const [anchorEl, setAnchorEl] = useState<HTMLElement | null>(null);
19
21
  const [sent, setSent] = useState<boolean>(false);
@@ -32,9 +34,9 @@ export const Feedback = ({ analytics = avLogMessagesApi, appName }: FeedbackProp
32
34
 
33
35
  return (
34
36
  <>
35
- <Button onClick={handlePopoverOpen} color="secondary" size="large">
37
+ <GiveFeedbackButton onClick={handlePopoverOpen} color="secondary">
36
38
  Give Feedback
37
- </Button>
39
+ </GiveFeedbackButton>
38
40
  <Popover
39
41
  anchorEl={anchorEl}
40
42
  anchorOrigin={{
@@ -33,6 +33,8 @@ interface FeedbackFormProps {
33
33
 
34
34
  const SmileButtons = styled(ToggleButtonGroup, { name: 'AvFeedbackContainer', slot: 'SmileButtons' })({});
35
35
 
36
+ const FormActions = styled(Grid, { name: 'AvFeedbackContainer', slot: 'FormActions' })({});
37
+
36
38
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
37
39
  const SmileButton = ({ disabled, Icon, label, value, ...props }: SmileButtonProps) => (
38
40
  <div>
@@ -164,18 +166,18 @@ export const FeedbackForm = ({
164
166
  disabled={loading}
165
167
  />
166
168
  )}
167
- <Grid container direction="row" marginTop="16px" spacing={1}>
168
- <Grid item xs={6}>
169
- <Button color="secondary" disabled={loading} fullWidth onClick={handleClose}>
169
+ <FormActions container direction="row" spacing={1}>
170
+ <Grid item>
171
+ <Button color="secondary" disabled={loading} onClick={handleClose}>
170
172
  Cancel
171
173
  </Button>
172
174
  </Grid>
173
- <Grid item xs={6}>
174
- <LoadingButton disabled={!smileFieldValue} fullWidth loading={loading} type="submit" variant="contained">
175
+ <Grid item>
176
+ <LoadingButton disabled={!smileFieldValue} loading={loading} type="submit" variant="contained">
175
177
  Send Feedback
176
178
  </LoadingButton>
177
179
  </Grid>
178
- </Grid>
180
+ </FormActions>
179
181
  </Grid>
180
182
  );
181
183
  } else {
@@ -1,7 +1,7 @@
1
1
  import { IconButton } from '@availity/mui-button';
2
2
  import { CloseIcon } from '@availity/mui-icon';
3
3
  import { Typography } from '@availity/mui-typography';
4
- import { Grid } from '@mui/material';
4
+ import { Grid, styled } from '@mui/material';
5
5
 
6
6
  interface FeedbackHeaderProps {
7
7
  appName: string;
@@ -10,9 +10,11 @@ interface FeedbackHeaderProps {
10
10
  sent: boolean;
11
11
  }
12
12
 
13
+ const FeedbackHeaderContainer = styled(Grid, { name: 'AvFeedbackContainer', slot: 'FeedbackHeaderContainer' })({});
14
+
13
15
  export const FeedbackHeader = ({ appName, handleClose, loading, sent }: FeedbackHeaderProps): JSX.Element => {
14
16
  return (
15
- <Grid
17
+ <FeedbackHeaderContainer
16
18
  alignItems="center"
17
19
  container
18
20
  direction="row"
@@ -31,6 +33,6 @@ export const FeedbackHeader = ({ appName, handleClose, loading, sent }: Feedback
31
33
  <CloseIcon />
32
34
  </IconButton>
33
35
  </Grid>
34
- </Grid>
36
+ </FeedbackHeaderContainer>
35
37
  );
36
38
  };
File without changes