@mxenabled/connect-widget 1.2.7 → 2.0.0
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/README.md +7 -2
- package/dist/index.es.js +24 -19
- package/dist/index.es.js.map +1 -1
- package/dist/lastBuild.txt +1 -1
- package/dist/style.css +5 -0
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -15,8 +15,9 @@ npm install @mxenabled/connect-widget
|
|
|
15
15
|
## Usage
|
|
16
16
|
|
|
17
17
|
1. Install package: `npm install --save @mxenabled/connect-widget`
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
1. Import the styles `import "@mxenabled/connect-widget/dist/style.css"`
|
|
19
|
+
1. Import `ApiProvider` and `ConnectWidget`. Add both to your project.
|
|
20
|
+
1. Pass applicable props to widget and your API to the provider.
|
|
20
21
|
|
|
21
22
|
```jsx
|
|
22
23
|
import ConnectWidget, { ApiProvider } from '@mxenabled/connect-widget'
|
|
@@ -96,6 +97,10 @@ Pull requests are welcome. Please open an issue first to discuss what you would
|
|
|
96
97
|
|
|
97
98
|
Make sure to add/update tests, translations, and documentation as appropriate.
|
|
98
99
|
|
|
100
|
+
### Architecture Decision Records
|
|
101
|
+
|
|
102
|
+
We have some [architecture decision records](./architectureDecisionRecords/) that outline what is expected when contributing.
|
|
103
|
+
|
|
99
104
|
## Changes
|
|
100
105
|
|
|
101
106
|
View our notes for each release [here](https://github.com/mxenabled/connect-widget/releases)
|
package/dist/index.es.js
CHANGED
|
@@ -27750,7 +27750,7 @@ process.env.NODE_ENV !== "production" ? MenuList$1.propTypes = {
|
|
|
27750
27750
|
function getStyleValue$1(value) {
|
|
27751
27751
|
return parseInt(value, 10) || 0;
|
|
27752
27752
|
}
|
|
27753
|
-
const styles$
|
|
27753
|
+
const styles$6 = {
|
|
27754
27754
|
shadow: {
|
|
27755
27755
|
// Visibility needed to hide the extra text area on iPads
|
|
27756
27756
|
visibility: "hidden",
|
|
@@ -27889,7 +27889,7 @@ const TextareaAutosize$1 = /* @__PURE__ */ React$1.forwardRef(function TextareaA
|
|
|
27889
27889
|
ref: shadowRef,
|
|
27890
27890
|
tabIndex: -1,
|
|
27891
27891
|
style: {
|
|
27892
|
-
...styles$
|
|
27892
|
+
...styles$6.shadow,
|
|
27893
27893
|
...style,
|
|
27894
27894
|
paddingTop: 0,
|
|
27895
27895
|
paddingBottom: 0
|
|
@@ -31009,7 +31009,7 @@ function getTransitionProps$1(props, options) {
|
|
|
31009
31009
|
function getScale$1(value) {
|
|
31010
31010
|
return `scale(${value}, ${value ** 2})`;
|
|
31011
31011
|
}
|
|
31012
|
-
const styles$
|
|
31012
|
+
const styles$5 = {
|
|
31013
31013
|
entering: {
|
|
31014
31014
|
opacity: 1,
|
|
31015
31015
|
transform: getScale$1(1)
|
|
@@ -31150,7 +31150,7 @@ const Grow$1 = /* @__PURE__ */ React$1.forwardRef(function Grow2(props, ref) {
|
|
|
31150
31150
|
opacity: 0,
|
|
31151
31151
|
transform: getScale$1(0.75),
|
|
31152
31152
|
visibility: state === "exited" && !inProp ? "hidden" : void 0,
|
|
31153
|
-
...styles$
|
|
31153
|
+
...styles$5[state],
|
|
31154
31154
|
...style,
|
|
31155
31155
|
...children.props.style
|
|
31156
31156
|
},
|
|
@@ -31814,7 +31814,7 @@ function useSlot(name, parameters) {
|
|
|
31814
31814
|
return [elementType, props];
|
|
31815
31815
|
}
|
|
31816
31816
|
|
|
31817
|
-
const styles$
|
|
31817
|
+
const styles$4 = {
|
|
31818
31818
|
entering: {
|
|
31819
31819
|
opacity: 1
|
|
31820
31820
|
},
|
|
@@ -31914,7 +31914,7 @@ const Fade$1 = /* @__PURE__ */ React$1.forwardRef(function Fade2(props, ref) {
|
|
|
31914
31914
|
style: {
|
|
31915
31915
|
opacity: 0,
|
|
31916
31916
|
visibility: state === "exited" && !inProp ? "hidden" : void 0,
|
|
31917
|
-
...styles$
|
|
31917
|
+
...styles$4[state],
|
|
31918
31918
|
...style,
|
|
31919
31919
|
...children.props.style
|
|
31920
31920
|
},
|
|
@@ -39229,7 +39229,7 @@ if (process.env.NODE_ENV !== "production") {
|
|
|
39229
39229
|
}
|
|
39230
39230
|
|
|
39231
39231
|
const _excluded$n = ["addEndListener", "appear", "children", "easing", "in", "onEnter", "onEntered", "onEntering", "onExit", "onExited", "onExiting", "style", "timeout", "TransitionComponent"];
|
|
39232
|
-
const styles$
|
|
39232
|
+
const styles$3 = {
|
|
39233
39233
|
entering: {
|
|
39234
39234
|
opacity: 1
|
|
39235
39235
|
},
|
|
@@ -39328,7 +39328,7 @@ const Fade = /* @__PURE__ */ React$1.forwardRef(function Fade2(props, ref) {
|
|
|
39328
39328
|
style: _extends$1({
|
|
39329
39329
|
opacity: 0,
|
|
39330
39330
|
visibility: state === "exited" && !inProp ? "hidden" : void 0
|
|
39331
|
-
}, styles$
|
|
39331
|
+
}, styles$3[state], style, children.props.style),
|
|
39332
39332
|
ref: handleRef
|
|
39333
39333
|
}, childProps));
|
|
39334
39334
|
}
|
|
@@ -40423,7 +40423,7 @@ const _excluded$i = ["onChange", "maxRows", "minRows", "style", "value"];
|
|
|
40423
40423
|
function getStyleValue(value) {
|
|
40424
40424
|
return parseInt(value, 10) || 0;
|
|
40425
40425
|
}
|
|
40426
|
-
const styles$
|
|
40426
|
+
const styles$2 = {
|
|
40427
40427
|
shadow: {
|
|
40428
40428
|
// Visibility needed to hide the extra text area on iPads
|
|
40429
40429
|
visibility: "hidden",
|
|
@@ -40559,7 +40559,7 @@ const TextareaAutosize = /* @__PURE__ */ React$1.forwardRef(function TextareaAut
|
|
|
40559
40559
|
readOnly: true,
|
|
40560
40560
|
ref: shadowRef,
|
|
40561
40561
|
tabIndex: -1,
|
|
40562
|
-
style: _extends$1({}, styles$
|
|
40562
|
+
style: _extends$1({}, styles$2.shadow, style, {
|
|
40563
40563
|
paddingTop: 0,
|
|
40564
40564
|
paddingBottom: 0
|
|
40565
40565
|
})
|
|
@@ -43667,7 +43667,7 @@ const _excluded$6 = ["addEndListener", "appear", "children", "easing", "in", "on
|
|
|
43667
43667
|
function getScale(value) {
|
|
43668
43668
|
return `scale(${value}, ${value ** 2})`;
|
|
43669
43669
|
}
|
|
43670
|
-
const styles = {
|
|
43670
|
+
const styles$1 = {
|
|
43671
43671
|
entering: {
|
|
43672
43672
|
opacity: 1,
|
|
43673
43673
|
transform: getScale(1)
|
|
@@ -43807,7 +43807,7 @@ const Grow = /* @__PURE__ */ React$1.forwardRef(function Grow2(props, ref) {
|
|
|
43807
43807
|
opacity: 0,
|
|
43808
43808
|
transform: getScale(0.75),
|
|
43809
43809
|
visibility: state === "exited" && !inProp ? "hidden" : void 0
|
|
43810
|
-
}, styles[state], style, children.props.style),
|
|
43810
|
+
}, styles$1[state], style, children.props.style),
|
|
43811
43811
|
ref: handleRef
|
|
43812
43812
|
}, childProps));
|
|
43813
43813
|
}
|
|
@@ -65664,6 +65664,11 @@ const focusElement = (element) => {
|
|
|
65664
65664
|
}
|
|
65665
65665
|
};
|
|
65666
65666
|
|
|
65667
|
+
const container = "_container_1pcxm_1";
|
|
65668
|
+
const styles = {
|
|
65669
|
+
container: container
|
|
65670
|
+
};
|
|
65671
|
+
|
|
65667
65672
|
const initialState$1 = {
|
|
65668
65673
|
currentView: SEARCH_VIEWS.LOADING,
|
|
65669
65674
|
popularInstitutions: [],
|
|
@@ -65879,7 +65884,7 @@ const Search$2 = React__default.forwardRef((props, navigationRef) => {
|
|
|
65879
65884
|
}
|
|
65880
65885
|
}, 500);
|
|
65881
65886
|
const tokens = useTokens();
|
|
65882
|
-
const
|
|
65887
|
+
const inlineStyles = getStyles$13(tokens, state.currentView);
|
|
65883
65888
|
if (state.currentView === SEARCH_VIEWS.OOPS) {
|
|
65884
65889
|
throw state.error;
|
|
65885
65890
|
}
|
|
@@ -65893,8 +65898,8 @@ const Search$2 = React__default.forwardRef((props, navigationRef) => {
|
|
|
65893
65898
|
}
|
|
65894
65899
|
);
|
|
65895
65900
|
}
|
|
65896
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", {
|
|
65897
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { style:
|
|
65901
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: styles.container, children: [
|
|
65902
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { style: inlineStyles.searchBar, children: [
|
|
65898
65903
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
65899
65904
|
x,
|
|
65900
65905
|
{
|
|
@@ -65903,7 +65908,7 @@ const Search$2 = React__default.forwardRef((props, navigationRef) => {
|
|
|
65903
65908
|
component: "h2",
|
|
65904
65909
|
"data-test": "search-header",
|
|
65905
65910
|
id: "connect-search-header",
|
|
65906
|
-
style:
|
|
65911
|
+
style: inlineStyles.headerText,
|
|
65907
65912
|
tabIndex: -1,
|
|
65908
65913
|
truncate: false,
|
|
65909
65914
|
variant: "H2",
|
|
@@ -65929,7 +65934,7 @@ const Search$2 = React__default.forwardRef((props, navigationRef) => {
|
|
|
65929
65934
|
searchInput.current.value = "";
|
|
65930
65935
|
searchInput.current.focus();
|
|
65931
65936
|
},
|
|
65932
|
-
style:
|
|
65937
|
+
style: inlineStyles.resetButton,
|
|
65933
65938
|
variant: "text",
|
|
65934
65939
|
children: /* @__PURE__ */ jsxRuntimeExports.jsx(CloseOutline, {})
|
|
65935
65940
|
}
|
|
@@ -65947,7 +65952,7 @@ const Search$2 = React__default.forwardRef((props, navigationRef) => {
|
|
|
65947
65952
|
}
|
|
65948
65953
|
)
|
|
65949
65954
|
] }),
|
|
65950
|
-
state.currentView === SEARCH_VIEWS.LOADING && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { style:
|
|
65955
|
+
state.currentView === SEARCH_VIEWS.LOADING && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { style: inlineStyles.spinner, children: /* @__PURE__ */ jsxRuntimeExports.jsx(LoadingSpinner, {}) }),
|
|
65951
65956
|
state.currentView === SEARCH_VIEWS.SEARCH_FAILED && /* @__PURE__ */ jsxRuntimeExports.jsx(SearchFailed, {}),
|
|
65952
65957
|
state.currentView === SEARCH_VIEWS.NO_RESULTS && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
65953
65958
|
SearchNoResult,
|
|
@@ -65964,7 +65969,7 @@ const Search$2 = React__default.forwardRef((props, navigationRef) => {
|
|
|
65964
65969
|
setAriaLiveRegionMessage
|
|
65965
65970
|
}
|
|
65966
65971
|
),
|
|
65967
|
-
state.currentView === SEARCH_VIEWS.SEARCH_LOADING && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { style:
|
|
65972
|
+
state.currentView === SEARCH_VIEWS.SEARCH_LOADING && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { style: inlineStyles.spinner, children: /* @__PURE__ */ jsxRuntimeExports.jsx(LoadingSpinner, {}) }),
|
|
65968
65973
|
state.currentView === SEARCH_VIEWS.SEARCHED && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
65969
65974
|
SearchedInstitutionsList,
|
|
65970
65975
|
{
|