@nnc-digital/nnc-design-system 0.4.21 → 0.4.23

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/build/index.js CHANGED
@@ -4415,7 +4415,7 @@ var BinCollection = function (_a) {
4415
4415
  var selectedUPRN = e.target.value;
4416
4416
  if (selectedUPRN) {
4417
4417
  var startDate = getFormattedDate();
4418
- var endDate = getFormattedDate(42);
4418
+ var endDate = getFormattedDate(28);
4419
4419
  // Fetch calendar events for the selected UPRN
4420
4420
  axios__default["default"].get("".concat(CalendarEventsApiUrl).concat(selectedUPRN, "/").concat(startDate, "/").concat(endDate))
4421
4421
  .then(function (response) {
@@ -23266,12 +23266,79 @@ const AccessibleLinks = styled__default["default"].a`
23266
23266
 
23267
23267
  `;
23268
23268
 
23269
+ const SkipToMainContent$1 = styled__default["default"].a`
23270
+ ${props => props.theme.fontStyles}
23271
+
23272
+ position: absolute;
23273
+ width: 1px;
23274
+ height: 1px;
23275
+ margin: 0;
23276
+ overflow: hidden;
23277
+ clip: rect(0 0 0 0);
23278
+ clip-path: inset(50%);
23279
+ white-space: nowrap;
23280
+ display: block;
23281
+ padding: 10px 15px;
23282
+
23283
+ &:active,
23284
+ &:focus {
23285
+ position: static;
23286
+ width: auto;
23287
+ height: auto;
23288
+ margin: inherit;
23289
+ overflow: visible;
23290
+ clip: auto;
23291
+ -webkit-clip-path: none;
23292
+ clip-path: none;
23293
+ white-space: inherit
23294
+ }
23295
+
23296
+ &:link,
23297
+ &:visited,
23298
+ &:hover,
23299
+ &:active,
23300
+ &:focus {
23301
+ color: ${props => props.theme.theme_vars.colours.black};
23302
+ }
23303
+
23304
+
23305
+
23306
+ @media (min-width: 40.0625em) {
23307
+ font-size: 16px;
23308
+ font-size: 1rem;
23309
+ line-height: 1.25
23310
+ }
23311
+
23312
+
23313
+
23314
+ &:focus {
23315
+ outline: 3px solid ${props => props.theme.theme_vars.colours.focus};
23316
+ outline-offset: 0;
23317
+ background-color: ${props => props.theme.theme_vars.colours.focus};
23318
+ }
23319
+
23320
+
23321
+
23322
+
23323
+ `;
23324
+
23325
+ var SkipToMainContent = function () { return (React__default["default"].createElement(SkipToMainContent$1, { "data-testid": "SkipToMainContent", href: "#main" }, "Skip to main content")); };
23326
+
23269
23327
  var AccessibleLink = function (_a) {
23270
- var _b = _a.AccessibleLinksArray, AccessibleLinksArray = _b === void 0 ? null : _b;
23271
- return (React__default["default"].createElement(AccessibleList, null, AccessibleLinksArray && AccessibleLinksArray.map(function (link, i) {
23272
- return React__default["default"].createElement(AccessibleListItem, { key: 'accessible-link-li-' + i },
23273
- React__default["default"].createElement(AccessibleLinks, { key: 'accessible-link-' + i, href: link.url }, link.title));
23274
- })));
23328
+ var _b = _a.AccessibleLinksArray, AccessibleLinksArray = _b === void 0 ? null : _b, _c = _a.includeSkipToMainContent, includeSkipToMainContent = _c === void 0 ? false : _c, _d = _a.listItem, listItem = _d === void 0 ? true : _d;
23329
+ var ListItemWrapper = function (_a) {
23330
+ var children = _a.children;
23331
+ return listItem ? React__default["default"].createElement(AccessibleListItem, null, children) : React__default["default"].createElement(React__default["default"].Fragment, null, children);
23332
+ };
23333
+ var ListWrapper = function (_a) {
23334
+ var children = _a.children;
23335
+ return listItem ? React__default["default"].createElement(AccessibleList, null, children) : React__default["default"].createElement(React__default["default"].Fragment, null, children);
23336
+ };
23337
+ return (React__default["default"].createElement(ListWrapper, null,
23338
+ includeSkipToMainContent && (React__default["default"].createElement(ListItemWrapper, null,
23339
+ React__default["default"].createElement(SkipToMainContent, null))),
23340
+ AccessibleLinksArray && AccessibleLinksArray.map(function (link, i) { return (React__default["default"].createElement(ListItemWrapper, { key: 'accessible-link-li-' + i },
23341
+ React__default["default"].createElement(AccessibleLinks, { key: 'accessible-link-' + i, href: link.url }, link.title))); })));
23275
23342
  };
23276
23343
 
23277
23344
  const Container$F = styled__default["default"].div`
@@ -27863,64 +27930,6 @@ var SignpostLinks = function (_a) {
27863
27930
  signpostLinksArray[0].areaName))));
27864
27931
  };
27865
27932
 
27866
- const SkipToMainContent$1 = styled__default["default"].a`
27867
- ${props => props.theme.fontStyles}
27868
-
27869
- position: absolute;
27870
- width: 1px;
27871
- height: 1px;
27872
- margin: 0;
27873
- overflow: hidden;
27874
- clip: rect(0 0 0 0);
27875
- clip-path: inset(50%);
27876
- white-space: nowrap;
27877
- display: block;
27878
- padding: 10px 15px;
27879
-
27880
- &:active,
27881
- &:focus {
27882
- position: static;
27883
- width: auto;
27884
- height: auto;
27885
- margin: inherit;
27886
- overflow: visible;
27887
- clip: auto;
27888
- -webkit-clip-path: none;
27889
- clip-path: none;
27890
- white-space: inherit
27891
- }
27892
-
27893
- &:link,
27894
- &:visited,
27895
- &:hover,
27896
- &:active,
27897
- &:focus {
27898
- color: ${props => props.theme.theme_vars.colours.black};
27899
- }
27900
-
27901
-
27902
-
27903
- @media (min-width: 40.0625em) {
27904
- font-size: 16px;
27905
- font-size: 1rem;
27906
- line-height: 1.25
27907
- }
27908
-
27909
-
27910
-
27911
- &:focus {
27912
- outline: 3px solid ${props => props.theme.theme_vars.colours.focus};
27913
- outline-offset: 0;
27914
- background-color: ${props => props.theme.theme_vars.colours.focus};
27915
- }
27916
-
27917
-
27918
-
27919
-
27920
- `;
27921
-
27922
- var SkipToMainContent = function () { return (React__default["default"].createElement(SkipToMainContent$1, { "data-testid": "SkipToMainContent", href: "#main" }, "Skip to main content")); };
27923
-
27924
27933
  const summaryStyles = (props) => {
27925
27934
  if (props.theme.is_memorial === true) {
27926
27935
  return styled.css`