@redneckz/wildless-cms-uni-blocks 0.2.42 → 0.2.45

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.
Files changed (257) hide show
  1. package/dist/BenefitsBlock.d.ts +2 -10
  2. package/dist/BenefitsBlock.js +3 -25
  3. package/dist/BenefitsBlock.js.map +1 -1
  4. package/dist/Blocks.d.ts +1 -0
  5. package/dist/Blocks.js +2 -0
  6. package/dist/Blocks.js.map +1 -1
  7. package/dist/ContentPage.d.ts +3 -6
  8. package/dist/ContentPage.js +1 -1
  9. package/dist/ContentPage.js.map +1 -1
  10. package/dist/ContentPageContext.d.ts +5 -0
  11. package/dist/Footer/Contacts.d.ts +6 -0
  12. package/dist/Footer/Contacts.js +31 -0
  13. package/dist/Footer/Contacts.js.map +1 -0
  14. package/dist/Footer/Footer.d.ts +12 -0
  15. package/dist/Footer/Footer.js +17 -0
  16. package/dist/Footer/Footer.js.map +1 -0
  17. package/dist/Footer/FooterLink.d.ts +5 -0
  18. package/dist/{ui-kit/Link.js → Footer/FooterLink.js} +1 -1
  19. package/dist/Footer/FooterLink.js.map +1 -0
  20. package/dist/Footer/HorizontalNavigation.d.ts +2 -0
  21. package/dist/Footer/HorizontalNavigation.js +12 -0
  22. package/dist/Footer/HorizontalNavigation.js.map +1 -0
  23. package/dist/Footer/Sitemap.d.ts +5 -0
  24. package/dist/Footer/Sitemap.js +19 -0
  25. package/dist/Footer/Sitemap.js.map +1 -0
  26. package/dist/Footer/SocialMedia.d.ts +5 -0
  27. package/dist/Footer/SocialMedia.js +21 -0
  28. package/dist/Footer/SocialMedia.js.map +1 -0
  29. package/dist/Footer/TextInformation.d.ts +2 -0
  30. package/dist/Footer/TextInformation.js +12 -0
  31. package/dist/Footer/TextInformation.js.map +1 -0
  32. package/dist/Footer/index.d.ts +2 -0
  33. package/dist/Footer/index.js +5 -0
  34. package/dist/Footer/index.js.map +1 -0
  35. package/dist/Header/Header.d.ts +2 -4
  36. package/dist/Header/Header.js +3 -3
  37. package/dist/Header/Header.js.map +1 -1
  38. package/dist/Header/HeaderContent.d.ts +1 -5
  39. package/dist/Header/HeaderSecondaryMenu.js +1 -1
  40. package/dist/Header/HeaderSecondaryMenu.js.map +1 -1
  41. package/dist/Header/HeaderSecondaryMenuButton.d.ts +1 -0
  42. package/dist/Header/HeaderSecondaryMenuButton.js +1 -1
  43. package/dist/Header/HeaderSecondaryMenuButton.js.map +1 -1
  44. package/dist/Header/isSubItemActive.d.ts +1 -1
  45. package/dist/Header/isTopItemActive.d.ts +1 -1
  46. package/dist/Icons/ActualBalanceIcon.d.ts +1 -1
  47. package/dist/Icons/CalendarIcon.d.ts +1 -1
  48. package/dist/Icons/ClockIcon.d.ts +1 -1
  49. package/dist/Icons/ComfortableCompIcon.d.ts +1 -1
  50. package/dist/Icons/EmptyWalletIcon.d.ts +1 -1
  51. package/dist/Icons/GridIcon.d.ts +1 -1
  52. package/dist/Icons/LoupeIcon.d.ts +1 -1
  53. package/dist/Icons/NewDocIcon.d.ts +1 -1
  54. package/dist/Icons/OkIcon.d.ts +1 -0
  55. package/dist/Icons/OkIcon.js +6 -0
  56. package/dist/Icons/OkIcon.js.map +1 -0
  57. package/dist/Icons/PassSendIcon.d.ts +1 -1
  58. package/dist/Icons/PercentageSquareIcon.d.ts +1 -1
  59. package/dist/Icons/ProfileIcon.d.ts +1 -1
  60. package/dist/Icons/SignDocsIcon.d.ts +1 -1
  61. package/dist/Icons/TelegramIcon.d.ts +1 -0
  62. package/dist/Icons/TelegramIcon.js +6 -0
  63. package/dist/Icons/TelegramIcon.js.map +1 -0
  64. package/dist/Icons/VKIcon.d.ts +1 -0
  65. package/dist/Icons/VKIcon.js +6 -0
  66. package/dist/Icons/VKIcon.js.map +1 -0
  67. package/dist/Icons/index.d.ts +4 -1
  68. package/dist/Icons/index.js +7 -1
  69. package/dist/Icons/index.js.map +1 -1
  70. package/dist/LikeControl.d.ts +2 -6
  71. package/dist/LikeControl.js +1 -1
  72. package/dist/LikeControl.js.map +1 -1
  73. package/dist/ProductBlock.d.ts +3 -11
  74. package/dist/ProductBlock.js.map +1 -1
  75. package/dist/ProductBlockInner.d.ts +2 -10
  76. package/dist/ProductBlockInner.js +6 -28
  77. package/dist/ProductBlockInner.js.map +1 -1
  78. package/dist/ProductGallery.d.ts +3 -5
  79. package/dist/ProductGallery.js +1 -1
  80. package/dist/ProductGallery.js.map +1 -1
  81. package/dist/StepsBlock.d.ts +9 -6
  82. package/dist/StepsBlock.js +3 -25
  83. package/dist/StepsBlock.js.map +1 -1
  84. package/dist/Tile.d.ts +2 -5
  85. package/dist/Tile.js.map +1 -1
  86. package/dist/{Header/mergeTopItems.d.ts → mergeTopItems.d.ts} +1 -1
  87. package/dist/{Header/mergeTopItems.js → mergeTopItems.js} +0 -0
  88. package/dist/mergeTopItems.js.map +1 -0
  89. package/dist/types.d.ts +27 -3
  90. package/dist/ui-kit/Breadcrumb.d.ts +1 -1
  91. package/dist/ui-kit/Breadcrumb.js +1 -1
  92. package/dist/ui-kit/Breadcrumb.js.map +1 -1
  93. package/dist/ui-kit/Button.d.ts +2 -1
  94. package/dist/ui-kit/Button.js +3 -3
  95. package/dist/ui-kit/Button.js.map +1 -1
  96. package/dist/ui-kit/LikeButton.d.ts +1 -0
  97. package/dist/ui-kit/LikeButton.js +1 -1
  98. package/dist/ui-kit/LikeButton.js.map +1 -1
  99. package/dist/ui-kit/Logo.d.ts +4 -3
  100. package/dist/ui-kit/Logo.js +2 -2
  101. package/dist/ui-kit/Logo.js.map +1 -1
  102. package/dist/ui-kit/SearchBar.d.ts +2 -0
  103. package/dist/ui-kit/SearchBar.js +13 -0
  104. package/dist/ui-kit/SearchBar.js.map +1 -0
  105. package/dist/ui-kit/TopItem.d.ts +2 -1
  106. package/dist/ui-kit/TopItem.js +2 -2
  107. package/dist/ui-kit/TopItem.js.map +1 -1
  108. package/dist/useLink.d.ts +2 -1
  109. package/dist/useLink.js +2 -1
  110. package/dist/useLink.js.map +1 -1
  111. package/dist/utils/url.d.ts +4 -4
  112. package/fonts/ubuntu/ubuntu.css +67 -0
  113. package/fonts/ubuntu/ubuntu.eot +0 -0
  114. package/fonts/ubuntu/ubuntu.ttf +0 -0
  115. package/fonts/ubuntu/ubuntu.woff +0 -0
  116. package/fonts/ubuntu/ubuntu.woff2 +0 -0
  117. package/fonts/ubuntu/ubuntubold.ttf +0 -0
  118. package/fonts/ubuntu/ubuntubold.woff +0 -0
  119. package/fonts/ubuntu/ubuntubold.woff2 +0 -0
  120. package/fonts/ubuntu/ubuntubolditalic.ttf +0 -0
  121. package/fonts/ubuntu/ubuntubolditalic.woff +0 -0
  122. package/fonts/ubuntu/ubuntubolditalic.woff2 +0 -0
  123. package/fonts/ubuntu/ubuntuitalic.ttf +0 -0
  124. package/fonts/ubuntu/ubuntuitalic.woff +0 -0
  125. package/fonts/ubuntu/ubuntuitalic.woff2 +0 -0
  126. package/fonts/ubuntu/ubuntulight.ttf +0 -0
  127. package/fonts/ubuntu/ubuntulight.woff +0 -0
  128. package/fonts/ubuntu/ubuntulight.woff2 +0 -0
  129. package/fonts/ubuntu/ubuntulightitalic.ttf +0 -0
  130. package/fonts/ubuntu/ubuntulightitalic.woff +0 -0
  131. package/fonts/ubuntu/ubuntulightitalic.woff2 +0 -0
  132. package/fonts/ubuntu/ubuntumedium.ttf +0 -0
  133. package/fonts/ubuntu/ubuntumedium.woff +0 -0
  134. package/fonts/ubuntu/ubuntumedium.woff2 +0 -0
  135. package/fonts/ubuntu/ubuntumediumitalic.ttf +0 -0
  136. package/fonts/ubuntu/ubuntumediumitalic.woff +0 -0
  137. package/fonts/ubuntu/ubuntumediumitalic.woff2 +0 -0
  138. package/lib/BenefitsBlock.d.ts +2 -10
  139. package/lib/BenefitsBlock.js +3 -2
  140. package/lib/BenefitsBlock.js.map +1 -1
  141. package/lib/Blocks.d.ts +1 -0
  142. package/lib/Blocks.js +2 -0
  143. package/lib/Blocks.js.map +1 -1
  144. package/lib/ContentPage.d.ts +3 -6
  145. package/lib/ContentPage.js +1 -1
  146. package/lib/ContentPage.js.map +1 -1
  147. package/lib/ContentPageContext.d.ts +5 -0
  148. package/lib/Footer/Contacts.d.ts +6 -0
  149. package/lib/Footer/Contacts.js +29 -0
  150. package/lib/Footer/Contacts.js.map +1 -0
  151. package/lib/Footer/Footer.d.ts +12 -0
  152. package/lib/Footer/Footer.js +15 -0
  153. package/lib/Footer/Footer.js.map +1 -0
  154. package/lib/Footer/FooterLink.d.ts +5 -0
  155. package/lib/Footer/FooterLink.js +2 -0
  156. package/lib/Footer/FooterLink.js.map +1 -0
  157. package/lib/Footer/HorizontalNavigation.d.ts +2 -0
  158. package/lib/Footer/HorizontalNavigation.js +10 -0
  159. package/lib/Footer/HorizontalNavigation.js.map +1 -0
  160. package/lib/Footer/Sitemap.d.ts +5 -0
  161. package/lib/Footer/Sitemap.js +17 -0
  162. package/lib/Footer/Sitemap.js.map +1 -0
  163. package/lib/Footer/SocialMedia.d.ts +5 -0
  164. package/lib/Footer/SocialMedia.js +19 -0
  165. package/lib/Footer/SocialMedia.js.map +1 -0
  166. package/lib/Footer/TextInformation.d.ts +2 -0
  167. package/lib/Footer/TextInformation.js +10 -0
  168. package/lib/Footer/TextInformation.js.map +1 -0
  169. package/lib/Footer/index.d.ts +2 -0
  170. package/lib/Footer/index.js +2 -0
  171. package/lib/Footer/index.js.map +1 -0
  172. package/lib/Header/Header.d.ts +2 -4
  173. package/lib/Header/Header.js +3 -3
  174. package/lib/Header/Header.js.map +1 -1
  175. package/lib/Header/HeaderContent.d.ts +1 -5
  176. package/lib/Header/HeaderSecondaryMenu.js +1 -1
  177. package/lib/Header/HeaderSecondaryMenu.js.map +1 -1
  178. package/lib/Header/HeaderSecondaryMenuButton.d.ts +1 -0
  179. package/lib/Header/HeaderSecondaryMenuButton.js +1 -1
  180. package/lib/Header/HeaderSecondaryMenuButton.js.map +1 -1
  181. package/lib/Header/isSubItemActive.d.ts +1 -1
  182. package/lib/Header/isTopItemActive.d.ts +1 -1
  183. package/lib/Icons/ActualBalanceIcon.d.ts +1 -1
  184. package/lib/Icons/CalendarIcon.d.ts +1 -1
  185. package/lib/Icons/ClockIcon.d.ts +1 -1
  186. package/lib/Icons/ComfortableCompIcon.d.ts +1 -1
  187. package/lib/Icons/EmptyWalletIcon.d.ts +1 -1
  188. package/lib/Icons/GridIcon.d.ts +1 -1
  189. package/lib/Icons/LoupeIcon.d.ts +1 -1
  190. package/lib/Icons/NewDocIcon.d.ts +1 -1
  191. package/lib/Icons/OkIcon.d.ts +1 -0
  192. package/lib/Icons/OkIcon.js +3 -0
  193. package/lib/Icons/OkIcon.js.map +1 -0
  194. package/lib/Icons/PassSendIcon.d.ts +1 -1
  195. package/lib/Icons/PercentageSquareIcon.d.ts +1 -1
  196. package/lib/Icons/ProfileIcon.d.ts +1 -1
  197. package/lib/Icons/SignDocsIcon.d.ts +1 -1
  198. package/lib/Icons/TelegramIcon.d.ts +1 -0
  199. package/lib/Icons/TelegramIcon.js +3 -0
  200. package/lib/Icons/TelegramIcon.js.map +1 -0
  201. package/lib/Icons/VKIcon.d.ts +1 -0
  202. package/lib/Icons/VKIcon.js +3 -0
  203. package/lib/Icons/VKIcon.js.map +1 -0
  204. package/lib/Icons/index.d.ts +4 -1
  205. package/lib/Icons/index.js +4 -1
  206. package/lib/Icons/index.js.map +1 -1
  207. package/lib/LikeControl.d.ts +2 -6
  208. package/lib/LikeControl.js +1 -1
  209. package/lib/LikeControl.js.map +1 -1
  210. package/lib/ProductBlock.d.ts +3 -11
  211. package/lib/ProductBlock.js.map +1 -1
  212. package/lib/ProductBlockInner.d.ts +2 -10
  213. package/lib/ProductBlockInner.js +6 -5
  214. package/lib/ProductBlockInner.js.map +1 -1
  215. package/lib/ProductGallery.d.ts +3 -5
  216. package/lib/ProductGallery.js +1 -1
  217. package/lib/ProductGallery.js.map +1 -1
  218. package/lib/StepsBlock.d.ts +9 -6
  219. package/lib/StepsBlock.js +3 -2
  220. package/lib/StepsBlock.js.map +1 -1
  221. package/lib/Tile.d.ts +2 -5
  222. package/lib/Tile.js.map +1 -1
  223. package/lib/common.css +1 -1
  224. package/lib/{Header/mergeTopItems.d.ts → mergeTopItems.d.ts} +1 -1
  225. package/lib/{Header/mergeTopItems.js → mergeTopItems.js} +0 -0
  226. package/lib/mergeTopItems.js.map +1 -0
  227. package/lib/types.d.ts +27 -3
  228. package/lib/ui-kit/Breadcrumb.d.ts +1 -1
  229. package/lib/ui-kit/Breadcrumb.js +1 -1
  230. package/lib/ui-kit/Breadcrumb.js.map +1 -1
  231. package/lib/ui-kit/Button.d.ts +2 -1
  232. package/lib/ui-kit/Button.js +3 -3
  233. package/lib/ui-kit/Button.js.map +1 -1
  234. package/lib/ui-kit/LikeButton.d.ts +1 -0
  235. package/lib/ui-kit/LikeButton.js +1 -1
  236. package/lib/ui-kit/LikeButton.js.map +1 -1
  237. package/lib/ui-kit/Logo.d.ts +4 -3
  238. package/lib/ui-kit/Logo.js +2 -2
  239. package/lib/ui-kit/Logo.js.map +1 -1
  240. package/lib/ui-kit/SearchBar.d.ts +2 -0
  241. package/lib/ui-kit/SearchBar.js +11 -0
  242. package/lib/ui-kit/SearchBar.js.map +1 -0
  243. package/lib/ui-kit/TopItem.d.ts +2 -1
  244. package/lib/ui-kit/TopItem.js +2 -2
  245. package/lib/ui-kit/TopItem.js.map +1 -1
  246. package/lib/useLink.d.ts +2 -1
  247. package/lib/useLink.js +2 -1
  248. package/lib/useLink.js.map +1 -1
  249. package/lib/utils/url.d.ts +4 -4
  250. package/package.json +44 -19
  251. package/dist/Header/mergeTopItems.js.map +0 -1
  252. package/dist/ui-kit/Link.d.ts +0 -5
  253. package/dist/ui-kit/Link.js.map +0 -1
  254. package/lib/Header/mergeTopItems.js.map +0 -1
  255. package/lib/ui-kit/Link.d.ts +0 -5
  256. package/lib/ui-kit/Link.js +0 -2
  257. package/lib/ui-kit/Link.js.map +0 -1
package/lib/types.d.ts CHANGED
@@ -1,11 +1,12 @@
1
1
  import type { AvifOptions, FormatEnum, GifOptions, HeifOptions, JpegOptions, PngOptions, ResizeOptions, TiffOptions, WebpOptions } from 'sharp';
2
+ import type { BenefitsBlockContent } from './BenefitsBlock';
3
+ import type { ContentPageContext } from './ContentPageContext';
2
4
  import type { HeaderContent } from './Header/index';
3
5
  import type { PlaceholderContent } from './Placeholder';
4
- import type { TileContent } from './Tile';
5
6
  import type { ProductBlockInnerContent } from './ProductBlockInner';
6
- import type { StepsBlockContent } from './StepsBlock';
7
- import type { BenefitsBlockContent } from './BenefitsBlock';
8
7
  import type { ProductGalleryContent } from './ProductGallery';
8
+ import type { StepsBlockContent } from './StepsBlock';
9
+ import type { TileContent } from './Tile';
9
10
  export declare type BlockVersion = 'primary' | 'secondary';
10
11
  export declare type ColorPalette = 'pc' | 'bc' | 'eo';
11
12
  export declare type BlockContent = HeaderContent | PlaceholderContent | ProductBlockInnerContent | TileContent | StepsBlockContent | BenefitsBlockContent | ProductGalleryContent;
@@ -44,3 +45,26 @@ export interface ImgSource {
44
45
  export interface Picture extends Img, ImgSource {
45
46
  sources?: ImgSource[];
46
47
  }
48
+ export interface UniBlocksComponentProps {
49
+ className?: string;
50
+ context: ContentPageContext;
51
+ }
52
+ export interface ContactInfo {
53
+ text: string;
54
+ type: 'tel' | 'email';
55
+ description: string;
56
+ }
57
+ export interface LinkContent {
58
+ text?: string;
59
+ href?: string;
60
+ target?: '_blank' | '_self' | '_parent' | '_top' | string;
61
+ }
62
+ export declare type NavMenuItem = LinkContent;
63
+ export interface TopMenuItem extends NavMenuItem {
64
+ items?: NavMenuItem[];
65
+ }
66
+ export interface Benefit {
67
+ label: string;
68
+ description?: string;
69
+ icon?: string;
70
+ }
@@ -1,4 +1,4 @@
1
- import type { LinkContent } from './Link';
1
+ import type { LinkContent } from '../types';
2
2
  export interface BreadcrumbProps extends LinkContent {
3
3
  className?: string;
4
4
  onClick?: (ev: MouseEvent) => any;
@@ -5,7 +5,7 @@ export const Breadcrumb = JSX(({ text, href, target, onClick, className, childre
5
5
  return (_jsx("a", { className: `no-underline ${className || ''}`, href: href, target: target, onClick: onClick, children: _jsx("span", { className: `${className || ''}`, children: text || children }) }));
6
6
  }
7
7
  else {
8
- return (_jsx("span", { className: `${className || ''}`, children: text || children }));
8
+ return _jsx("span", { className: `${className || ''}`, children: text || children });
9
9
  }
10
10
  });
11
11
  //# sourceMappingURL=Breadcrumb.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Breadcrumb.js","sourceRoot":"","sources":["../../src/ui-kit/Breadcrumb.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAQxC,MAAM,CAAC,MAAM,UAAU,GAAG,GAAG,CAAkB,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,EAAE,EAAE;IACtG,IAAI,IAAI,EAAE;QACR,OAAO,CACL,YACE,SAAS,EAAE,gBAAgB,SAAS,IAAI,EAAE,EAAE,EAC5C,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,OAAO,YAEhB,eAAM,SAAS,EAAE,GAAG,SAAS,IAAI,EAAE,EAAE,YAAG,IAAI,IAAI,QAAQ,GAAQ,GAC9D,CACL,CAAC;KACH;SAAM;QACL,OAAO,CACL,eAAM,SAAS,EAAE,GAAG,SAAS,IAAI,EAAE,EAAE,YAClC,IAAI,IAAI,QAAQ,GACZ,CACR,CAAC;KACH;AACH,CAAC,CAAC,CAAC"}
1
+ {"version":3,"file":"Breadcrumb.js","sourceRoot":"","sources":["../../src/ui-kit/Breadcrumb.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAQxC,MAAM,CAAC,MAAM,UAAU,GAAG,GAAG,CAC3B,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,EAAE,EAAE;IACvD,IAAI,IAAI,EAAE;QACR,OAAO,CACL,YACE,SAAS,EAAE,gBAAgB,SAAS,IAAI,EAAE,EAAE,EAC5C,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,OAAO,YAEhB,eAAM,SAAS,EAAE,GAAG,SAAS,IAAI,EAAE,EAAE,YAAG,IAAI,IAAI,QAAQ,GAAQ,GAC9D,CACL,CAAC;KACH;SAAM;QACL,OAAO,eAAM,SAAS,EAAE,GAAG,SAAS,IAAI,EAAE,EAAE,YAAG,IAAI,IAAI,QAAQ,GAAQ,CAAC;KACzE;AACH,CAAC,CACF,CAAC"}
@@ -1,9 +1,10 @@
1
- import type { LinkContent } from './Link';
1
+ import type { LinkContent } from '../types';
2
2
  declare type ButtonVersion = 'primary' | 'secondary';
3
3
  export interface ButtonProps extends LinkContent {
4
4
  className?: string;
5
5
  onClick?: (ev: MouseEvent) => any;
6
6
  version?: ButtonVersion;
7
+ ariaLabel?: string;
7
8
  disabled?: Boolean;
8
9
  }
9
10
  export declare const Button: (props: import("@redneckz/uni-jsx").PropsWithChildren<ButtonProps, any>, context?: any) => any;
@@ -9,10 +9,10 @@ const buttonDisabledStyleMap = {
9
9
  secondary: 'bg-secondary-light text-secondary-text',
10
10
  };
11
11
  const styleButton = 'inline-block rounded-3xl px-9 py-3.5 text-center font-sans';
12
- export const Button = JSX(({ className, text, href, target, onClick, children, disabled, version = 'primary' }) => {
12
+ export const Button = JSX(({ className, text, href, target, onClick, children, disabled, version = 'primary', ariaLabel, }) => {
13
13
  if (disabled) {
14
- return (_jsx("div", { role: "button", "area-disabled": "true", className: `${styleButton} select-none ${buttonDisabledStyleMap[version]} ${className || ''}`, children: _jsx("span", { className: "text-sm font-medium", children: text || children }) }));
14
+ return (_jsx("div", { role: "button", "aria-disabled": "true", "aria-label": ariaLabel, tabindex: "-1", className: `${styleButton} select-none ${buttonDisabledStyleMap[version]} ${className || ''}`, children: _jsx("span", { className: "text-sm font-medium", children: text || children }) }));
15
15
  }
16
- return (_jsx("a", { className: `${styleButton} no-underline ${buttonStyleMap[version]} ${className || ''}`, href: href, target: target, onClick: onClick, children: _jsx("span", { className: "text-sm font-medium", children: text || children }) }));
16
+ return (_jsx("a", { className: `${styleButton} no-underline ${buttonStyleMap[version]} ${className || ''}`, href: href, target: target, onClick: onClick, "aria-label": ariaLabel, children: _jsx("span", { className: "text-sm font-medium", children: text || children }) }));
17
17
  });
18
18
  //# sourceMappingURL=Button.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Button.js","sourceRoot":"","sources":["../../src/ui-kit/Button.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAWxC,MAAM,cAAc,GAAkC;IACpD,OAAO,EAAE,4EAA4E;IACrF,SAAS,EACP,0FAA0F;CAC7F,CAAC;AAEF,MAAM,sBAAsB,GAAkC;IAC5D,OAAO,EAAE,uCAAuC;IAChD,SAAS,EAAE,wCAAwC;CACpD,CAAC;AAEF,MAAM,WAAW,GAAG,4DAA4D,CAAC;AAEjF,MAAM,CAAC,MAAM,MAAM,GAAG,GAAG,CACvB,CAAC,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,OAAO,GAAG,SAAS,EAAE,EAAE,EAAE;IACtF,IAAI,QAAQ,EAAE;QACZ,OAAO,CACL,cACE,IAAI,EAAC,QAAQ,mBACC,MAAM,EACpB,SAAS,EAAE,GAAG,WAAW,gBAAgB,sBAAsB,CAAC,OAAO,CAAC,IACtE,SAAS,IAAI,EACf,EAAE,YAEF,eAAM,SAAS,EAAC,qBAAqB,YAAE,IAAI,IAAI,QAAQ,GAAQ,GAC3D,CACP,CAAC;KACH;IAED,OAAO,CACL,YACE,SAAS,EAAE,GAAG,WAAW,iBAAiB,cAAc,CAAC,OAAO,CAAC,IAAI,SAAS,IAAI,EAAE,EAAE,EACtF,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,OAAO,YAEhB,eAAM,SAAS,EAAC,qBAAqB,YAAE,IAAI,IAAI,QAAQ,GAAQ,GAC7D,CACL,CAAC;AACJ,CAAC,CACF,CAAC"}
1
+ {"version":3,"file":"Button.js","sourceRoot":"","sources":["../../src/ui-kit/Button.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAYxC,MAAM,cAAc,GAAkC;IACpD,OAAO,EAAE,4EAA4E;IACrF,SAAS,EACP,0FAA0F;CAC7F,CAAC;AAEF,MAAM,sBAAsB,GAAkC;IAC5D,OAAO,EAAE,uCAAuC;IAChD,SAAS,EAAE,wCAAwC;CACpD,CAAC;AAEF,MAAM,WAAW,GAAG,4DAA4D,CAAC;AAEjF,MAAM,CAAC,MAAM,MAAM,GAAG,GAAG,CACvB,CAAC,EACC,SAAS,EACT,IAAI,EACJ,IAAI,EACJ,MAAM,EACN,OAAO,EACP,QAAQ,EACR,QAAQ,EACR,OAAO,GAAG,SAAS,EACnB,SAAS,GACV,EAAE,EAAE;IACH,IAAI,QAAQ,EAAE;QACZ,OAAO,CACL,cACE,IAAI,EAAC,QAAQ,mBACC,MAAM,gBACR,SAAS,EACrB,QAAQ,EAAC,IAAI,EACb,SAAS,EAAE,GAAG,WAAW,gBAAgB,sBAAsB,CAAC,OAAO,CAAC,IACtE,SAAS,IAAI,EACf,EAAE,YAEF,eAAM,SAAS,EAAC,qBAAqB,YAAE,IAAI,IAAI,QAAQ,GAAQ,GAC3D,CACP,CAAC;KACH;IAED,OAAO,CACL,YACE,SAAS,EAAE,GAAG,WAAW,iBAAiB,cAAc,CAAC,OAAO,CAAC,IAAI,SAAS,IAAI,EAAE,EAAE,EACtF,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,OAAO,gBACJ,SAAS,YAErB,eAAM,SAAS,EAAC,qBAAqB,YAAE,IAAI,IAAI,QAAQ,GAAQ,GAC7D,CACL,CAAC;AACJ,CAAC,CACF,CAAC"}
@@ -1,5 +1,6 @@
1
1
  export interface LikeButtonProps {
2
2
  className?: string;
3
3
  onClick?: (ev: MouseEvent) => any;
4
+ ariaLabel?: string;
4
5
  }
5
6
  export declare const LikeButton: (props: import("@redneckz/uni-jsx").PropsWithChildren<LikeButtonProps, any>, context?: any) => any;
@@ -1,6 +1,6 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "@redneckz/uni-jsx/jsx-runtime";
2
2
  import { JSX } from '@redneckz/uni-jsx';
3
- export const LikeButton = JSX(({ className, onClick }) => (_jsx("button", { type: "button", className: `border-0 w-[36px] bg-inherit cursor-pointer ${className || ''}`, onClick: onClick, children: renderLikeIcon() })));
3
+ export const LikeButton = JSX(({ className, onClick, ariaLabel }) => (_jsx("button", { type: "button", className: `border-0 w-[36px] bg-inherit cursor-pointer ${className || ''}`, onClick: onClick, "aria-label": ariaLabel, children: renderLikeIcon() })));
4
4
  const renderLikeIcon = () => {
5
5
  const params = {
6
6
  stroke: '#292D32',
@@ -1 +1 @@
1
- {"version":3,"file":"LikeButton.js","sourceRoot":"","sources":["../../src/ui-kit/LikeButton.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAOxC,MAAM,CAAC,MAAM,UAAU,GAAG,GAAG,CAAkB,CAAC,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CACzE,iBACE,IAAI,EAAC,QAAQ,EACb,SAAS,EAAE,+CAA+C,SAAS,IAAI,EAAE,EAAE,EAC3E,OAAO,EAAE,OAAO,YAEf,cAAc,EAAE,GACV,CACV,CAAC,CAAC;AAEH,MAAM,cAAc,GAAG,GAAG,EAAE;IAC1B,MAAM,MAAM,GAAG;QACb,MAAM,EAAE,SAAS;QACjB,aAAa,EAAE,OAAO;QACtB,cAAc,EAAE,OAAO;QACvB,WAAW,EAAE,KAAK;KACnB,CAAC;IAEF,OAAO,CACL,eAAK,KAAK,EAAC,4BAA4B,EAAC,IAAI,EAAC,MAAM,EAAC,OAAO,EAAC,WAAW,aACrE,kBACM,MAAM,EACV,gBAAgB,EAAC,IAAI,EACrB,CAAC,EAAC,wLAAwL,GAC1L,EACF,kBACM,MAAM,EACV,CAAC,EAAC,oGAAoG,GACtG,IACE,CACP,CAAC;AACJ,CAAC,CAAC"}
1
+ {"version":3,"file":"LikeButton.js","sourceRoot":"","sources":["../../src/ui-kit/LikeButton.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAQxC,MAAM,CAAC,MAAM,UAAU,GAAG,GAAG,CAAkB,CAAC,EAAE,SAAS,EAAE,OAAO,EAAE,SAAS,EAAE,EAAE,EAAE,CAAC,CACpF,iBACE,IAAI,EAAC,QAAQ,EACb,SAAS,EAAE,+CAA+C,SAAS,IAAI,EAAE,EAAE,EAC3E,OAAO,EAAE,OAAO,gBACJ,SAAS,YAEpB,cAAc,EAAE,GACV,CACV,CAAC,CAAC;AAEH,MAAM,cAAc,GAAG,GAAG,EAAE;IAC1B,MAAM,MAAM,GAAG;QACb,MAAM,EAAE,SAAS;QACjB,aAAa,EAAE,OAAO;QACtB,cAAc,EAAE,OAAO;QACvB,WAAW,EAAE,KAAK;KACnB,CAAC;IAEF,OAAO,CACL,eAAK,KAAK,EAAC,4BAA4B,EAAC,IAAI,EAAC,MAAM,EAAC,OAAO,EAAC,WAAW,aACrE,kBACM,MAAM,EACV,gBAAgB,EAAC,IAAI,EACrB,CAAC,EAAC,wLAAwL,GAC1L,EACF,kBACM,MAAM,EACV,CAAC,EAAC,oGAAoG,GACtG,IACE,CACP,CAAC;AACJ,CAAC,CAAC"}
@@ -1,5 +1,6 @@
1
1
  export interface LogoProps {
2
- className?: string;
3
- href?: string;
2
+ className: string;
3
+ href: string;
4
+ targetBlank: boolean;
4
5
  }
5
- export declare const Logo: (props: import("@redneckz/uni-jsx").PropsWithChildren<LogoProps, any>, context?: any) => any;
6
+ export declare const Logo: (props: import("@redneckz/uni-jsx").PropsWithChildren<Partial<LogoProps>, any>, context?: any) => any;
@@ -8,7 +8,7 @@ const LOGO_PATHS = [
8
8
  'M14.7 27.83h2.58c.67 0 1.14.14 1.4.4.27.25.4.72.4 1.38v7.4c0 .66-.12 1.12-.4 1.38-.4.41-1.16.41-1.78.41l-.4-.01v3.5l.78.14v-2.88c1.2 0 1.97-.4 2.34-1.22v4.29h.26l.5-.01V29.74c0-.68.13-1.16.4-1.43.25-.27.72-.4 1.37-.4.67 0 1.65-.1 2.16.4.26.27.38.76.38 1.43v3.8h-1.77v-4.06h-.77v12.99c.26-.03.5-.07.77-.12V34.3h1.77v7.64c.36-.1.72-.21 1.08-.34v-7c0-.8.19-1.4 1-1.67l-.9-4.87h1.8l.3 5.31h.22l.3-5.31h1.88l-1.01 4.87c.84.3 1.01.81 1.01 1.66v4.53a16.63 16.63 0 0 0 1.5-1.27v-9.83h5.25l.1-.72H24.93l.17.89c-.38-.72-1.12-1.08-2.2-1.08h-.77c-1.3 0-2.1.52-2.4 1.55-.27-1.08-1.1-1.62-2.46-1.62h-3.36v14.52c.26.09.52.18.78.25V27.84Zm16.29 5.58-.85-.8.85-4.37v5.17Z',
9
9
  'M27.66 40.79c.27-.14.55-.28.8-.43v-5.98h-.8v6.4Z',
10
10
  ];
11
- export const Logo = JSX(({ className, href, children }) => {
12
- return (_jsxs("a", { className: `inline-flex items-center font-sans no-underline ${className || ''}`, href: href || 'https://rshb.ru/', target: "_blank", children: [_jsx(SVG, { className: "text-primary-main w-10", viewBox: "0 0 40 45", paths: LOGO_PATHS.map((d) => ({ d })) }), _jsx("span", { className: "text-black text-base font-medium ml-2.5", children: children || 'Россельхозбанк' })] }));
11
+ export const Logo = JSX(({ className, href, children, targetBlank }) => {
12
+ return (_jsxs("a", { className: `inline-flex items-center font-sans no-underline ${className || ''}`, href: href || 'https://rshb.ru/', target: targetBlank ? '_blank' : '_self', children: [_jsx(SVG, { className: "text-primary-main w-10", viewBox: "0 0 40 45", paths: LOGO_PATHS.map((d) => ({ d })) }), _jsx("span", { className: "text-black text-base font-medium ml-2.5", children: children || 'Россельхозбанк' })] }));
13
13
  });
14
14
  //# sourceMappingURL=Logo.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Logo.js","sourceRoot":"","sources":["../../src/ui-kit/Logo.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAO5B,MAAM,UAAU,GAAG;IACjB,w5CAAw5C;IACx5C,2OAA2O;IAC3O,0JAA0J;IAC1J,gpBAAgpB;IAChpB,kDAAkD;CACnD,CAAC;AAEF,MAAM,CAAC,MAAM,IAAI,GAAG,GAAG,CAAY,CAAC,EAAE,SAAS,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE;IACnE,OAAO,CACL,aACE,SAAS,EAAE,mDAAmD,SAAS,IAAI,EAAE,EAAE,EAC/E,IAAI,EAAE,IAAI,IAAI,kBAAkB,EAChC,MAAM,EAAC,QAAQ,aAEf,KAAC,GAAG,IACF,SAAS,EAAC,wBAAwB,EAClC,OAAO,EAAC,WAAW,EACnB,KAAK,EAAE,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,GACrC,EACF,eAAM,SAAS,EAAC,yCAAyC,YACtD,QAAQ,IAAI,gBAAgB,GACxB,IACL,CACL,CAAC;AACJ,CAAC,CAAC,CAAC"}
1
+ {"version":3,"file":"Logo.js","sourceRoot":"","sources":["../../src/ui-kit/Logo.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAQ5B,MAAM,UAAU,GAAG;IACjB,w5CAAw5C;IACx5C,2OAA2O;IAC3O,0JAA0J;IAC1J,gpBAAgpB;IAChpB,kDAAkD;CACnD,CAAC;AAEF,MAAM,CAAC,MAAM,IAAI,GAAG,GAAG,CAAqB,CAAC,EAAE,SAAS,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,EAAE,EAAE;IACzF,OAAO,CACL,aACE,SAAS,EAAE,mDAAmD,SAAS,IAAI,EAAE,EAAE,EAC/E,IAAI,EAAE,IAAI,IAAI,kBAAkB,EAChC,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,OAAO,aAExC,KAAC,GAAG,IACF,SAAS,EAAC,wBAAwB,EAClC,OAAO,EAAC,WAAW,EACnB,KAAK,EAAE,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,GACrC,EACF,eAAM,SAAS,EAAC,yCAAyC,YACtD,QAAQ,IAAI,gBAAgB,GACxB,IACL,CACL,CAAC;AACJ,CAAC,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ import type { UniBlocksComponentProps } from '../types';
2
+ export declare const SearchBar: (props: import("@redneckz/uni-jsx").PropsWithChildren<UniBlocksComponentProps, any>, context?: any) => any;
@@ -0,0 +1,11 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "@redneckz/uni-jsx/jsx-runtime";
2
+ import { JSX } from '@redneckz/uni-jsx';
3
+ import { LoupeIcon } from '../Icons/index.js';
4
+ export const SearchBar = JSX(({ className, context }) => {
5
+ const search = context.useSearch();
6
+ return (_jsxs("form", { className: `relative ${className || ''}`, children: [_jsxs("div", { className: "absolute rounded-l-full h-full flex items-center justify-center pl-4 max-w-[170px] gap-3.5", children: [_jsx("div", { className: "w-[24px] h-[24px]", children: LoupeIcon() }), _jsx("span", { className: "font-sans font-normal text-sm text-secondary-text", children: "\u041F\u043E\u0438\u0441\u043A \u043F\u043E \u0441\u0430\u0439\u0442\u0443" })] }), _jsx("input", { className: "pl-[170px] w-full font-sans font-normal text-sm border border-solid border-main-divider rounded-full h-full box-border outline-none", value: search.term, onChange: (e) => search.setTerm(e.target.value), type: "text", placeholder: "\u041F\u043E\u0438\u0441\u043A \u043F\u043E \u0441\u0430\u0439\u0442\u0443", name: "s" }), _jsx("button", { type: "submit", className: "absolute font-sans font-normal text-sm cursor-pointer bg-transparent hover:bg-primary-hover active:bg-primary-active text-primary-main hover:text-white border-none px-5 rounded-r-full h-full top-0 right-0 outline-none", onClick: (e) => {
7
+ e.preventDefault();
8
+ console.log('click');
9
+ }, children: "\u041D\u0430\u0439\u0442\u0438" })] }));
10
+ });
11
+ //# sourceMappingURL=SearchBar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SearchBar.js","sourceRoot":"","sources":["../../src/ui-kit/SearchBar.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAExC,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAE3C,MAAM,CAAC,MAAM,SAAS,GAAG,GAAG,CAA0B,CAAC,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE,EAAE;IAC/E,MAAM,MAAM,GAAG,OAAO,CAAC,SAAS,EAAE,CAAC;IACnC,OAAO,CACL,gBAAM,SAAS,EAAE,YAAY,SAAS,IAAI,EAAE,EAAE,aAC5C,eAAK,SAAS,EAAC,4FAA4F,aACzG,cAAK,SAAS,EAAC,mBAAmB,YAAE,SAAS,EAAE,GAAO,EACtD,eAAM,SAAS,EAAC,mDAAmD,2FAAsB,IACrF,EACN,gBACE,SAAS,EAAC,qIAAqI,EAC/I,KAAK,EAAE,MAAM,CAAC,IAAI,EAClB,QAAQ,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAC/C,IAAI,EAAC,MAAM,EACX,WAAW,EAAC,4EAAgB,EAC5B,IAAI,EAAC,GAAG,GACR,EACF,iBACE,IAAI,EAAC,QAAQ,EACb,SAAS,EAAC,2NAA2N,EACrO,OAAO,EAAE,CAAC,CAAC,EAAE,EAAE;oBACb,CAAC,CAAC,cAAc,EAAE,CAAC;oBACnB,OAAO,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;gBACvB,CAAC,+CAGM,IACJ,CACR,CAAC;AACJ,CAAC,CAAC,CAAC"}
@@ -1,10 +1,11 @@
1
- import type { LinkContent } from './Link';
1
+ import type { LinkContent } from '../types';
2
2
  export interface TopItemContent extends LinkContent {
3
3
  active?: boolean;
4
4
  }
5
5
  export interface TopItemProps extends TopItemContent {
6
6
  className?: string;
7
7
  flat?: boolean;
8
+ ariaLabel?: string;
8
9
  onClick?: (ev: MouseEvent) => any;
9
10
  }
10
11
  export declare const TopItem: (props: import("@redneckz/uni-jsx").PropsWithChildren<TopItemProps, any>, context?: any) => any;
@@ -1,10 +1,10 @@
1
1
  import { jsx as _jsx } from "@redneckz/uni-jsx/jsx-runtime";
2
2
  import { JSX } from '@redneckz/uni-jsx';
3
- export const TopItem = JSX(({ className, text, href, target, active, flat, onClick, children }) => {
3
+ export const TopItem = JSX(({ className, text, href, target, active, flat, onClick, children, ariaLabel }) => {
4
4
  const linkStyle = active ? 'border-primary-main rounded-3xl' : 'border-transparent';
5
5
  const textStyle = active
6
6
  ? 'text-primary-main'
7
7
  : `${flat ? 'text-primary-text' : 'text-secondary-text'} hover:text-primary-main`;
8
- return (_jsx("a", { className: `inline-block border border-solid bg-transparent text-center no-underline ${flat ? '' : 'px-4 py-2'} ${linkStyle} ${className || ''}`, href: href, target: target, onClick: onClick, children: _jsx("span", { className: `font-sans font-normal text-sm ${textStyle}`, children: text || children }) }));
8
+ return (_jsx("a", { className: `inline-block border border-solid bg-transparent text-center no-underline ${flat ? '' : 'px-4 py-2'} ${linkStyle} ${className || ''}`, href: href, target: target, onClick: onClick, rel: "noopener noreferrer", "aria-label": ariaLabel, children: _jsx("span", { className: `font-sans font-normal text-sm ${textStyle}`, children: text || children }) }));
9
9
  });
10
10
  //# sourceMappingURL=TopItem.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"TopItem.js","sourceRoot":"","sources":["../../src/ui-kit/TopItem.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAaxC,MAAM,CAAC,MAAM,OAAO,GAAG,GAAG,CACxB,CAAC,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE;IACrE,MAAM,SAAS,GAAG,MAAM,CAAC,CAAC,CAAC,iCAAiC,CAAC,CAAC,CAAC,oBAAoB,CAAC;IACpF,MAAM,SAAS,GAAG,MAAM;QACtB,CAAC,CAAC,mBAAmB;QACrB,CAAC,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC,mBAAmB,CAAC,CAAC,CAAC,qBAAqB,0BAA0B,CAAC;IACpF,OAAO,CACL,YACE,SAAS,EAAE,4EACT,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,WACd,IAAI,SAAS,IAAI,SAAS,IAAI,EAAE,EAAE,EAClC,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,OAAO,YAEhB,eAAM,SAAS,EAAE,iCAAiC,SAAS,EAAE,YAAG,IAAI,IAAI,QAAQ,GAAQ,GACtF,CACL,CAAC;AACJ,CAAC,CACF,CAAC"}
1
+ {"version":3,"file":"TopItem.js","sourceRoot":"","sources":["../../src/ui-kit/TopItem.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAcxC,MAAM,CAAC,MAAM,OAAO,GAAG,GAAG,CACxB,CAAC,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,EAAE,EAAE;IAChF,MAAM,SAAS,GAAG,MAAM,CAAC,CAAC,CAAC,iCAAiC,CAAC,CAAC,CAAC,oBAAoB,CAAC;IACpF,MAAM,SAAS,GAAG,MAAM;QACtB,CAAC,CAAC,mBAAmB;QACrB,CAAC,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC,mBAAmB,CAAC,CAAC,CAAC,qBAAqB,0BAA0B,CAAC;IAEpF,OAAO,CACL,YACE,SAAS,EAAE,4EACT,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,WACd,IAAI,SAAS,IAAI,SAAS,IAAI,EAAE,EAAE,EAClC,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,OAAO,EAChB,GAAG,EAAC,qBAAqB,gBACb,SAAS,YAErB,eAAM,SAAS,EAAE,iCAAiC,SAAS,EAAE,YAAG,IAAI,IAAI,QAAQ,GAAQ,GACtF,CACL,CAAC;AACJ,CAAC,CACF,CAAC"}
package/lib/useLink.d.ts CHANGED
@@ -1,10 +1,11 @@
1
1
  import { HandlerDecorator, Router } from './ContentPageContext';
2
- import type { LinkContent } from './ui-kit/Link';
2
+ import type { LinkContent } from './types';
3
3
  export declare function useLink({ router, handlerDecorator, }: {
4
4
  router: Router;
5
5
  handlerDecorator?: HandlerDecorator;
6
6
  }, link: Partial<LinkContent>): {
7
7
  href: string | undefined;
8
+ ariaLabel: string | undefined;
8
9
  onClick: (ev: MouseEvent) => void;
9
10
  text?: string | undefined;
10
11
  target?: string | undefined;
package/lib/useLink.js CHANGED
@@ -1,10 +1,11 @@
1
1
  import { isURL, toRelativeHref } from './utils/url.js';
2
- const defaultHandlerDecorator = (_) => _;
2
+ const defaultHandlerDecorator = (handler, targetContent) => handler;
3
3
  export function useLink({ router, handlerDecorator = defaultHandlerDecorator, }, link) {
4
4
  const href = toRelativeHref(link.href, router.href);
5
5
  return {
6
6
  ...link,
7
7
  href,
8
+ ariaLabel: link.text,
8
9
  onClick: handlerDecorator((ev) => {
9
10
  const isLocalHref = href && !isURL(href);
10
11
  const isLocalTarget = !link.target || link.target === '_self';
@@ -1 +1 @@
1
- {"version":3,"file":"useLink.js","sourceRoot":"","sources":["../src/useLink.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAEpD,MAAM,uBAAuB,GAAqB,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC;AAE3D,MAAM,UAAU,OAAO,CACrB,EACE,MAAM,EACN,gBAAgB,GAAG,uBAAuB,GACc,EAC1D,IAA0B;IAE1B,MAAM,IAAI,GAAG,cAAc,CAAC,IAAI,CAAC,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,CAAC;IACpD,OAAO;QACL,GAAG,IAAI;QACP,IAAI;QACJ,OAAO,EAAE,gBAAgB,CAAC,CAAC,EAAc,EAAE,EAAE;YAC3C,MAAM,WAAW,GAAG,IAAI,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;YACzC,MAAM,aAAa,GAAG,CAAC,IAAI,CAAC,MAAM,IAAI,IAAI,CAAC,MAAM,KAAK,OAAO,CAAC;YAC9D,IAAI,WAAW,IAAI,aAAa,EAAE;gBAChC,EAAE,CAAC,cAAc,EAAE,CAAC;gBACpB,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACnB;QACH,CAAC,EAAE,IAAI,CAAC;KACT,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"useLink.js","sourceRoot":"","sources":["../src/useLink.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAEpD,MAAM,uBAAuB,GAAqB,CAAC,OAAO,EAAE,aAAa,EAAE,EAAE,CAAC,OAAO,CAAC;AAEtF,MAAM,UAAU,OAAO,CACrB,EACE,MAAM,EACN,gBAAgB,GAAG,uBAAuB,GACc,EAC1D,IAA0B;IAE1B,MAAM,IAAI,GAAG,cAAc,CAAC,IAAI,CAAC,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,CAAC;IACpD,OAAO;QACL,GAAG,IAAI;QACP,IAAI;QACJ,SAAS,EAAE,IAAI,CAAC,IAAI;QACpB,OAAO,EAAE,gBAAgB,CAAC,CAAC,EAAc,EAAE,EAAE;YAC3C,MAAM,WAAW,GAAG,IAAI,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;YACzC,MAAM,aAAa,GAAG,CAAC,IAAI,CAAC,MAAM,IAAI,IAAI,CAAC,MAAM,KAAK,OAAO,CAAC;YAC9D,IAAI,WAAW,IAAI,aAAa,EAAE;gBAChC,EAAE,CAAC,cAAc,EAAE,CAAC;gBACpB,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACnB;QACH,CAAC,EAAE,IAAI,CAAC;KACT,CAAC;AACJ,CAAC"}
@@ -1,4 +1,4 @@
1
- export declare const isURL: (href?: string | undefined) => boolean | undefined;
2
- export declare const withoutQuery: (href?: string | undefined) => string;
3
- export declare const getOrigin: (href?: string | undefined) => string | undefined;
4
- export declare const toRelativeHref: (href?: string | undefined, baseURL?: string | undefined) => string | undefined;
1
+ export declare const isURL: (href?: string) => boolean | undefined;
2
+ export declare const withoutQuery: (href?: string) => string;
3
+ export declare const getOrigin: (href?: string) => string | undefined;
4
+ export declare const toRelativeHref: (href?: string, baseURL?: string) => string | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@redneckz/wildless-cms-uni-blocks",
3
- "version": "0.2.42",
3
+ "version": "0.2.45",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -26,7 +26,18 @@
26
26
  "require": "./dist/Header/*.js",
27
27
  "types": "./lib/Header/*.d.ts"
28
28
  },
29
+ "./lib/Footer": {
30
+ "import": "./lib/Footer/index.js",
31
+ "require": "./dist/Footer/index.js",
32
+ "types": "./lib/Footer/index.d.ts"
33
+ },
34
+ "./lib/Footer/*.js": {
35
+ "import": "./lib/Footer/*.js",
36
+ "require": "./dist/Footer/*.js",
37
+ "types": "./lib/Footer/*.d.ts"
38
+ },
29
39
  "./lib/common.css": "./lib/common.css",
40
+ "./fonts/ubuntu/*": "./fonts/ubuntu/*",
30
41
  "./lib/content-page-repository": {
31
42
  "import": "./lib/content-page-repository/index.js",
32
43
  "require": "./dist/content-page-repository/index.js",
@@ -48,7 +59,8 @@
48
59
  },
49
60
  "files": [
50
61
  "lib",
51
- "dist"
62
+ "dist",
63
+ "fonts"
52
64
  ],
53
65
  "author": {
54
66
  "name": "redneckz",
@@ -62,9 +74,11 @@
62
74
  },
63
75
  "scripts": {
64
76
  "build": "rimraf ./lib && tsc --build --verbose && npm run build:commonjs && npm run build:style",
65
- "postbuild": "replace-in-file --configFile=replace-config.cjs --verbose",
66
77
  "build:commonjs": "rimraf ./dist && tsc --module commonjs --noImplicitUseStrict --outDir dist",
67
78
  "build:style": "postcss './src/**/*.css' --env production --dir ./lib",
79
+ "postbuild:style": "npm run size",
80
+ "postbuild": "replace-in-file --configFile=replace-config.cjs --verbose",
81
+ "size": "size-limit",
68
82
  "test": "jest --coverage",
69
83
  "cosmos": "cosmos",
70
84
  "cosmos:export": "cosmos-export",
@@ -84,38 +98,49 @@
84
98
  },
85
99
  "dependencies": {
86
100
  "@redneckz/uni-jsx": "^0.1.6",
87
- "glob": "^8.0.1",
101
+ "glob": "^8.0.3",
88
102
  "remark-html": "^15.0.1",
89
103
  "remark-parse": "^10.0.1",
90
- "sharp": "^0.30.4",
104
+ "sharp": "^0.30.6",
91
105
  "unified": "^10.1.2"
92
106
  },
93
107
  "devDependencies": {
94
- "@types/jest": "^27.4.1",
95
- "autoprefixer": "^10.4.4",
108
+ "@size-limit/file": "^7.0.8",
109
+ "@types/jest": "^28.1.1",
110
+ "autoprefixer": "^10.4.7",
96
111
  "css-loader": "^6.7.1",
97
- "cssnano": "^5.1.7",
112
+ "cssnano": "^5.1.11",
98
113
  "html-webpack-plugin": "^5.5.0",
99
114
  "husky": "^8.0.1",
100
- "jest": "^27.5.1",
101
- "lint-staged": "^12.4.2",
102
- "postcss": "^8.4.12",
115
+ "jest": "^28.1.1",
116
+ "lint-staged": "^13.0.1",
117
+ "postcss": "^8.4.14",
103
118
  "postcss-cli": "^9.1.0",
104
- "postcss-loader": "^6.2.1",
119
+ "postcss-loader": "^7.0.0",
105
120
  "prettier": "2.6.2",
106
121
  "react-cosmos": "^5.7.2",
107
- "replace-in-file": "^6.3.2",
122
+ "replace-in-file": "^6.3.5",
108
123
  "rimraf": "^3.0.2",
124
+ "size-limit": "^7.0.8",
109
125
  "style-loader": "^3.3.1",
110
- "tailwindcss": "^3.0.24",
111
- "ts-jest": "^27.1.4",
112
- "ts-loader": "^9.2.8",
113
- "typescript": "^4.6.3",
114
- "webpack": "^5.72.0",
126
+ "tailwindcss": "^3.1.1",
127
+ "ts-jest": "^28.0.4",
128
+ "ts-loader": "^9.3.0",
129
+ "typescript": "^4.7.3",
130
+ "webpack": "^5.73.0",
115
131
  "webpack-cli": "^4.9.2"
116
132
  },
133
+ "size-limit": [
134
+ {
135
+ "limit": "7 kB",
136
+ "path": "lib/common.css"
137
+ }
138
+ ],
117
139
  "lint-staged": {
118
140
  "src/**/*.{js,jsx,ts,tsx,css}": "prettier --write",
119
- "src/**/*.{js,jsx,ts,tsx,css,json}": ["cosmos-export", "git add ./docs"]
141
+ "src/**/*.{js,jsx,ts,tsx,css,json}": [
142
+ "cosmos-export",
143
+ "git add ./docs"
144
+ ]
120
145
  }
121
146
  }
@@ -1 +0,0 @@
1
- {"version":3,"file":"mergeTopItems.js","sourceRoot":"","sources":["../../src/Header/mergeTopItems.ts"],"names":[],"mappings":";;AAEA,MAAM,GAAG,GAAG,CAAC,CAAe,EAAE,EAAE,CAAC,CAAC,CAAe,EAAE,EAAE,CAAC,CAAC,EAAE,IAAI,KAAK,CAAC,EAAE,IAAI,CAAC;AAE1E,MAAM,UAAU,GAAG,CAAC,KAAqB,EAAE,YAA4B,EAAE,EAAE,CACzE,CAAC,KAAK,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,YAAY,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;AAE5D,MAAM,QAAQ,GAAG,CAAC,OAAuB,EAAE,UAA0B,EAAE,EAAE,CACvE,CAAC,OAAO,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,UAAU,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AAE3D,SAAgB,aAAa,CAAC,IAAoB,EAAE,KAAqB;IACvE,OAAO,UAAU,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC,CAAC;AAC/D,CAAC;AAFD,sCAEC"}
@@ -1,5 +0,0 @@
1
- export interface LinkContent {
2
- text?: string;
3
- href?: string;
4
- target?: '_blank' | '_self' | '_parent' | '_top' | string;
5
- }
@@ -1 +0,0 @@
1
- {"version":3,"file":"Link.js","sourceRoot":"","sources":["../../src/ui-kit/Link.ts"],"names":[],"mappings":""}
@@ -1 +0,0 @@
1
- {"version":3,"file":"mergeTopItems.js","sourceRoot":"","sources":["../../src/Header/mergeTopItems.ts"],"names":[],"mappings":"AAEA,MAAM,GAAG,GAAG,CAAC,CAAe,EAAE,EAAE,CAAC,CAAC,CAAe,EAAE,EAAE,CAAC,CAAC,EAAE,IAAI,KAAK,CAAC,EAAE,IAAI,CAAC;AAE1E,MAAM,UAAU,GAAG,CAAC,KAAqB,EAAE,YAA4B,EAAE,EAAE,CACzE,CAAC,KAAK,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,YAAY,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;AAE5D,MAAM,QAAQ,GAAG,CAAC,OAAuB,EAAE,UAA0B,EAAE,EAAE,CACvE,CAAC,OAAO,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,UAAU,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AAE3D,MAAM,UAAU,aAAa,CAAC,IAAoB,EAAE,KAAqB;IACvE,OAAO,UAAU,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC,CAAC;AAC/D,CAAC"}
@@ -1,5 +0,0 @@
1
- export interface LinkContent {
2
- text?: string;
3
- href?: string;
4
- target?: '_blank' | '_self' | '_parent' | '_top' | string;
5
- }
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=Link.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Link.js","sourceRoot":"","sources":["../../src/ui-kit/Link.ts"],"names":[],"mappings":""}