@axos-web-dev/shared-components 2.0.0-dev.31.insights → 2.0.0-dev.31.insights.2

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.
@@ -74,8 +74,8 @@ import "../Carousel/index.js";
74
74
  /* empty css */
75
75
  import "../Chatbot/store/chat.js";
76
76
  import "../Chatbot/Chatbot.js";
77
- import "../LoadingIndicator/LoadingIndicator.css.js";
78
77
  import "../Chatbot/Chatbot.css.ts.vanilla.css.js";
78
+ import "../LoadingIndicator/LoadingIndicator.css.js";
79
79
  /* empty css */
80
80
  import "../Chatbot/store/messages.js";
81
81
  import { Hyperlink } from "../Hyperlink/index.js";
@@ -54,9 +54,9 @@ import "../Carousel/index.js";
54
54
  /* empty css */
55
55
  import "../Chatbot/store/chat.js";
56
56
  import "../Chatbot/Chatbot.js";
57
+ import "../Chatbot/Chatbot.css.ts.vanilla.css.js";
57
58
  import "../LoadingIndicator/LoadingIndicator.css.js";
58
59
  import "react-use";
59
- import "../Chatbot/Chatbot.css.ts.vanilla.css.js";
60
60
  /* empty css */
61
61
  import "../Chatbot/store/messages.js";
62
62
  /* empty css */
@@ -3,7 +3,6 @@ import '../assets/Chatbot/ChatWindow.css';import '../assets/Typography/Typograph
3
3
  /* empty css */
4
4
  /* empty css */
5
5
  /* empty css */
6
- import "./Chatbot.css.ts.vanilla.css.js";
7
6
  /* empty css */
8
7
  var windowStyle = "_13n1jqk1";
9
8
  var windowExpandedStyle = "_13n1jqk2";
@@ -1,3 +1,4 @@
1
+ import "./Chatbot.css.ts.vanilla.css.js";
1
2
  var chatbotAXB = "_1hpv6vm0";
2
3
  var chatbotUFB = "_1hpv6vm1";
3
4
  export {
@@ -69,9 +69,9 @@ import "../Carousel/index.js";
69
69
  /* empty css */
70
70
  import "../Chatbot/store/chat.js";
71
71
  import "../Chatbot/Chatbot.js";
72
+ import "../Chatbot/Chatbot.css.ts.vanilla.css.js";
72
73
  import "../LoadingIndicator/LoadingIndicator.css.js";
73
74
  import "react-use";
74
- import "../Chatbot/Chatbot.css.ts.vanilla.css.js";
75
75
  /* empty css */
76
76
  import "../Chatbot/store/messages.js";
77
77
  /* empty css */
@@ -103,7 +103,7 @@ import "next/script.js";
103
103
  /* empty css */
104
104
  /* empty css */
105
105
  /* empty css */
106
- import { featured_section, featured_title, featured_grid, featured_maingrid, featured_maingrid_img, ratio, featured_main_wrapper, featured_maingrid_title, featured_maingrid_text, info_details, featured_subgrid, featured_subgrid_item, featured_subgrid_title } from "./Featured.css.js";
106
+ import { featured_section, featured_grid, featured_title, featured_maingrid, featured_maingrid_img, ratio, featured_main_wrapper, featured_maingrid_title, featured_maingrid_text, info_details, featured_subgrid, featured_subgrid_item, featured_subgrid_title } from "./Featured.css.js";
107
107
  import { insight_wrap } from "./Header.css.js";
108
108
  import "../../LandingPageHeader/LandingPageHeader.css.js";
109
109
  import "next/link.js";
@@ -143,23 +143,31 @@ const FeaturedItem = (props) => {
143
143
  image
144
144
  } = props;
145
145
  const variant = getVariant(fullVariant);
146
+ const imageUrl = image?.url ? `https:${image.url}` : void 0;
146
147
  return /* @__PURE__ */ jsx("a", { href: url ?? "/", className: featured_subgrid_item, children: /* @__PURE__ */ jsxs("div", { className: "flex", style: { gap: "16px" }, children: [
147
- /* @__PURE__ */ jsxs("picture", { className: ratio, children: [
148
- /* @__PURE__ */ jsx("source", { srcSet: `https:${image?.url}?fm=avif`, type: "image/avif" }),
149
- /* @__PURE__ */ jsx("source", { srcSet: `https:${image?.url}?fm=webp`, type: "image/webp" }),
150
- /* @__PURE__ */ jsx(
151
- Image,
152
- {
153
- src: `https:${image?.url}`,
154
- className: clsx(featured_maingrid_img, ratio),
155
- height: 159,
156
- width: 269,
157
- priority: true,
158
- alt: ""
159
- }
160
- )
161
- ] }),
162
- /* @__PURE__ */ jsxs("div", { className: "flex gap_24", children: [
148
+ imageUrl ? /* @__PURE__ */ jsxs(
149
+ "picture",
150
+ {
151
+ className: clsx(ratio, "rounded"),
152
+ style: { borderRadius: "12px" },
153
+ children: [
154
+ /* @__PURE__ */ jsx("source", { srcSet: `${imageUrl}?fm=avif`, type: "image/avif" }),
155
+ /* @__PURE__ */ jsx("source", { srcSet: `${imageUrl}?fm=webp`, type: "image/webp" }),
156
+ /* @__PURE__ */ jsx(
157
+ Image,
158
+ {
159
+ src: imageUrl,
160
+ className: clsx(featured_maingrid_img, ratio),
161
+ height: 159,
162
+ width: 269,
163
+ priority: true,
164
+ alt: image?.alt ?? ""
165
+ }
166
+ )
167
+ ]
168
+ }
169
+ ) : null,
170
+ /* @__PURE__ */ jsxs("div", { className: "flex_col gap_24", children: [
163
171
  /* @__PURE__ */ jsx("h3", { className: clsx(featured_subgrid_title, title({ variant })), children: featureItemTitle ?? "" }),
164
172
  /* @__PURE__ */ jsxs("div", { className: "flex middle", style: { gap: "4px" }, children: [
165
173
  /* @__PURE__ */ jsx(ClockIcon, {}),
@@ -184,37 +192,38 @@ const Featured = (props) => {
184
192
  const { id, variant: fullVariant, featured, headline } = props;
185
193
  const variant = getVariant(fullVariant);
186
194
  const [main, ...restFeatured] = featured;
187
- return /* @__PURE__ */ jsx("section", { id, className: featured_section, children: /* @__PURE__ */ jsxs("div", { className: insight_wrap, children: [
188
- headline && /* @__PURE__ */ jsx("h2", { className: featured_title, children: headline }),
189
- /* @__PURE__ */ jsxs("div", { className: featured_grid, children: [
195
+ const mainImageUrl = main?.image?.url ? `https:${main.image.url}` : void 0;
196
+ return /* @__PURE__ */ jsx("section", { id, className: featured_section, children: /* @__PURE__ */ jsx("div", { className: insight_wrap, children: /* @__PURE__ */ jsxs("div", { className: featured_grid, children: [
197
+ /* @__PURE__ */ jsxs("div", { children: [
198
+ headline && /* @__PURE__ */ jsx("h2", { className: featured_title, children: headline }),
190
199
  /* @__PURE__ */ jsxs("a", { href: main?.url, className: featured_maingrid, children: [
191
- /* @__PURE__ */ jsxs("picture", { className: clsx(ratio, "rounded"), children: [
200
+ mainImageUrl ? /* @__PURE__ */ jsxs("picture", { className: clsx(ratio, "rounded"), children: [
192
201
  /* @__PURE__ */ jsx(
193
202
  "source",
194
203
  {
195
- srcSet: `https:${main?.image?.url}?fm=avif`,
204
+ srcSet: `${mainImageUrl}?fm=avif`,
196
205
  type: "image/avif"
197
206
  }
198
207
  ),
199
208
  /* @__PURE__ */ jsx(
200
209
  "source",
201
210
  {
202
- srcSet: `https:${main?.image?.url}?fm=webp`,
211
+ srcSet: `${mainImageUrl}?fm=webp`,
203
212
  type: "image/webp"
204
213
  }
205
214
  ),
206
215
  /* @__PURE__ */ jsx(
207
216
  Image,
208
217
  {
209
- src: `https:${main?.image?.url}`,
218
+ src: mainImageUrl,
210
219
  className: clsx(featured_maingrid_img, ratio),
211
220
  height: 346,
212
221
  width: 586,
213
222
  priority: true,
214
- alt: ""
223
+ alt: main?.image?.alt ?? ""
215
224
  }
216
225
  )
217
- ] }),
226
+ ] }) : null,
218
227
  /* @__PURE__ */ jsxs("div", { className: featured_main_wrapper, children: [
219
228
  /* @__PURE__ */ jsx("h3", { className: featured_maingrid_title, children: main?.title ?? "" }),
220
229
  /* @__PURE__ */ jsx("p", { className: featured_maingrid_text, children: main?.text ?? "" }),
@@ -235,23 +244,24 @@ const Featured = (props) => {
235
244
  /* @__PURE__ */ jsx("span", { className: info_details, style: { fontWeight: "600" }, children: (typeof main?.supertag == "string" && main?.supertag.replaceAll("-", " ")) ?? "" })
236
245
  ] })
237
246
  ] })
238
- ] }),
239
- /* @__PURE__ */ jsxs("div", { children: [
240
- /* @__PURE__ */ jsx("h2", { className: featured_title, children: "Popular topics" }),
241
- /* @__PURE__ */ jsx("div", { className: featured_subgrid, children: restFeatured.map((item) => /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(
242
- FeaturedItem,
243
- {
244
- variant: variant ?? "secondary",
245
- readingTime: item.readingTime,
246
- supertag: item.supertag,
247
- title: item.title,
248
- url: item.url
249
- },
250
- item.id
251
- ) }, item.id)) })
252
247
  ] })
248
+ ] }),
249
+ /* @__PURE__ */ jsxs("div", { children: [
250
+ /* @__PURE__ */ jsx("h2", { className: featured_title, children: "Popular topics" }),
251
+ /* @__PURE__ */ jsx("div", { className: featured_subgrid, children: restFeatured.map((item) => /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(
252
+ FeaturedItem,
253
+ {
254
+ variant: variant ?? "secondary",
255
+ image: item.image,
256
+ readingTime: item.readingTime,
257
+ supertag: item.supertag,
258
+ title: item.title,
259
+ url: item.url
260
+ },
261
+ item.id
262
+ ) }, item.id)) })
253
263
  ] })
254
- ] }) });
264
+ ] }) }) });
255
265
  };
256
266
  export {
257
267
  Featured,
@@ -101,7 +101,7 @@ import "next/script.js";
101
101
  /* empty css */
102
102
  /* empty css */
103
103
  /* empty css */
104
- import { header_title_featured, header_in_insight, insight_wrap, header_featured } from "./Header.css.js";
104
+ import { insight_wrap, header_title_featured, header_in_insight, header_featured } from "./Header.css.js";
105
105
  import "../../LandingPageHeader/LandingPageHeader.css.js";
106
106
  import "next/link.js";
107
107
  /* empty css */
@@ -132,26 +132,19 @@ import "../../StepItemSet/StepItemSet.css.js";
132
132
  /* empty css */
133
133
  const BreadcumbHeader = (props) => {
134
134
  const { section, showTitle = true } = props;
135
- return /* @__PURE__ */ jsx(
136
- "div",
135
+ return /* @__PURE__ */ jsx("div", { className: clsx(!showTitle ? header_in_insight : "", header_featured), children: /* @__PURE__ */ jsx("div", { className: insight_wrap, children: showTitle && /* @__PURE__ */ jsxs(
136
+ "h1",
137
137
  {
138
138
  className: clsx(
139
- !showTitle ? header_in_insight : "",
140
- insight_wrap,
141
- header_featured
139
+ title({ variant: "primary" }),
140
+ header_title_featured
142
141
  ),
143
- children: showTitle && /* @__PURE__ */ jsxs(
144
- "h1",
145
- {
146
- className: clsx(title({ variant: "primary" }), header_title_featured),
147
- children: [
148
- section?.replaceAll("-", " "),
149
- " Insights"
150
- ]
151
- }
152
- )
142
+ children: [
143
+ section?.replaceAll("-", " "),
144
+ " Insights"
145
+ ]
153
146
  }
154
- );
147
+ ) }) });
155
148
  };
156
149
  export {
157
150
  BreadcumbHeader
@@ -48,6 +48,12 @@
48
48
  font-size: 16px;
49
49
  line-height: 1.5;
50
50
  margin-bottom: 0;
51
+ display: -webkit-box;
52
+ -webkit-box-orient: vertical;
53
+ line-clamp: 2;
54
+ -webkit-line-clamp: 2;
55
+ overflow: hidden;
56
+ text-overflow: ellipsis;
51
57
  }
52
58
  ._1sr2o6v9 {
53
59
  color: var(--_1073cm8f);
@@ -65,8 +71,6 @@
65
71
  text-decoration: none;
66
72
  }
67
73
  ._1sr2o6vc {
68
- margin-bottom: 8px;
69
- max-height: min(76px, 108px);
70
74
  display: -webkit-box;
71
75
  -webkit-box-orient: vertical;
72
76
  line-clamp: 2;
@@ -74,6 +78,7 @@
74
78
  overflow: hidden;
75
79
  text-overflow: ellipsis;
76
80
  width: 100%;
81
+ font-size: 20px !important;
77
82
  }
78
83
  ._1sr2o6vd {
79
84
  display: inline-block;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@axos-web-dev/shared-components",
3
3
  "description": "Axos shared components library for web.",
4
- "version": "2.0.0-dev.31.insights",
4
+ "version": "2.0.0-dev.31.insights.2",
5
5
  "type": "module",
6
6
  "main": "index.js",
7
7
  "module": "dist/main.js",