slack-blocks-to-jsx 0.3.6 → 0.3.7

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/dist/index.js CHANGED
@@ -1976,7 +1976,8 @@ var missing_emojis = {
1976
1976
  wavy_dash: "&#x3030-FE0F;",
1977
1977
  part_alternation_mark: "&#x303D-FE0F;",
1978
1978
  congratulations: "&#x3297-FE0F;",
1979
- secret: "&#x3299-FE0F;"
1979
+ secret: "&#x3299-FE0F;",
1980
+ thumbsup: "👍"
1980
1981
  };
1981
1982
 
1982
1983
  // src/utils/emojis/parser.ts
@@ -2118,25 +2119,38 @@ var date_token_to_label = (inputDate, formatString) => {
2118
2119
  }
2119
2120
  };
2120
2121
 
2121
- // src/utils/markdown_parser/sub_elements/slack_broadcast.tsx
2122
+ // src/utils/markdown_parser/sub_elements/slack_emoji.tsx
2122
2123
  var import_jsx_runtime2 = require("react/jsx-runtime");
2124
+ var SlackEmoji = (props) => {
2125
+ const { element } = props;
2126
+ const { hooks } = useGlobalData();
2127
+ if (hooks.emoji) {
2128
+ const custom_emoji = hooks.emoji(element.value);
2129
+ if (custom_emoji !== "fallback")
2130
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_jsx_runtime2.Fragment, { children: custom_emoji });
2131
+ }
2132
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "slack_emoji", children: parseEmojis(`:${element.value}:`) });
2133
+ };
2134
+
2135
+ // src/utils/markdown_parser/sub_elements/slack_broadcast.tsx
2136
+ var import_jsx_runtime3 = require("react/jsx-runtime");
2123
2137
  var SlackBroadcast = (props) => {
2124
2138
  const { element } = props;
2125
2139
  const { hooks } = useGlobalData();
2126
2140
  if (element.value === "here" && hooks.atHere)
2127
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_jsx_runtime2.Fragment, { children: hooks.atHere() });
2141
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_jsx_runtime3.Fragment, { children: hooks.atHere() });
2128
2142
  if (element.value === "everyone" && hooks.atEveryone)
2129
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_jsx_runtime2.Fragment, { children: hooks.atEveryone() });
2143
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_jsx_runtime3.Fragment, { children: hooks.atEveryone() });
2130
2144
  if (element.value === "channel" && hooks.atChannel)
2131
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_jsx_runtime2.Fragment, { children: hooks.atChannel() });
2132
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("span", { className: "slack_broadcast", children: [
2145
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_jsx_runtime3.Fragment, { children: hooks.atChannel() });
2146
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("span", { className: "slack_broadcast", children: [
2133
2147
  "@",
2134
2148
  element.value
2135
2149
  ] });
2136
2150
  };
2137
2151
 
2138
2152
  // src/utils/markdown_parser/sub_elements/slack_channel_mention.tsx
2139
- var import_jsx_runtime3 = require("react/jsx-runtime");
2153
+ var import_jsx_runtime4 = require("react/jsx-runtime");
2140
2154
  var SlackChannelMention = (props) => {
2141
2155
  const { element } = props;
2142
2156
  const { hooks, channels } = useGlobalData();
@@ -2144,15 +2158,15 @@ var SlackChannelMention = (props) => {
2144
2158
  const channel = channels.find((u) => u.id === channel_id || u.name === channel_id);
2145
2159
  const label = (channel == null ? void 0 : channel.name) || channel_id;
2146
2160
  if (hooks.channel)
2147
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_jsx_runtime3.Fragment, { children: hooks.channel(channel || { id: channel_id, name: label }) });
2148
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("span", { className: "slack_channel", "data-channel-id": (channel == null ? void 0 : channel.id) || channel_id, children: [
2161
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_jsx_runtime4.Fragment, { children: hooks.channel(channel || { id: channel_id, name: label }) });
2162
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("span", { className: "slack_channel", "data-channel-id": (channel == null ? void 0 : channel.id) || channel_id, children: [
2149
2163
  "#",
2150
2164
  label
2151
2165
  ] });
2152
2166
  };
2153
2167
 
2154
2168
  // src/utils/markdown_parser/sub_elements/slack_user_group_mention.tsx
2155
- var import_jsx_runtime4 = require("react/jsx-runtime");
2169
+ var import_jsx_runtime5 = require("react/jsx-runtime");
2156
2170
  var SlackUserGroupMention = (props) => {
2157
2171
  const { element } = props;
2158
2172
  const { hooks, user_groups } = useGlobalData();
@@ -2160,173 +2174,183 @@ var SlackUserGroupMention = (props) => {
2160
2174
  const group = user_groups.find((u) => u.id === group_id || u.name === group_id);
2161
2175
  const label = (group == null ? void 0 : group.name) || group_id;
2162
2176
  if (hooks.usergroup)
2163
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_jsx_runtime4.Fragment, { children: hooks.usergroup(group || { id: group_id, name: label }) });
2164
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("span", { "data-usergroup-id": (group == null ? void 0 : group.id) || group_id, className: "slack_user_group", children: [
2177
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_jsx_runtime5.Fragment, { children: hooks.usergroup(group || { id: group_id, name: label }) });
2178
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { "data-usergroup-id": (group == null ? void 0 : group.id) || group_id, className: "slack_user_group", children: [
2165
2179
  "@",
2166
2180
  label
2167
2181
  ] });
2168
2182
  };
2169
2183
 
2170
2184
  // src/utils/markdown_parser/sub_elements/slack_user_mention.tsx
2171
- var import_jsx_runtime5 = require("react/jsx-runtime");
2185
+ var import_jsx_runtime6 = require("react/jsx-runtime");
2172
2186
  var SlackUserMention = (props) => {
2173
2187
  const { element } = props;
2174
2188
  const { hooks, users } = useGlobalData();
2175
2189
  const user_id = element.value;
2176
2190
  const user = users.find((u) => u.id === user_id || u.name === user_id);
2177
2191
  if (hooks.user)
2178
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_jsx_runtime5.Fragment, { children: hooks.user(user || { id: user_id, name: user_id }) });
2192
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_jsx_runtime6.Fragment, { children: hooks.user(user || { id: user_id, name: user_id }) });
2179
2193
  const label = (user == null ? void 0 : user.name) || user_id;
2180
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("span", { className: "slack_user", "data-user-id": (user == null ? void 0 : user.id) || user_id, children: [
2194
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { className: "slack_user", "data-user-id": (user == null ? void 0 : user.id) || user_id, children: [
2181
2195
  "@",
2182
2196
  label
2183
2197
  ] });
2184
2198
  };
2185
2199
 
2186
2200
  // src/utils/markdown_parser/sub_elements/text.tsx
2187
- var import_jsx_runtime6 = require("react/jsx-runtime");
2201
+ var import_jsx_runtime7 = require("react/jsx-runtime");
2188
2202
  var Text = (props) => {
2189
2203
  const { element } = props;
2190
2204
  if (!element.value)
2191
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { children: element.value });
2205
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { children: element.value });
2192
2206
  if (element.value === " ")
2193
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { children: "\xA0" });
2194
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { children: element.value.split("[[DOUBLE_LINE_BREAK]]").map((line, index) => {
2195
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("span", { children: [
2196
- index > 0 && /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { className: "slack_blocks_to_jsx__line_break_not_first" }),
2207
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { children: "\xA0" });
2208
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { children: element.value.split("[[DOUBLE_LINE_BREAK]]").map((line, index) => {
2209
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("span", { children: [
2210
+ index > 0 && /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { className: "slack_blocks_to_jsx__line_break_not_first" }),
2197
2211
  line
2198
2212
  ] }, index);
2199
2213
  }) });
2200
2214
  };
2201
2215
 
2202
2216
  // src/utils/markdown_parser/sub_elements/strong.tsx
2203
- var import_jsx_runtime7 = require("react/jsx-runtime");
2217
+ var import_jsx_runtime8 = require("react/jsx-runtime");
2204
2218
  var Strong = (props) => {
2205
2219
  const { element } = props;
2206
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("strong", { children: element.children.map((child, i) => {
2220
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("strong", { children: element.children.map((child, i) => {
2207
2221
  if (child.type === "delete")
2208
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Delete, { element: child }, i);
2222
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Delete, { element: child }, i);
2209
2223
  if (child.type === "slack_user_mention")
2210
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(SlackUserMention, { element: child }, i);
2224
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(SlackUserMention, { element: child }, i);
2211
2225
  if (child.type === "slack_channel_mention")
2212
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(SlackChannelMention, { element: child }, i);
2226
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(SlackChannelMention, { element: child }, i);
2213
2227
  if (child.type === "slack_user_group_mention")
2214
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(SlackUserGroupMention, { element: child }, i);
2228
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(SlackUserGroupMention, { element: child }, i);
2215
2229
  if (child.type === "slack_broadcast")
2216
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(SlackBroadcast, { element: child }, i);
2230
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(SlackBroadcast, { element: child }, i);
2217
2231
  if (child.type === "slack_date")
2218
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(SlackDate, { element: child }, i);
2232
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(SlackDate, { element: child }, i);
2219
2233
  if (child.type === "emphasis")
2220
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Emphasis, { element: child }, i);
2221
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Text, { element: child }, i);
2234
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Emphasis, { element: child }, i);
2235
+ if (child.type === "slack_emoji")
2236
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(SlackEmoji, { element: child }, i);
2237
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Text, { element: child }, i);
2222
2238
  }) });
2223
2239
  };
2224
2240
 
2225
2241
  // src/utils/markdown_parser/sub_elements/delete.tsx
2226
- var import_jsx_runtime8 = require("react/jsx-runtime");
2242
+ var import_jsx_runtime9 = require("react/jsx-runtime");
2227
2243
  var Delete = (props) => {
2228
2244
  const { element } = props;
2229
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("s", { children: element.children.map((child, i) => {
2245
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("s", { children: element.children.map((child, i) => {
2230
2246
  if (child.type === "slack_date")
2231
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(SlackDate, { element: child }, i);
2247
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(SlackDate, { element: child }, i);
2232
2248
  if (child.type === "strong")
2233
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Strong, { element: child }, i);
2249
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Strong, { element: child }, i);
2234
2250
  if (child.type === "emphasis")
2235
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Emphasis, { element: child }, i);
2236
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(Text, { element: child }, i);
2251
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Emphasis, { element: child }, i);
2252
+ if (child.type === "slack_emoji")
2253
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(SlackEmoji, { element: child }, i);
2254
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Text, { element: child }, i);
2237
2255
  }) });
2238
2256
  };
2239
2257
 
2240
2258
  // src/utils/markdown_parser/sub_elements/emphasis.tsx
2241
- var import_jsx_runtime9 = require("react/jsx-runtime");
2259
+ var import_jsx_runtime10 = require("react/jsx-runtime");
2242
2260
  var Emphasis = (props) => {
2243
2261
  const { element } = props;
2244
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("em", { children: element.children.map((child, i) => {
2262
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("em", { children: element.children.map((child, i) => {
2245
2263
  if (child.type === "delete")
2246
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Delete, { element: child }, i);
2264
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Delete, { element: child }, i);
2247
2265
  if (child.type === "slack_user_mention")
2248
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(SlackUserMention, { element: child }, i);
2266
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(SlackUserMention, { element: child }, i);
2249
2267
  if (child.type === "slack_channel_mention")
2250
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(SlackChannelMention, { element: child }, i);
2268
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(SlackChannelMention, { element: child }, i);
2251
2269
  if (child.type === "slack_user_group_mention")
2252
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(SlackUserGroupMention, { element: child }, i);
2270
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(SlackUserGroupMention, { element: child }, i);
2253
2271
  if (child.type === "slack_broadcast")
2254
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(SlackBroadcast, { element: child }, i);
2272
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(SlackBroadcast, { element: child }, i);
2255
2273
  if (child.type === "slack_date")
2256
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(SlackDate, { element: child }, i);
2274
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(SlackDate, { element: child }, i);
2257
2275
  if (child.type === "strong")
2258
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Strong, { element: child }, i);
2259
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Text, { element: child }, i);
2276
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Strong, { element: child }, i);
2277
+ if (child.type === "slack_emoji")
2278
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(SlackEmoji, { element: child }, i);
2279
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Text, { element: child }, i);
2260
2280
  }) });
2261
2281
  };
2262
2282
 
2263
2283
  // src/utils/markdown_parser/sub_elements/inline_code.tsx
2264
- var import_jsx_runtime10 = require("react/jsx-runtime");
2284
+ var import_jsx_runtime11 = require("react/jsx-runtime");
2265
2285
  var InlineCode = (props) => {
2266
2286
  const { element } = props;
2267
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("code", { className: "slack_code_inline", children: element.value });
2287
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("code", { className: "slack_code_inline", children: element.value });
2268
2288
  };
2269
2289
 
2270
2290
  // src/utils/markdown_parser/sub_elements/link.tsx
2271
- var import_jsx_runtime11 = require("react/jsx-runtime");
2291
+ var import_jsx_runtime12 = require("react/jsx-runtime");
2272
2292
  var Link = (props) => {
2273
2293
  const { element } = props;
2274
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("a", { href: element.url, className: "slack_link", children: element.children.map((child, i) => {
2294
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("a", { href: element.url, className: "slack_link", children: element.children.map((child, i) => {
2275
2295
  if (child.type === "delete")
2276
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Delete, { element: child }, i);
2296
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Delete, { element: child }, i);
2277
2297
  if (child.type === "emphasis")
2278
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Emphasis, { element: child }, i);
2298
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Emphasis, { element: child }, i);
2279
2299
  if (child.type === "strong")
2280
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Strong, { element: child }, i);
2281
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Text, { element: child }, i);
2300
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Strong, { element: child }, i);
2301
+ if (child.type === "slack_emoji")
2302
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(SlackEmoji, { element: child }, i);
2303
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Text, { element: child }, i);
2282
2304
  }) });
2283
2305
  };
2284
2306
 
2285
2307
  // src/utils/markdown_parser/elements/paragraph.tsx
2286
- var import_jsx_runtime12 = require("react/jsx-runtime");
2308
+ var import_jsx_runtime13 = require("react/jsx-runtime");
2287
2309
  var Paragraph = (props) => {
2288
2310
  const { element } = props;
2289
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_jsx_runtime12.Fragment, { children: element.children.map((subelement, i) => {
2311
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_jsx_runtime13.Fragment, { children: element.children.map((subelement, i) => {
2290
2312
  if (subelement.type === "text")
2291
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Text, { element: subelement }, i);
2313
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Text, { element: subelement }, i);
2292
2314
  if (subelement.type === "emphasis")
2293
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Emphasis, { element: subelement }, i);
2315
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Emphasis, { element: subelement }, i);
2294
2316
  if (subelement.type === "inlineCode")
2295
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(InlineCode, { element: subelement }, i);
2317
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(InlineCode, { element: subelement }, i);
2296
2318
  if (subelement.type === "delete")
2297
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Delete, { element: subelement }, i);
2319
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Delete, { element: subelement }, i);
2298
2320
  if (subelement.type === "strong")
2299
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Strong, { element: subelement }, i);
2321
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Strong, { element: subelement }, i);
2300
2322
  if (subelement.type === "link")
2301
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Link, { element: subelement }, i);
2323
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Link, { element: subelement }, i);
2302
2324
  if (subelement.type === "slack_user_mention")
2303
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(SlackUserMention, { element: subelement }, i);
2325
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(SlackUserMention, { element: subelement }, i);
2304
2326
  if (subelement.type === "slack_channel_mention")
2305
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(SlackChannelMention, { element: subelement }, i);
2327
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(SlackChannelMention, { element: subelement }, i);
2306
2328
  if (subelement.type === "slack_user_group_mention")
2307
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(SlackUserGroupMention, { element: subelement }, i);
2329
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(SlackUserGroupMention, { element: subelement }, i);
2308
2330
  if (subelement.type === "slack_broadcast")
2309
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(SlackBroadcast, { element: subelement }, i);
2331
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(SlackBroadcast, { element: subelement }, i);
2310
2332
  if (subelement.type === "slack_date")
2311
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(SlackDate, { element: subelement }, i);
2333
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(SlackDate, { element: subelement }, i);
2334
+ if (subelement.type === "slack_emoji")
2335
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(SlackEmoji, { element: subelement }, i);
2312
2336
  return null;
2313
2337
  }) });
2314
2338
  };
2315
2339
 
2316
2340
  // src/utils/markdown_parser/elements/blockquote.tsx
2317
- var import_jsx_runtime13 = require("react/jsx-runtime");
2341
+ var import_jsx_runtime14 = require("react/jsx-runtime");
2318
2342
  var Blockquote = (props) => {
2319
2343
  const { element } = props;
2320
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_jsx_runtime13.Fragment, { children: element.children.map((para) => {
2321
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Paragraph, { element: para });
2344
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_jsx_runtime14.Fragment, { children: element.children.map((para) => {
2345
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Paragraph, { element: para });
2322
2346
  }) });
2323
2347
  };
2324
2348
 
2325
2349
  // src/utils/markdown_parser/elements/code.tsx
2326
- var import_jsx_runtime14 = require("react/jsx-runtime");
2350
+ var import_jsx_runtime15 = require("react/jsx-runtime");
2327
2351
  var Code = (props) => {
2328
2352
  const { element } = props;
2329
- return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("code", { className: "slack_code", children: element.value });
2353
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("code", { className: "slack_code", children: element.value });
2330
2354
  };
2331
2355
 
2332
2356
  // src/utils/markdown_parser/tokenizers/slack_user_mention/tokenizer.ts
@@ -2865,19 +2889,19 @@ var parse5 = function(api) {
2865
2889
  const nodePoints = api.getNodePoints();
2866
2890
  const fullString = (0, import_character10.calcStringFromNodePoints)(nodePoints, token.startIndex, token.endIndex);
2867
2891
  const datePattern = /<!date\^(\d+)\^([^\^]*)\^?([^\|]*)\|([^>]*)>/;
2868
- const match6 = datePattern.exec(fullString);
2892
+ const match7 = datePattern.exec(fullString);
2869
2893
  let value = {
2870
2894
  timestamp: "",
2871
2895
  tokenString: "",
2872
2896
  optionalLink: "",
2873
2897
  fallbackText: ""
2874
2898
  };
2875
- if (match6) {
2899
+ if (match7) {
2876
2900
  value = {
2877
- timestamp: match6[1],
2878
- tokenString: match6[2],
2879
- optionalLink: match6[3],
2880
- fallbackText: match6[4]
2901
+ timestamp: match7[1],
2902
+ tokenString: match7[2],
2903
+ optionalLink: match7[3],
2904
+ fallbackText: match7[4]
2881
2905
  };
2882
2906
  }
2883
2907
  const node = api.shouldReservePosition ? { type: SlackDateType, position: api.calcPosition(token), value } : { type: SlackDateType, value };
@@ -2898,9 +2922,115 @@ var SlackDateTokenizer = class extends import_core_tokenizer8.BaseInlineTokenize
2898
2922
  }
2899
2923
  };
2900
2924
 
2925
+ // src/utils/markdown_parser/tokenizers/slack_emoji/tokenizer.ts
2926
+ var import_core_tokenizer9 = require("@yozora/core-tokenizer");
2927
+
2928
+ // src/utils/markdown_parser/tokenizers/slack_emoji/match.ts
2929
+ var import_character11 = require("@yozora/character");
2930
+
2931
+ // src/utils/markdown_parser/tokenizers/slack_emoji/types.ts
2932
+ var SlackEmojiType = "slack_emoji";
2933
+
2934
+ // src/utils/markdown_parser/tokenizers/slack_emoji/match.ts
2935
+ var match6 = function(api) {
2936
+ return { findDelimiter, processSingleDelimiter };
2937
+ function* findDelimiter() {
2938
+ var _a;
2939
+ const nodePoints = api.getNodePoints();
2940
+ const blockStartIndex = api.getBlockStartIndex();
2941
+ const blockEndIndex = api.getBlockEndIndex();
2942
+ const potentialDelimiters = [];
2943
+ for (let i = blockStartIndex; i < blockEndIndex; ++i) {
2944
+ if (((_a = nodePoints[i]) == null ? void 0 : _a.codePoint) === import_character11.AsciiCodePoint.COLON) {
2945
+ const endIndex = findEndDelimiter(nodePoints, i, blockEndIndex);
2946
+ if (endIndex !== -1) {
2947
+ potentialDelimiters.push({
2948
+ type: "both",
2949
+ startIndex: i,
2950
+ endIndex: endIndex + 1,
2951
+ thickness: endIndex + 1 - i
2952
+ });
2953
+ i = endIndex;
2954
+ }
2955
+ }
2956
+ }
2957
+ let pIndex = 0;
2958
+ let lastEndIndex = -1;
2959
+ let currentDelimiter = null;
2960
+ while (pIndex < potentialDelimiters.length) {
2961
+ const [startIndex, endIndex] = yield currentDelimiter;
2962
+ if (lastEndIndex === endIndex) {
2963
+ if (currentDelimiter == null || currentDelimiter.startIndex >= startIndex)
2964
+ continue;
2965
+ }
2966
+ lastEndIndex = endIndex;
2967
+ for (; pIndex < potentialDelimiters.length; ++pIndex) {
2968
+ const delimiter = potentialDelimiters[pIndex];
2969
+ if (delimiter.startIndex >= startIndex) {
2970
+ currentDelimiter = {
2971
+ type: "full",
2972
+ startIndex: delimiter.startIndex,
2973
+ endIndex: delimiter.endIndex,
2974
+ thickness: delimiter.thickness
2975
+ };
2976
+ break;
2977
+ }
2978
+ }
2979
+ }
2980
+ }
2981
+ function findEndDelimiter(nodePoints, startIndex, blockEndIndex) {
2982
+ var _a;
2983
+ for (let i = startIndex + 1; i < blockEndIndex; ++i) {
2984
+ if (((_a = nodePoints[i]) == null ? void 0 : _a.codePoint) === import_character11.AsciiCodePoint.COLON) {
2985
+ return i;
2986
+ }
2987
+ }
2988
+ return -1;
2989
+ }
2990
+ function processSingleDelimiter(delimiter) {
2991
+ const token = {
2992
+ nodeType: SlackEmojiType,
2993
+ startIndex: delimiter.startIndex,
2994
+ endIndex: delimiter.endIndex,
2995
+ thickness: delimiter.thickness
2996
+ };
2997
+ return [token];
2998
+ }
2999
+ };
3000
+
3001
+ // src/utils/markdown_parser/tokenizers/slack_emoji/parse.ts
3002
+ var import_character12 = require("@yozora/character");
3003
+ var parse6 = function(api) {
3004
+ return {
3005
+ parse: (tokens) => tokens.map((token) => {
3006
+ const nodePoints = api.getNodePoints();
3007
+ const fullString = (0, import_character12.calcStringFromNodePoints)(nodePoints, token.startIndex, token.endIndex);
3008
+ const emojiPattern = /^:(\w+):$/;
3009
+ const match7 = emojiPattern.exec(fullString);
3010
+ let value = fullString;
3011
+ if (match7)
3012
+ value = match7[1];
3013
+ const node = api.shouldReservePosition ? { type: SlackEmojiType, position: api.calcPosition(token), value } : { type: SlackEmojiType, value };
3014
+ return node;
3015
+ })
3016
+ };
3017
+ };
3018
+
3019
+ // src/utils/markdown_parser/tokenizers/slack_emoji/tokenizer.ts
3020
+ var SlackEmojiTokenizer = class extends import_core_tokenizer9.BaseInlineTokenizer {
3021
+ constructor(props = {}) {
3022
+ super({
3023
+ name: SlackEmojiType,
3024
+ priority: props.priority || import_core_tokenizer9.TokenizerPriority.ATOMIC
3025
+ });
3026
+ this.match = match6;
3027
+ this.parse = parse6;
3028
+ }
3029
+ };
3030
+
2901
3031
  // src/utils/markdown_parser/parser.tsx
2902
- var import_jsx_runtime15 = require("react/jsx-runtime");
2903
- var parser = new import_parser.default().unmountTokenizer("@yozora/tokenizer-list").useTokenizer(new SlackUserMentionTokenizer()).useTokenizer(new SlackChannelMentionTokenizer()).useTokenizer(new SlackUserGroupMentionTokenizer()).useTokenizer(new SlackBroadcastTokenizer()).useTokenizer(new SlackDateTokenizer());
3032
+ var import_jsx_runtime16 = require("react/jsx-runtime");
3033
+ var parser = new import_parser.default().unmountTokenizer("@yozora/tokenizer-list").useTokenizer(new SlackUserMentionTokenizer()).useTokenizer(new SlackChannelMentionTokenizer()).useTokenizer(new SlackUserGroupMentionTokenizer()).useTokenizer(new SlackBroadcastTokenizer()).useTokenizer(new SlackDateTokenizer()).useTokenizer(new SlackEmojiTokenizer());
2904
3034
  var markdown_parser = (markdown, options) => {
2905
3035
  if (!markdown)
2906
3036
  return null;
@@ -2917,13 +3047,13 @@ var markdown_parser = (markdown, options) => {
2917
3047
  text_string = text_string.replace(/<!channel>/g, "@channel");
2918
3048
  const parsed_data = parser.parse(text_string);
2919
3049
  const elements = parsed_data.children;
2920
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { children: elements.map((element, i) => {
3050
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { children: elements.map((element, i) => {
2921
3051
  if (element.type === "paragraph")
2922
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Paragraph, { element }, i);
3052
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(Paragraph, { element }, i);
2923
3053
  if (element.type === "blockquote")
2924
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Blockquote, { element }, i);
3054
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(Blockquote, { element }, i);
2925
3055
  if (element.type === "code")
2926
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Code, { element }, i);
3056
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(Code, { element }, i);
2927
3057
  return null;
2928
3058
  }) });
2929
3059
  };
@@ -2978,21 +3108,21 @@ var is_accessory_stacked = (element) => {
2978
3108
  };
2979
3109
 
2980
3110
  // src/header.tsx
2981
- var import_jsx_runtime16 = require("react/jsx-runtime");
3111
+ var import_jsx_runtime17 = require("react/jsx-runtime");
2982
3112
  var Header = (props) => {
2983
3113
  const { name, time } = props;
2984
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { className: "flex gap-[5px] items-center w-full slack_blocks_to_jsx--header", children: [
2985
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("h3", { className: "font-black text-[15px]", children: name }),
2986
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { className: "h-[14px] w-[27px] leading-[12.5px] py-[1px] px-[3px] uppercase text-[10px] text-black-primary/[0.7] bg-black-primary/[0.13] font-semibold rounded-[2px] text-center", children: "APP" }),
2987
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { className: "text-xs text-black-secondary uppercase leading-[17.6px]", children: dateToTime(time) })
3114
+ return /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)("div", { className: "flex gap-[5px] items-center w-full slack_blocks_to_jsx--header", children: [
3115
+ /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("h3", { className: "font-black text-[15px]", children: name }),
3116
+ /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("div", { className: "h-[14px] w-[27px] leading-[12.5px] py-[1px] px-[3px] uppercase text-[10px] text-black-primary/[0.7] bg-black-primary/[0.13] font-semibold rounded-[2px] text-center", children: "APP" }),
3117
+ /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("div", { className: "text-xs text-black-secondary uppercase leading-[17.6px]", children: dateToTime(time) })
2988
3118
  ] });
2989
3119
  };
2990
3120
 
2991
3121
  // src/components/elements/image_element.tsx
2992
- var import_jsx_runtime17 = require("react/jsx-runtime");
3122
+ var import_jsx_runtime18 = require("react/jsx-runtime");
2993
3123
  var ImageElement = (props) => {
2994
3124
  const { alt_text, image_url } = props.data;
2995
- return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("div", { className: "relative", children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
3125
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "relative", children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
2996
3126
  "img",
2997
3127
  {
2998
3128
  src: image_url,
@@ -3003,23 +3133,22 @@ var ImageElement = (props) => {
3003
3133
  };
3004
3134
 
3005
3135
  // src/components/composition_objects/text_object.tsx
3006
- var import_jsx_runtime18 = require("react/jsx-runtime");
3136
+ var import_jsx_runtime19 = require("react/jsx-runtime");
3007
3137
  var TextObject = (props) => {
3008
3138
  const { type, text, emoji, verbatim = false } = props.data;
3009
3139
  const { className = "" } = props;
3010
3140
  const { channels, users, hooks } = useGlobalData();
3011
- let emoji_parsed = type == "mrkdwn" ? hooks.emoji ? hooks.emoji(text) : parseEmojis(text) : emoji === false ? text : hooks.emoji ? hooks.emoji(text) : parseEmojis(text);
3012
- emoji_parsed = emoji_parsed.replace(/&gt;/g, "> ").replace(/&lt;/g, "<");
3141
+ const parsed = text.replace(/&gt;/g, "> ").replace(/&lt;/g, "<");
3013
3142
  if (type === "plain_text")
3014
- return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className, children: markdown_parser(emoji_parsed, { markdown: false, users, channels, hooks }) });
3015
- return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className, children: markdown_parser(emoji_parsed, { markdown: true, users, channels, hooks }) });
3143
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className, children: markdown_parser(parsed, { markdown: false, users, channels, hooks }) });
3144
+ return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className, children: markdown_parser(parsed, { markdown: true, users, channels, hooks }) });
3016
3145
  };
3017
3146
 
3018
3147
  // src/components/elements/button_element.tsx
3019
- var import_jsx_runtime19 = require("react/jsx-runtime");
3148
+ var import_jsx_runtime20 = require("react/jsx-runtime");
3020
3149
  var ButtonElement = (props) => {
3021
3150
  const { text, action_id, url, style, accessibility_label } = props.data;
3022
- return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
3151
+ return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
3023
3152
  "button",
3024
3153
  {
3025
3154
  type: "button",
@@ -3031,14 +3160,14 @@ var ButtonElement = (props) => {
3031
3160
  window.open(url, "_blank");
3032
3161
  }
3033
3162
  },
3034
- children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(TextObject, { data: text })
3163
+ children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(TextObject, { data: text })
3035
3164
  }
3036
3165
  );
3037
3166
  };
3038
3167
 
3039
3168
  // src/components/elements/static_select_element.tsx
3040
3169
  var import_react = require("react");
3041
- var import_jsx_runtime20 = require("react/jsx-runtime");
3170
+ var import_jsx_runtime21 = require("react/jsx-runtime");
3042
3171
  var StaticSelectElement = (props) => {
3043
3172
  const {
3044
3173
  action_id,
@@ -3073,20 +3202,20 @@ var StaticSelectElement = (props) => {
3073
3202
  const results = option.text.text.toLowerCase().includes(search.toLowerCase());
3074
3203
  return results;
3075
3204
  }, []);
3076
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)(
3205
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
3077
3206
  "div",
3078
3207
  {
3079
3208
  id: action_id,
3080
3209
  className: "py-1 px-2 h-7 min-h-[28px] relative flex items-center justify-between rounded text-small w-[190px] border border-black-primary.3",
3081
3210
  tabIndex: 0,
3082
3211
  children: [
3083
- visible && /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
3212
+ visible && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
3084
3213
  "div",
3085
3214
  {
3086
3215
  className: "absolute top-[24px] -left-3 bg-white-secondary border border-gray-primary rounded-[6px] shadow-custom_shadow-1 w-[322px] max-w-[322px] max-h-[240px] overflow-auto py-3 z-20",
3087
3216
  id: "static_select_popup",
3088
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", { className: "flex flex-col", children: filteredOptions.map((option, i) => {
3089
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
3217
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "flex flex-col", children: filteredOptions.map((option, i) => {
3218
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
3090
3219
  "div",
3091
3220
  {
3092
3221
  className: "h-7 px-6 flex items-center select-none cursor-pointer hover:bg-blue-primary hover:text-white-primary",
@@ -3095,14 +3224,14 @@ var StaticSelectElement = (props) => {
3095
3224
  setVisible(false);
3096
3225
  setSelected(option.value);
3097
3226
  },
3098
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(TextObject, { data: option.text })
3227
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(TextObject, { data: option.text })
3099
3228
  },
3100
3229
  i
3101
3230
  );
3102
3231
  }) })
3103
3232
  }
3104
3233
  ),
3105
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
3234
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
3106
3235
  "input",
3107
3236
  {
3108
3237
  type: "text",
@@ -3113,7 +3242,7 @@ var StaticSelectElement = (props) => {
3113
3242
  "aria-label": "Select an item"
3114
3243
  }
3115
3244
  ),
3116
- !search && /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", { className: "absolute w-full h-full pointer-events-none flex items-center text-black-primary.3", children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
3245
+ !search && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "absolute w-full h-full pointer-events-none flex items-center text-black-primary.3", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
3117
3246
  TextObject,
3118
3247
  {
3119
3248
  data: placeholder != null ? placeholder : {
@@ -3122,7 +3251,7 @@ var StaticSelectElement = (props) => {
3122
3251
  }
3123
3252
  }
3124
3253
  ) }),
3125
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
3254
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
3126
3255
  "button",
3127
3256
  {
3128
3257
  type: "button",
@@ -3131,7 +3260,7 @@ var StaticSelectElement = (props) => {
3131
3260
  onClick: () => {
3132
3261
  setVisible((prev) => !prev);
3133
3262
  },
3134
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
3263
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
3135
3264
  "svg",
3136
3265
  {
3137
3266
  xmlns: "http://www.w3.org/2000/svg",
@@ -3140,7 +3269,7 @@ var StaticSelectElement = (props) => {
3140
3269
  strokeWidth: "3",
3141
3270
  stroke: "currentColor",
3142
3271
  className: "w-3 h-3",
3143
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M19.5 8.25l-7.5 7.5-7.5-7.5" })
3272
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M19.5 8.25l-7.5 7.5-7.5-7.5" })
3144
3273
  }
3145
3274
  )
3146
3275
  }
@@ -3152,7 +3281,7 @@ var StaticSelectElement = (props) => {
3152
3281
 
3153
3282
  // src/components/elements/checkboxes_element.tsx
3154
3283
  var import_react2 = require("react");
3155
- var import_jsx_runtime21 = require("react/jsx-runtime");
3284
+ var import_jsx_runtime22 = require("react/jsx-runtime");
3156
3285
  var CheckboxesElement = (props) => {
3157
3286
  const { action_id, options, focus_on_load, initial_options } = props.data;
3158
3287
  const [selected, setSelected] = (0, import_react2.useState)(
@@ -3166,15 +3295,15 @@ var CheckboxesElement = (props) => {
3166
3295
  input_ref.current.focus();
3167
3296
  }
3168
3297
  }, [focus_on_load]);
3169
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { id: action_id, className: "my-1 flex w-full slack_blocks_to_jsx__checkboxes_element", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("fieldset", { className: "flex flex-col gap-2", children: options.map((option, i) => {
3298
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("div", { id: action_id, className: "my-1 flex w-full slack_blocks_to_jsx__checkboxes_element", children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("fieldset", { className: "flex flex-col gap-2", children: options.map((option, i) => {
3170
3299
  const { text, value, description } = option;
3171
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
3300
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(
3172
3301
  "label",
3173
3302
  {
3174
3303
  className: "flex cursor-pointer items-baseline gap-3 select-none",
3175
3304
  htmlFor: `checkboxes-${action_id}-value-${value}-${i}`,
3176
3305
  children: [
3177
- /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
3306
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
3178
3307
  "input",
3179
3308
  {
3180
3309
  type: "checkbox",
@@ -3190,9 +3319,9 @@ var CheckboxesElement = (props) => {
3190
3319
  }
3191
3320
  }
3192
3321
  ) }),
3193
- /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { children: [
3194
- /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(TextObject, { data: text }),
3195
- description && /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(TextObject, { className: "text-black-secondary", data: description })
3322
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { children: [
3323
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(TextObject, { data: text }),
3324
+ description && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(TextObject, { className: "text-black-secondary", data: description })
3196
3325
  ] })
3197
3326
  ]
3198
3327
  }
@@ -3202,7 +3331,7 @@ var CheckboxesElement = (props) => {
3202
3331
 
3203
3332
  // src/components/elements/plain_text_input.tsx
3204
3333
  var import_react3 = require("react");
3205
- var import_jsx_runtime22 = require("react/jsx-runtime");
3334
+ var import_jsx_runtime23 = require("react/jsx-runtime");
3206
3335
  var PlaintTextInput = (props) => {
3207
3336
  const {
3208
3337
  action_id,
@@ -3230,15 +3359,15 @@ var PlaintTextInput = (props) => {
3230
3359
  document.removeEventListener("mousedown", handleClickOutside);
3231
3360
  };
3232
3361
  }, []);
3233
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(
3362
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
3234
3363
  "div",
3235
3364
  {
3236
3365
  id: action_id,
3237
3366
  className: "relative text-small w-full slack_blocks_to_jsx__plain_text_input_element",
3238
3367
  tabIndex: 0,
3239
3368
  children: [
3240
- !value && placeholder && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("div", { className: "absolute left-2 top-2 text-black-primary.3", children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(TextObject, { data: placeholder }) }),
3241
- !value && !placeholder && /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("div", { className: "absolute left-2 top-2 text-black-primary.3", children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
3369
+ !value && placeholder && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: "absolute left-2 top-2 text-black-primary.3", children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(TextObject, { data: placeholder }) }),
3370
+ !value && !placeholder && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: "absolute left-2 top-2 text-black-primary.3", children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
3242
3371
  TextObject,
3243
3372
  {
3244
3373
  data: {
@@ -3247,7 +3376,7 @@ var PlaintTextInput = (props) => {
3247
3376
  }
3248
3377
  }
3249
3378
  ) }),
3250
- /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
3379
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
3251
3380
  "textarea",
3252
3381
  {
3253
3382
  value,
@@ -3270,7 +3399,7 @@ var PlaintTextInput = (props) => {
3270
3399
 
3271
3400
  // src/components/elements/users_select_element.tsx
3272
3401
  var import_react4 = require("react");
3273
- var import_jsx_runtime23 = require("react/jsx-runtime");
3402
+ var import_jsx_runtime24 = require("react/jsx-runtime");
3274
3403
  var UsersSelectElement = (props) => {
3275
3404
  const { action_id, focus_on_load, placeholder, type, confirm, initial_user, people } = props.data;
3276
3405
  const [visible, setVisible] = (0, import_react4.useState)(focus_on_load || false);
@@ -3295,20 +3424,20 @@ var UsersSelectElement = (props) => {
3295
3424
  const name = person.name.toLowerCase();
3296
3425
  return name.includes(search_query);
3297
3426
  }, []);
3298
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
3427
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
3299
3428
  "div",
3300
3429
  {
3301
3430
  id: action_id,
3302
3431
  className: "py-1 px-2 h-7 min-h-[28px] relative flex items-center justify-between rounded text-small w-[190px] border border-black-primary.3 slack_blocks_to_jsx__users_select_element",
3303
3432
  tabIndex: 0,
3304
3433
  children: [
3305
- visible && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
3434
+ visible && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
3306
3435
  "div",
3307
3436
  {
3308
3437
  className: "absolute top-[24px] -left-3 bg-white-secondary border border-gray-primary rounded-[6px] shadow-custom_shadow-1 w-[322px] max-w-[322px] max-h-[240px] overflow-auto py-3 z-20",
3309
3438
  id: "static_select_popup",
3310
- children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: "flex flex-col", children: filteredOptions.map((option, i) => {
3311
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
3439
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "flex flex-col", children: filteredOptions.map((option, i) => {
3440
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
3312
3441
  "button",
3313
3442
  {
3314
3443
  className: "h-7 px-6 flex group items-center gap-2 select-none cursor-pointer hover:bg-blue-primary hover:text-white-primary",
@@ -3319,7 +3448,7 @@ var UsersSelectElement = (props) => {
3319
3448
  setSelected(option.id);
3320
3449
  },
3321
3450
  children: [
3322
- option.image && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
3451
+ option.image && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
3323
3452
  "img",
3324
3453
  {
3325
3454
  src: option.image,
@@ -3327,8 +3456,8 @@ var UsersSelectElement = (props) => {
3327
3456
  className: "w-5 h-5 rounded-md overflow-hidden"
3328
3457
  }
3329
3458
  ),
3330
- !option.image && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: "w-5 h-5 rounded-md overflow-hidden bg-gray-300 text-black-primary font-semibold flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { children: option.name[0] || "" }) }),
3331
- /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
3459
+ !option.image && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "w-5 h-5 rounded-md overflow-hidden bg-gray-300 text-black-primary font-semibold flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("span", { children: option.name[0] || "" }) }),
3460
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
3332
3461
  TextObject,
3333
3462
  {
3334
3463
  data: {
@@ -3337,17 +3466,17 @@ var UsersSelectElement = (props) => {
3337
3466
  }
3338
3467
  }
3339
3468
  ),
3340
- /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: "relative", children: [
3341
- option.online && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
3469
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: "relative", children: [
3470
+ option.online && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
3342
3471
  "div",
3343
3472
  {
3344
3473
  className: `bg-green-secondary w-[9px] h-[9px] rounded-full shrink-0`
3345
3474
  }
3346
3475
  ),
3347
- !option.online && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: "w-[9px] h-[9px] rounded-full border-[1.5px] shrink-0 border-black-secondary group-hover:border-white-primary" }),
3348
- option.sleeping && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: "absolute -top-[5px] -right-[5px] h-[10px] w-[10px] rounded-full bg-white-secondary flex justify-center z-[10] text-[8px] leading-[8px] font-semibold group-hover:bg-blue-primary", children: "z" })
3476
+ !option.online && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "w-[9px] h-[9px] rounded-full border-[1.5px] shrink-0 border-black-secondary group-hover:border-white-primary" }),
3477
+ option.sleeping && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "absolute -top-[5px] -right-[5px] h-[10px] w-[10px] rounded-full bg-white-secondary flex justify-center z-[10] text-[8px] leading-[8px] font-semibold group-hover:bg-blue-primary", children: "z" })
3349
3478
  ] }),
3350
- /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: "text-black-primary group-hover:text-white-primary", children: option.name })
3479
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "text-black-primary group-hover:text-white-primary", children: option.name })
3351
3480
  ]
3352
3481
  },
3353
3482
  i
@@ -3355,7 +3484,7 @@ var UsersSelectElement = (props) => {
3355
3484
  }) })
3356
3485
  }
3357
3486
  ),
3358
- /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
3487
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
3359
3488
  "input",
3360
3489
  {
3361
3490
  type: "text",
@@ -3367,7 +3496,7 @@ var UsersSelectElement = (props) => {
3367
3496
  "aria-label": "Select an item"
3368
3497
  }
3369
3498
  ),
3370
- !search && /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: "absolute w-full h-full pointer-events-none flex items-center text-black-primary.3", children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
3499
+ !search && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "absolute w-full h-full pointer-events-none flex items-center text-black-primary.3", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
3371
3500
  TextObject,
3372
3501
  {
3373
3502
  data: placeholder != null ? placeholder : {
@@ -3376,7 +3505,7 @@ var UsersSelectElement = (props) => {
3376
3505
  }
3377
3506
  }
3378
3507
  ) }),
3379
- /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
3508
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
3380
3509
  "button",
3381
3510
  {
3382
3511
  type: "button",
@@ -3385,7 +3514,7 @@ var UsersSelectElement = (props) => {
3385
3514
  onClick: () => {
3386
3515
  setVisible((prev) => !prev);
3387
3516
  },
3388
- children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
3517
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
3389
3518
  "svg",
3390
3519
  {
3391
3520
  xmlns: "http://www.w3.org/2000/svg",
@@ -3394,7 +3523,7 @@ var UsersSelectElement = (props) => {
3394
3523
  strokeWidth: "3",
3395
3524
  stroke: "currentColor",
3396
3525
  className: "w-3 h-3",
3397
- children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M19.5 8.25l-7.5 7.5-7.5-7.5" })
3526
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M19.5 8.25l-7.5 7.5-7.5-7.5" })
3398
3527
  }
3399
3528
  )
3400
3529
  }
@@ -3405,52 +3534,52 @@ var UsersSelectElement = (props) => {
3405
3534
  };
3406
3535
 
3407
3536
  // src/components/blocks/actions.tsx
3408
- var import_jsx_runtime24 = require("react/jsx-runtime");
3537
+ var import_jsx_runtime25 = require("react/jsx-runtime");
3409
3538
  var Actions = (props) => {
3410
3539
  const { elements, block_id } = props.data;
3411
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
3540
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
3412
3541
  "div",
3413
3542
  {
3414
3543
  id: block_id,
3415
3544
  className: "mb-2 text-primary flex w-full text-black-primary items-center slack_blocks_to_jsx__actions",
3416
- children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "flex flex-wrap", children: elements.map((element, i) => {
3545
+ children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { className: "flex flex-wrap", children: elements.map((element, i) => {
3417
3546
  if (element.type === "button") {
3418
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "mt-2 mr-2", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(ButtonElement, { data: element }) }, i);
3547
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { className: "mt-2 mr-2", children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(ButtonElement, { data: element }) }, i);
3419
3548
  }
3420
3549
  if (element.type === "static_select") {
3421
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "mt-2 mr-2", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(StaticSelectElement, { data: element }) }, i);
3550
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { className: "mt-2 mr-2", children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(StaticSelectElement, { data: element }) }, i);
3422
3551
  }
3423
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "mt-2 mr-2" }, i);
3552
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { className: "mt-2 mr-2" }, i);
3424
3553
  }) })
3425
3554
  }
3426
3555
  );
3427
3556
  };
3428
3557
 
3429
3558
  // src/components/blocks/context.tsx
3430
- var import_jsx_runtime25 = require("react/jsx-runtime");
3559
+ var import_jsx_runtime26 = require("react/jsx-runtime");
3431
3560
  var Context = (props) => {
3432
3561
  const { elements, block_id } = props.data;
3433
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
3562
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
3434
3563
  "div",
3435
3564
  {
3436
3565
  id: block_id,
3437
3566
  className: "my-1 text-primary flex w-full text-black-primary flex-wrap items-center overflow-hidden slack_blocks_to_jsx__context",
3438
3567
  children: elements.slice(0, 10).map((element, i) => {
3439
3568
  if (element.type !== "image") {
3440
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { className: "text-black-secondary text-small pr-3 flex items-center", children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(TextObject, { data: element }) }, i);
3569
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { className: "text-black-secondary text-small pr-3 flex items-center", children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(TextObject, { data: element }) }, i);
3441
3570
  }
3442
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(ImageElement, { data: element }) }, i);
3571
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(ImageElement, { data: element }) }, i);
3443
3572
  })
3444
3573
  }
3445
3574
  );
3446
3575
  };
3447
3576
 
3448
3577
  // src/components/blocks/divider.tsx
3449
- var import_jsx_runtime26 = require("react/jsx-runtime");
3578
+ var import_jsx_runtime27 = require("react/jsx-runtime");
3450
3579
  var Divider = (props) => {
3451
3580
  const { data } = props;
3452
3581
  const { block_id } = data;
3453
- return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
3582
+ return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
3454
3583
  "div",
3455
3584
  {
3456
3585
  id: block_id,
@@ -3466,31 +3595,31 @@ var File = (props) => {
3466
3595
  };
3467
3596
 
3468
3597
  // src/components/blocks/header.tsx
3469
- var import_jsx_runtime27 = require("react/jsx-runtime");
3598
+ var import_jsx_runtime28 = require("react/jsx-runtime");
3470
3599
  var Header2 = (props) => {
3471
3600
  const { text, block_id } = props.data;
3472
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { id: block_id, className: "mt-1 slack_blocks_to_jsx__header", children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("h3", { className: "text-header font-bold slack_blocks_to_jsx__header_heading", children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(TextObject, { data: text }) }) });
3601
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { id: block_id, className: "mt-1 slack_blocks_to_jsx__header", children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("h3", { className: "text-header font-bold slack_blocks_to_jsx__header_heading", children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(TextObject, { data: text }) }) });
3473
3602
  };
3474
3603
 
3475
3604
  // src/components/blocks/image.tsx
3476
3605
  var import_react5 = require("react");
3477
- var import_jsx_runtime28 = require("react/jsx-runtime");
3606
+ var import_jsx_runtime29 = require("react/jsx-runtime");
3478
3607
  var Image = (props) => {
3479
3608
  const { block_id, alt_text, image_url, image_bytes, image_height, image_width } = props.data;
3480
3609
  const [showImage, setShowImage] = (0, import_react5.useState)(true);
3481
- return /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { id: block_id, className: "my-2 flex flex-col gap-2 slack_blocks_to_jsx__image", children: [
3482
- /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: "text-black-secondary text-small flex gap-1 items-center", children: [
3483
- /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("span", { children: [
3610
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { id: block_id, className: "my-2 flex flex-col gap-2 slack_blocks_to_jsx__image", children: [
3611
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { className: "text-black-secondary text-small flex gap-1 items-center", children: [
3612
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("span", { children: [
3484
3613
  alt_text,
3485
3614
  image_bytes && ` (${Math.round(image_bytes / 1e3)} kB)`
3486
3615
  ] }),
3487
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3616
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3488
3617
  "button",
3489
3618
  {
3490
3619
  type: "button",
3491
3620
  className: "w-[15px] h-[15px]",
3492
3621
  onClick: () => setShowImage((prev) => !prev),
3493
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3622
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3494
3623
  "svg",
3495
3624
  {
3496
3625
  xmlns: "http://www.w3.org/2000/svg",
@@ -3506,7 +3635,7 @@ var Image = (props) => {
3506
3635
  style: {
3507
3636
  transform: showImage ? "rotate(0deg)" : "rotate(-90deg)"
3508
3637
  },
3509
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3638
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3510
3639
  "path",
3511
3640
  {
3512
3641
  fill: "currentColor",
@@ -3519,7 +3648,7 @@ var Image = (props) => {
3519
3648
  }
3520
3649
  )
3521
3650
  ] }),
3522
- showImage && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { className: "rounded-md overflow-hidden relative max-w-max", children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3651
+ showImage && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: "rounded-md overflow-hidden relative max-w-max", children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3523
3652
  "img",
3524
3653
  {
3525
3654
  src: image_url,
@@ -3534,17 +3663,17 @@ var Image = (props) => {
3534
3663
  };
3535
3664
 
3536
3665
  // src/components/blocks/input.tsx
3537
- var import_jsx_runtime29 = require("react/jsx-runtime");
3666
+ var import_jsx_runtime30 = require("react/jsx-runtime");
3538
3667
  var Input = (props) => {
3539
3668
  const { element: given_element, label, block_id, hint, optional, type } = props.data;
3540
3669
  const element = given_element ? getElementComponent(given_element) : null;
3541
- return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3670
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
3542
3671
  "div",
3543
3672
  {
3544
3673
  id: block_id,
3545
3674
  className: `mt-2 mb-1 text-primary slack_blocks_to_jsx__input flex w-full text-black-primary`,
3546
- children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: "grow", children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { className: "flex flex-col gap-2", children: [
3547
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3675
+ children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", { className: "grow", children: /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "flex flex-col gap-2", children: [
3676
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
3548
3677
  TextObject,
3549
3678
  {
3550
3679
  data: {
@@ -3555,11 +3684,11 @@ var Input = (props) => {
3555
3684
  }
3556
3685
  }
3557
3686
  ),
3558
- /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { className: "mb-1 flex flex-col gap-1", children: [
3559
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: "relative shrink-0", children: element }),
3560
- (hint || given_element.type === "plain_text_input") && /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { className: "text-black-secondary text-small flex gap-1", children: [
3561
- hint && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { className: "inline", children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(TextObject, { data: hint }) }),
3562
- given_element.type === "plain_text_input" && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("p", { children: "\u21B5 Please 'enter' to submit" })
3687
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "mb-1 flex flex-col gap-1", children: [
3688
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", { className: "relative shrink-0", children: element }),
3689
+ (hint || given_element.type === "plain_text_input") && /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: "text-black-secondary text-small flex gap-1", children: [
3690
+ hint && /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("div", { className: "inline", children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(TextObject, { data: hint }) }),
3691
+ given_element.type === "plain_text_input" && /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("p", { children: "\u21B5 Please 'enter' to submit" })
3563
3692
  ] })
3564
3693
  ] })
3565
3694
  ] }) })
@@ -3568,27 +3697,27 @@ var Input = (props) => {
3568
3697
  };
3569
3698
 
3570
3699
  // src/components/blocks/rich_text/rich_text_list_wrapper.tsx
3571
- var import_jsx_runtime30 = require("react/jsx-runtime");
3700
+ var import_jsx_runtime31 = require("react/jsx-runtime");
3572
3701
  var RichTextListWrapper = (props) => {
3573
3702
  const _a = props, { element, children } = _a, rest = __objRest(_a, ["element", "children"]);
3574
3703
  if (element.style === "bullet") {
3575
- return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("ul", __spreadProps(__spreadValues({}, rest), { children }));
3704
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("ul", __spreadProps(__spreadValues({}, rest), { children }));
3576
3705
  }
3577
- return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("ol", __spreadProps(__spreadValues({}, rest), { children }));
3706
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("ol", __spreadProps(__spreadValues({}, rest), { children }));
3578
3707
  };
3579
3708
 
3580
3709
  // src/components/blocks/rich_text/rich_text_section_broadcast.tsx
3581
- var import_jsx_runtime31 = require("react/jsx-runtime");
3710
+ var import_jsx_runtime32 = require("react/jsx-runtime");
3582
3711
  var RichTextSectionBroadcast = (props) => {
3583
3712
  const { range, style } = props;
3584
3713
  const { hooks } = useGlobalData();
3585
3714
  if (range === "channel" && hooks.atChannel)
3586
- return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_jsx_runtime31.Fragment, { children: hooks.atChannel() });
3715
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_jsx_runtime32.Fragment, { children: hooks.atChannel() });
3587
3716
  if (range === "everyone" && hooks.atEveryone)
3588
- return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_jsx_runtime31.Fragment, { children: hooks.atEveryone() });
3717
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_jsx_runtime32.Fragment, { children: hooks.atEveryone() });
3589
3718
  if (range === "here" && hooks.atHere)
3590
- return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_jsx_runtime31.Fragment, { children: hooks.atHere() });
3591
- return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(
3719
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_jsx_runtime32.Fragment, { children: hooks.atHere() });
3720
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
3592
3721
  "span",
3593
3722
  {
3594
3723
  className: `
@@ -3607,15 +3736,15 @@ var RichTextSectionBroadcast = (props) => {
3607
3736
  };
3608
3737
 
3609
3738
  // src/components/blocks/rich_text/rich_text_section_channel.tsx
3610
- var import_jsx_runtime32 = require("react/jsx-runtime");
3739
+ var import_jsx_runtime33 = require("react/jsx-runtime");
3611
3740
  var RichTextSectionChannel = (props) => {
3612
3741
  const { channel_id, style } = props;
3613
3742
  const { channels, hooks } = useGlobalData();
3614
3743
  const channel = channels.find((u) => u.id === channel_id || u.name === channel_id);
3615
3744
  const label = (channel == null ? void 0 : channel.name) || channel_id;
3616
3745
  if (hooks.channel)
3617
- return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_jsx_runtime32.Fragment, { children: hooks.channel(channel || { id: channel_id, name: label }) });
3618
- return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
3746
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_jsx_runtime33.Fragment, { children: hooks.channel(channel || { id: channel_id, name: label }) });
3747
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(
3619
3748
  "span",
3620
3749
  {
3621
3750
  "data-channel-id": (channel == null ? void 0 : channel.id) || channel_id,
@@ -3635,23 +3764,29 @@ var RichTextSectionChannel = (props) => {
3635
3764
  };
3636
3765
 
3637
3766
  // src/components/blocks/rich_text/rich_text_section_emoji.tsx
3638
- var import_jsx_runtime33 = require("react/jsx-runtime");
3767
+ var import_jsx_runtime34 = require("react/jsx-runtime");
3639
3768
  var RichTextSectionEmoji = (props) => {
3640
3769
  const { name } = props;
3641
3770
  const { hooks } = useGlobalData();
3642
- return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("span", { className: "slack_blocks_to_jsx__rich_text_section_element_emoji", children: hooks.emoji ? hooks.emoji(name) : parseEmojis(`:${name}:`) });
3771
+ if (hooks.emoji) {
3772
+ const custom_emoji = hooks.emoji(name);
3773
+ if (custom_emoji !== "fallback") {
3774
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { className: "slack_blocks_to_jsx__rich_text_section_element_emoji", children: custom_emoji });
3775
+ }
3776
+ }
3777
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("span", { className: "slack_blocks_to_jsx__rich_text_section_element_emoji", children: parseEmojis(`:${name}:`) });
3643
3778
  };
3644
3779
 
3645
3780
  // src/components/blocks/rich_text/rich_text_section_user.tsx
3646
- var import_jsx_runtime34 = require("react/jsx-runtime");
3781
+ var import_jsx_runtime35 = require("react/jsx-runtime");
3647
3782
  var RichTextSectionUser = (props) => {
3648
3783
  const { user_id, style } = props;
3649
3784
  const { users, hooks } = useGlobalData();
3650
3785
  const user = users.find((u) => u.id === user_id || u.name === user_id);
3651
3786
  const label = (user == null ? void 0 : user.name) || user_id;
3652
3787
  if (hooks.user)
3653
- return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(import_jsx_runtime34.Fragment, { children: hooks.user(user || { id: user_id, name: label }) });
3654
- return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(
3788
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_jsx_runtime35.Fragment, { children: hooks.user(user || { id: user_id, name: label }) });
3789
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
3655
3790
  "span",
3656
3791
  {
3657
3792
  "data-user-id": (user == null ? void 0 : user.id) || user_id,
@@ -3671,15 +3806,15 @@ var RichTextSectionUser = (props) => {
3671
3806
  };
3672
3807
 
3673
3808
  // src/components/blocks/rich_text/rich_text_section_user_group.tsx
3674
- var import_jsx_runtime35 = require("react/jsx-runtime");
3809
+ var import_jsx_runtime36 = require("react/jsx-runtime");
3675
3810
  var RichTextSectionUserGroup = (props) => {
3676
3811
  const { usergroup_id, style } = props;
3677
3812
  const { user_groups, hooks } = useGlobalData();
3678
3813
  const group = user_groups.find((u) => u.id === usergroup_id || u.name === usergroup_id);
3679
3814
  const label = (group == null ? void 0 : group.name) || usergroup_id;
3680
3815
  if (hooks.usergroup)
3681
- return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_jsx_runtime35.Fragment, { children: hooks.usergroup(group || { id: usergroup_id, name: label }) });
3682
- return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
3816
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(import_jsx_runtime36.Fragment, { children: hooks.usergroup(group || { id: usergroup_id, name: label }) });
3817
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(
3683
3818
  "span",
3684
3819
  {
3685
3820
  "data-usergroup-id": (group == null ? void 0 : group.id) || usergroup_id,
@@ -3699,22 +3834,22 @@ var RichTextSectionUserGroup = (props) => {
3699
3834
  };
3700
3835
 
3701
3836
  // src/components/blocks/rich_text/rich_text_section.tsx
3702
- var import_jsx_runtime36 = require("react/jsx-runtime");
3837
+ var import_jsx_runtime37 = require("react/jsx-runtime");
3703
3838
  var RichTextSectionElement = (props) => {
3704
3839
  const { element } = props;
3705
3840
  if (element.type === "user")
3706
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(RichTextSectionUser, __spreadValues({}, element));
3841
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(RichTextSectionUser, __spreadValues({}, element));
3707
3842
  if (element.type === "channel")
3708
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(RichTextSectionChannel, __spreadValues({}, element));
3843
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(RichTextSectionChannel, __spreadValues({}, element));
3709
3844
  if (element.type === "broadcast")
3710
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(RichTextSectionBroadcast, __spreadValues({}, element));
3845
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(RichTextSectionBroadcast, __spreadValues({}, element));
3711
3846
  if (element.type === "emoji")
3712
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(RichTextSectionEmoji, __spreadValues({}, element));
3847
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(RichTextSectionEmoji, __spreadValues({}, element));
3713
3848
  if (element.type === "usergroup")
3714
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(RichTextSectionUserGroup, __spreadValues({}, element));
3849
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(RichTextSectionUserGroup, __spreadValues({}, element));
3715
3850
  if (element.type === "text") {
3716
3851
  const { text, style } = element;
3717
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
3852
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
3718
3853
  "span",
3719
3854
  {
3720
3855
  className: `
@@ -3730,7 +3865,7 @@ var RichTextSectionElement = (props) => {
3730
3865
  }
3731
3866
  if (element.type === "link") {
3732
3867
  const { url, style, text } = element;
3733
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
3868
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
3734
3869
  "a",
3735
3870
  {
3736
3871
  target: "_blank",
@@ -3750,7 +3885,7 @@ var RichTextSectionElement = (props) => {
3750
3885
  }
3751
3886
  if (element.type === "date") {
3752
3887
  const { timestamp, format, style } = element;
3753
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
3888
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
3754
3889
  "span",
3755
3890
  {
3756
3891
  className: `
@@ -3760,7 +3895,7 @@ var RichTextSectionElement = (props) => {
3760
3895
  ${(style == null ? void 0 : style.code) ? "slack_inline_code" : ""}
3761
3896
  ${(style == null ? void 0 : style.bold) ? "font-medium" : ""}
3762
3897
  `,
3763
- children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
3898
+ children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
3764
3899
  SlackDate,
3765
3900
  {
3766
3901
  element: {
@@ -3781,21 +3916,21 @@ var RichTextSectionElement = (props) => {
3781
3916
  };
3782
3917
 
3783
3918
  // src/components/blocks/rich_text/rich_text.tsx
3784
- var import_jsx_runtime37 = require("react/jsx-runtime");
3919
+ var import_jsx_runtime38 = require("react/jsx-runtime");
3785
3920
  var RichText = (props) => {
3786
3921
  const { elements, block_id } = props.data;
3787
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { id: block_id, className: "slack_blocks_to_jsx__rich_text", children: elements.map((element, i) => {
3788
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Element, { element }, `${element.type}__${i}`);
3922
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("div", { id: block_id, className: "slack_blocks_to_jsx__rich_text", children: elements.map((element, i) => {
3923
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(Element, { element }, `${element.type}__${i}`);
3789
3924
  }) });
3790
3925
  };
3791
3926
  var Element = (props) => {
3792
3927
  const { element } = props;
3793
3928
  if (element.type === "rich_text_list") {
3794
3929
  const { elements, style, border = 0, indent, offset } = element;
3795
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("div", { className: "flex gap-2 slack_blocks_to_jsx__rich_text_list_element", children: [
3796
- border === 1 && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { className: "w-1 rounded bg-gray-primary self-stretch" }),
3797
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(RichTextListWrapper, { element, className: `list-none`, children: elements.map((el, i) => {
3798
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
3930
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("div", { className: "flex gap-2 slack_blocks_to_jsx__rich_text_list_element", children: [
3931
+ border === 1 && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("div", { className: "w-1 rounded bg-gray-primary self-stretch" }),
3932
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(RichTextListWrapper, { element, className: `list-none`, children: elements.map((el, i) => {
3933
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(
3799
3934
  "li",
3800
3935
  {
3801
3936
  className: "flex",
@@ -3803,22 +3938,22 @@ var Element = (props) => {
3803
3938
  marginLeft: indent ? indent > 5 ? 0 : indent * 28 + 6 + 28 : 0
3804
3939
  },
3805
3940
  children: [
3806
- style === "ordered" && /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("span", { className: "w-[22px] h-[22px] shrink-0 flex items-center justify-center", children: [
3941
+ style === "ordered" && /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("span", { className: "w-[22px] h-[22px] shrink-0 flex items-center justify-center", children: [
3807
3942
  i + 1,
3808
3943
  "."
3809
3944
  ] }),
3810
- style === "bullet" && /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("span", { className: "w-[22px] h-[22px] shrink-0 flex items-center justify-center", children: [
3811
- (indent === void 0 || indent === 0 || indent === 3 || indent === 6) && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "w-1.5 h-1.5 rounded-full bg-current" }),
3812
- (indent === 1 || indent === 4 || indent === 7) && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "w-1.5 h-1.5 rounded-full border border-current" }),
3813
- (indent === 2 || indent === 5 || indent === 8) && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "w-1.5 h-1.5 rounded-[1.5px] bg-current" })
3945
+ style === "bullet" && /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("span", { className: "w-[22px] h-[22px] shrink-0 flex items-center justify-center", children: [
3946
+ (indent === void 0 || indent === 0 || indent === 3 || indent === 6) && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "w-1.5 h-1.5 rounded-full bg-current" }),
3947
+ (indent === 1 || indent === 4 || indent === 7) && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "w-1.5 h-1.5 rounded-full border border-current" }),
3948
+ (indent === 2 || indent === 5 || indent === 8) && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "w-1.5 h-1.5 rounded-[1.5px] bg-current" })
3814
3949
  ] }),
3815
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
3950
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
3816
3951
  "div",
3817
3952
  {
3818
3953
  style: {
3819
3954
  marginLeft: 6
3820
3955
  },
3821
- children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Element, { element: el }, `${element.type}__${i}`)
3956
+ children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(Element, { element: el }, `${element.type}__${i}`)
3822
3957
  }
3823
3958
  )
3824
3959
  ]
@@ -3830,9 +3965,9 @@ var Element = (props) => {
3830
3965
  }
3831
3966
  if (element.type === "rich_text_preformatted") {
3832
3967
  const { elements, border } = element;
3833
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("code", { className: "flex gap-2 w-full slack_blocks_to_jsx__rich_text_preformatted_element", children: [
3834
- border === 1 && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { className: "w-1 rounded bg-gray-primary self-stretch" }),
3835
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
3968
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("code", { className: "flex gap-2 w-full slack_blocks_to_jsx__rich_text_preformatted_element", children: [
3969
+ border === 1 && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("div", { className: "w-1 rounded bg-gray-primary self-stretch" }),
3970
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
3836
3971
  "pre",
3837
3972
  {
3838
3973
  className: "p-2 rounded my-1 whitespace-pre-wrap bg-gray-secondary text-xs leading-[1.50001] border grow",
@@ -3841,7 +3976,7 @@ var Element = (props) => {
3841
3976
  wordBreak: "normal"
3842
3977
  },
3843
3978
  children: elements.map((el, i) => {
3844
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(RichTextSectionElement, { element: el }, `${el.type}__${i}`);
3979
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(RichTextSectionElement, { element: el }, `${el.type}__${i}`);
3845
3980
  })
3846
3981
  }
3847
3982
  )
@@ -3849,41 +3984,41 @@ var Element = (props) => {
3849
3984
  }
3850
3985
  if (element.type === "rich_text_quote") {
3851
3986
  const { elements, border } = element;
3852
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("blockquote", { className: "flex gap-2 slack_blocks_to_jsx__rich_text_quote_element", children: [
3853
- border === 1 && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { className: "w-1 rounded bg-gray-primary self-stretch" }),
3987
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("blockquote", { className: "flex gap-2 slack_blocks_to_jsx__rich_text_quote_element", children: [
3988
+ border === 1 && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("div", { className: "w-1 rounded bg-gray-primary self-stretch" }),
3854
3989
  elements.map((el, i) => {
3855
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(RichTextSectionElement, { element: el }, `${el.type}__${i}`);
3990
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(RichTextSectionElement, { element: el }, `${el.type}__${i}`);
3856
3991
  })
3857
3992
  ] });
3858
3993
  }
3859
3994
  if (element.type === "rich_text_section") {
3860
3995
  const { elements } = element;
3861
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { className: "inline-block slack_blocks_to_jsx__rich_text_section_element", children: elements.map((el, i) => {
3862
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(RichTextSectionElement, { element: el }, `${el.type}__${i}`);
3996
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("div", { className: "inline-block slack_blocks_to_jsx__rich_text_section_element", children: elements.map((el, i) => {
3997
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(RichTextSectionElement, { element: el }, `${el.type}__${i}`);
3863
3998
  }) });
3864
3999
  }
3865
4000
  return null;
3866
4001
  };
3867
4002
 
3868
4003
  // src/components/blocks/section.tsx
3869
- var import_jsx_runtime38 = require("react/jsx-runtime");
4004
+ var import_jsx_runtime39 = require("react/jsx-runtime");
3870
4005
  var Section = (props) => {
3871
4006
  const { accessory, fields, text, block_id } = props.data;
3872
4007
  const element = accessory ? getElementComponent(accessory) : null;
3873
4008
  const is_stacked = accessory ? is_accessory_stacked(accessory) : false;
3874
- return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(
4009
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
3875
4010
  "div",
3876
4011
  {
3877
4012
  id: block_id,
3878
4013
  className: `mt-2 mb-1 text-primary slack_blocks_to_jsx__section flex w-full text-black-primary ${is_stacked ? "flex-col" : ""}`,
3879
4014
  children: [
3880
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("div", { className: "grow", children: /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("div", { className: "flex flex-col gap-3", children: [
3881
- text && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(TextObject, { data: text }),
3882
- fields && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("div", { className: "grid grid-col-2 w-full", children: fields.map((field, i) => {
3883
- return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(TextObject, { data: field }, i);
4015
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: "grow", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("div", { className: "flex flex-col gap-3", children: [
4016
+ text && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(TextObject, { data: text }),
4017
+ fields && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: "grid grid-col-2 w-full", children: fields.map((field, i) => {
4018
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(TextObject, { data: field }, i);
3884
4019
  }) })
3885
4020
  ] }) }),
3886
- element && is_stacked ? element : /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("div", { className: "ml-2 mb-1 relative shrink-0", children: element })
4021
+ element && is_stacked ? element : /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: "ml-2 mb-1 relative shrink-0", children: element })
3887
4022
  ]
3888
4023
  }
3889
4024
  );
@@ -3891,7 +4026,7 @@ var Section = (props) => {
3891
4026
 
3892
4027
  // src/components/blocks/video.tsx
3893
4028
  var import_react6 = require("react");
3894
- var import_jsx_runtime39 = require("react/jsx-runtime");
4029
+ var import_jsx_runtime40 = require("react/jsx-runtime");
3895
4030
  var Video = (props) => {
3896
4031
  const {
3897
4032
  alt_text,
@@ -3904,18 +4039,18 @@ var Video = (props) => {
3904
4039
  iframeProps = {}
3905
4040
  } = props.data;
3906
4041
  const [showVideo, setShowVideo] = (0, import_react6.useState)(true);
3907
- return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("div", { className: "py-2 slack_blocks_to_jsx__video", id: block_id, children: [
3908
- author_name && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: "slack_blocks_to_jsx__video_author", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "font-bold", children: author_name }) }),
3909
- description && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: "slack_blocks_to_jsx__video_description", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(TextObject, { data: description }) }),
3910
- /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("div", { className: "flex flex-wrap items-center gap-1 slack_blocks_to_jsx__video_title", children: [
3911
- title_url ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("a", { href: title_url, className: "text-blue-primary", target: "_blank", rel: "noreferrer", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(TextObject, { data: title }) }) : /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("p", { children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(TextObject, { data: title }) }),
3912
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4042
+ return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: "py-2 slack_blocks_to_jsx__video", id: block_id, children: [
4043
+ author_name && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("div", { className: "slack_blocks_to_jsx__video_author", children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("span", { className: "font-bold", children: author_name }) }),
4044
+ description && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("div", { className: "slack_blocks_to_jsx__video_description", children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(TextObject, { data: description }) }),
4045
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("div", { className: "flex flex-wrap items-center gap-1 slack_blocks_to_jsx__video_title", children: [
4046
+ title_url ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("a", { href: title_url, className: "text-blue-primary", target: "_blank", rel: "noreferrer", children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(TextObject, { data: title }) }) : /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("p", { children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(TextObject, { data: title }) }),
4047
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
3913
4048
  "button",
3914
4049
  {
3915
4050
  type: "button",
3916
4051
  className: "w-[15px] h-[15px]",
3917
4052
  onClick: () => setShowVideo((prev) => !prev),
3918
- children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4053
+ children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
3919
4054
  "svg",
3920
4055
  {
3921
4056
  xmlns: "http://www.w3.org/2000/svg",
@@ -3931,7 +4066,7 @@ var Video = (props) => {
3931
4066
  style: {
3932
4067
  transform: showVideo ? "rotate(0deg)" : "rotate(-90deg)"
3933
4068
  },
3934
- children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4069
+ children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
3935
4070
  "path",
3936
4071
  {
3937
4072
  fill: "currentColor",
@@ -3944,7 +4079,7 @@ var Video = (props) => {
3944
4079
  }
3945
4080
  )
3946
4081
  ] }),
3947
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: "slack_blocks_to_jsx__video_container max-w-max", children: showVideo && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4082
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("div", { className: "slack_blocks_to_jsx__video_container max-w-max", children: showVideo && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
3948
4083
  "iframe",
3949
4084
  __spreadValues({
3950
4085
  title: alt_text,
@@ -3956,41 +4091,41 @@ var Video = (props) => {
3956
4091
  };
3957
4092
 
3958
4093
  // src/components/index.tsx
3959
- var import_jsx_runtime40 = require("react/jsx-runtime");
4094
+ var import_jsx_runtime41 = require("react/jsx-runtime");
3960
4095
  var getBlockComponent = (block) => {
3961
4096
  if (block.type === "divider")
3962
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Divider, { data: block });
4097
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Divider, { data: block });
3963
4098
  if (block.type === "section")
3964
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Section, { data: block });
4099
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Section, { data: block });
3965
4100
  if (block.type === "image")
3966
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Image, { data: block });
4101
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Image, { data: block });
3967
4102
  if (block.type === "context")
3968
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Context, { data: block });
4103
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Context, { data: block });
3969
4104
  if (block.type === "actions")
3970
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Actions, { data: block });
4105
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Actions, { data: block });
3971
4106
  if (block.type === "file")
3972
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(File, { data: block });
4107
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(File, { data: block });
3973
4108
  if (block.type === "header")
3974
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Header2, { data: block });
4109
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Header2, { data: block });
3975
4110
  if (block.type === "input")
3976
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Input, { data: block });
4111
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Input, { data: block });
3977
4112
  if (block.type === "video")
3978
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Video, { data: block });
4113
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Video, { data: block });
3979
4114
  if (block.type === "rich_text")
3980
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(RichText, { data: block });
4115
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(RichText, { data: block });
3981
4116
  return null;
3982
4117
  };
3983
4118
  var getElementComponent = (element) => {
3984
4119
  if (element.type === "button")
3985
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(ButtonElement, { data: element });
4120
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(ButtonElement, { data: element });
3986
4121
  if (element.type === "checkboxes")
3987
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(CheckboxesElement, { data: element });
4122
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(CheckboxesElement, { data: element });
3988
4123
  if (element.type === "image")
3989
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(ImageElement, { data: element });
4124
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(ImageElement, { data: element });
3990
4125
  if (element.type === "plain_text_input")
3991
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(PlaintTextInput, { data: element });
4126
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(PlaintTextInput, { data: element });
3992
4127
  if (element.type === "users_select")
3993
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(UsersSelectElement, { data: element });
4128
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(UsersSelectElement, { data: element });
3994
4129
  if (element.type === "datepicker")
3995
4130
  return null;
3996
4131
  if (element.type === "datetimepicker")
@@ -4029,15 +4164,15 @@ var getElementComponent = (element) => {
4029
4164
  };
4030
4165
 
4031
4166
  // src/block_wrapper.tsx
4032
- var import_jsx_runtime41 = require("react/jsx-runtime");
4167
+ var import_jsx_runtime42 = require("react/jsx-runtime");
4033
4168
  var BlockWrapper = (props) => {
4034
4169
  const { children } = props;
4035
- return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("div", { className: "text-base slack_blocks_to_jsx--block_wrapper break-words font-normal", children });
4170
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: "text-base slack_blocks_to_jsx--block_wrapper break-words font-normal", children });
4036
4171
  };
4037
4172
 
4038
4173
  // src/message.tsx
4039
4174
  var import_react7 = require("react");
4040
- var import_jsx_runtime42 = require("react/jsx-runtime");
4175
+ var import_jsx_runtime43 = require("react/jsx-runtime");
4041
4176
  var Message = (props) => {
4042
4177
  const {
4043
4178
  blocks,
@@ -4064,7 +4199,7 @@ var Message = (props) => {
4064
4199
  setHooks(hooks);
4065
4200
  }, [data, hooks]);
4066
4201
  if (withoutWrapper) {
4067
- return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
4202
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
4068
4203
  "div",
4069
4204
  {
4070
4205
  id: "slack_blocks_to_jsx",
@@ -4074,18 +4209,18 @@ var Message = (props) => {
4074
4209
  const element = getBlockComponent(block);
4075
4210
  if (!element)
4076
4211
  return null;
4077
- return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(BlockWrapper, { children: element }, i);
4212
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(BlockWrapper, { children: element }, i);
4078
4213
  })
4079
4214
  }
4080
4215
  );
4081
4216
  }
4082
- return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { id: "slack_blocks_to_jsx", children: /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
4217
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { id: "slack_blocks_to_jsx", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
4083
4218
  "section",
4084
4219
  {
4085
4220
  className: `flex gap-2 w-full max-w-[600px] slack_blocks_to_jsx relative ${unstyled ? "styles_disabled" : "styles_enabled"} ${className}`,
4086
4221
  style,
4087
4222
  children: [
4088
- showBlockKitDebug && /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
4223
+ showBlockKitDebug && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
4089
4224
  "a",
4090
4225
  {
4091
4226
  target: "_blank",
@@ -4097,14 +4232,14 @@ var Message = (props) => {
4097
4232
  children: "Open in Slack Block Kit Builder"
4098
4233
  }
4099
4234
  ),
4100
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: "shrink-0", children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("img", { src: logo, className: "w-9 h-9", alt: name }) }),
4101
- /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("div", { className: "flex flex-col w-full", children: [
4102
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(Header, { name, time }),
4103
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: "slack_blocks_to_jsx--blocks", children: blocks.map((block, i) => {
4235
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: "shrink-0", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("img", { src: logo, className: "w-9 h-9", alt: name }) }),
4236
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "flex flex-col w-full", children: [
4237
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(Header, { name, time }),
4238
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className: "slack_blocks_to_jsx--blocks", children: blocks.map((block, i) => {
4104
4239
  const element = getBlockComponent(block);
4105
4240
  if (!element)
4106
4241
  return null;
4107
- return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(BlockWrapper, { children: element }, i);
4242
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(BlockWrapper, { children: element }, i);
4108
4243
  }) })
4109
4244
  ] })
4110
4245
  ]