@industry-theme/github-panels 0.1.30 → 0.1.31

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.
@@ -1 +1 @@
1
- {"version":3,"file":"OwnerRepositoriesPanel.d.ts","sourceRoot":"","sources":["../../src/panels/OwnerRepositoriesPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA2C,MAAM,OAAO,CAAC;AAgBhE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AA0mBpD;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,sBAAsB,EAAE,KAAK,CAAC,EAAE,CAAC,mBAAmB,GAAG;IAAE,KAAK,CAAC,EAAE,MAAM,CAAA;CAAE,CAErF,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,8BAA8B;;;;;;;;CAQ1C,CAAC"}
1
+ {"version":3,"file":"OwnerRepositoriesPanel.d.ts","sourceRoot":"","sources":["../../src/panels/OwnerRepositoriesPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA2C,MAAM,OAAO,CAAC;AAahE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AA6iBpD;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,sBAAsB,EAAE,KAAK,CAAC,EAAE,CAAC,mBAAmB,GAAG;IAAE,KAAK,CAAC,EAAE,MAAM,CAAA;CAAE,CAErF,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,8BAA8B;;;;;;;;CAQ1C,CAAC"}
@@ -1,4 +1,4 @@
1
- import { jsxs, jsx, Fragment } from "react/jsx-runtime";
1
+ import { jsxs, jsx } from "react/jsx-runtime";
2
2
  import React2, { createContext, useContext, forwardRef, createElement, useState, useRef, useEffect, useCallback, useMemo } from "react";
3
3
  var ThemeContext;
4
4
  var getThemeContext = () => {
@@ -128,31 +128,31 @@ const createLucideIcon = (iconName, iconNode) => {
128
128
  * This source code is licensed under the ISC license.
129
129
  * See the LICENSE file in the root directory of this source tree.
130
130
  */
131
- const __iconNode$n = [
131
+ const __iconNode$m = [
132
132
  ["path", { d: "M5 12h14", key: "1ays0h" }],
133
133
  ["path", { d: "m12 5 7 7-7 7", key: "xquz4c" }]
134
134
  ];
135
- const ArrowRight = createLucideIcon("arrow-right", __iconNode$n);
135
+ const ArrowRight = createLucideIcon("arrow-right", __iconNode$m);
136
136
  /**
137
137
  * @license lucide-react v0.552.0 - ISC
138
138
  *
139
139
  * This source code is licensed under the ISC license.
140
140
  * See the LICENSE file in the root directory of this source tree.
141
141
  */
142
- const __iconNode$m = [
142
+ const __iconNode$l = [
143
143
  ["path", { d: "m21 16-4 4-4-4", key: "f6ql7i" }],
144
144
  ["path", { d: "M17 20V4", key: "1ejh1v" }],
145
145
  ["path", { d: "m3 8 4-4 4 4", key: "11wl7u" }],
146
146
  ["path", { d: "M7 4v16", key: "1glfcx" }]
147
147
  ];
148
- const ArrowUpDown = createLucideIcon("arrow-up-down", __iconNode$m);
148
+ const ArrowUpDown = createLucideIcon("arrow-up-down", __iconNode$l);
149
149
  /**
150
150
  * @license lucide-react v0.552.0 - ISC
151
151
  *
152
152
  * This source code is licensed under the ISC license.
153
153
  * See the LICENSE file in the root directory of this source tree.
154
154
  */
155
- const __iconNode$l = [
155
+ const __iconNode$k = [
156
156
  ["path", { d: "M12 7v14", key: "1akyts" }],
157
157
  [
158
158
  "path",
@@ -162,14 +162,14 @@ const __iconNode$l = [
162
162
  }
163
163
  ]
164
164
  ];
165
- const BookOpen = createLucideIcon("book-open", __iconNode$l);
165
+ const BookOpen = createLucideIcon("book-open", __iconNode$k);
166
166
  /**
167
167
  * @license lucide-react v0.552.0 - ISC
168
168
  *
169
169
  * This source code is licensed under the ISC license.
170
170
  * See the LICENSE file in the root directory of this source tree.
171
171
  */
172
- const __iconNode$k = [
172
+ const __iconNode$j = [
173
173
  ["path", { d: "M10 12h4", key: "a56b0p" }],
174
174
  ["path", { d: "M10 8h4", key: "1sr2af" }],
175
175
  ["path", { d: "M14 21v-3a2 2 0 0 0-4 0v3", key: "1rgiei" }],
@@ -182,55 +182,55 @@ const __iconNode$k = [
182
182
  ],
183
183
  ["path", { d: "M6 21V5a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v16", key: "16ra0t" }]
184
184
  ];
185
- const Building2 = createLucideIcon("building-2", __iconNode$k);
185
+ const Building2 = createLucideIcon("building-2", __iconNode$j);
186
186
  /**
187
187
  * @license lucide-react v0.552.0 - ISC
188
188
  *
189
189
  * This source code is licensed under the ISC license.
190
190
  * See the LICENSE file in the root directory of this source tree.
191
191
  */
192
- const __iconNode$j = [
192
+ const __iconNode$i = [
193
193
  ["path", { d: "M8 2v4", key: "1cmpym" }],
194
194
  ["path", { d: "M16 2v4", key: "4m81vk" }],
195
195
  ["rect", { width: "18", height: "18", x: "3", y: "4", rx: "2", key: "1hopcy" }],
196
196
  ["path", { d: "M3 10h18", key: "8toen8" }]
197
197
  ];
198
- const Calendar = createLucideIcon("calendar", __iconNode$j);
198
+ const Calendar = createLucideIcon("calendar", __iconNode$i);
199
199
  /**
200
200
  * @license lucide-react v0.552.0 - ISC
201
201
  *
202
202
  * This source code is licensed under the ISC license.
203
203
  * See the LICENSE file in the root directory of this source tree.
204
204
  */
205
- const __iconNode$i = [["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]];
206
- const ChevronDown = createLucideIcon("chevron-down", __iconNode$i);
205
+ const __iconNode$h = [["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]];
206
+ const ChevronDown = createLucideIcon("chevron-down", __iconNode$h);
207
207
  /**
208
208
  * @license lucide-react v0.552.0 - ISC
209
209
  *
210
210
  * This source code is licensed under the ISC license.
211
211
  * See the LICENSE file in the root directory of this source tree.
212
212
  */
213
- const __iconNode$h = [["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]];
214
- const ChevronRight = createLucideIcon("chevron-right", __iconNode$h);
213
+ const __iconNode$g = [["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]];
214
+ const ChevronRight = createLucideIcon("chevron-right", __iconNode$g);
215
215
  /**
216
216
  * @license lucide-react v0.552.0 - ISC
217
217
  *
218
218
  * This source code is licensed under the ISC license.
219
219
  * See the LICENSE file in the root directory of this source tree.
220
220
  */
221
- const __iconNode$g = [
221
+ const __iconNode$f = [
222
222
  ["path", { d: "M15 3h6v6", key: "1q9fwt" }],
223
223
  ["path", { d: "M10 14 21 3", key: "gplh6r" }],
224
224
  ["path", { d: "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6", key: "a6xqqp" }]
225
225
  ];
226
- const ExternalLink = createLucideIcon("external-link", __iconNode$g);
226
+ const ExternalLink = createLucideIcon("external-link", __iconNode$f);
227
227
  /**
228
228
  * @license lucide-react v0.552.0 - ISC
229
229
  *
230
230
  * This source code is licensed under the ISC license.
231
231
  * See the LICENSE file in the root directory of this source tree.
232
232
  */
233
- const __iconNode$f = [
233
+ const __iconNode$e = [
234
234
  [
235
235
  "path",
236
236
  {
@@ -239,14 +239,14 @@ const __iconNode$f = [
239
239
  }
240
240
  ]
241
241
  ];
242
- const Folder = createLucideIcon("folder", __iconNode$f);
242
+ const Folder = createLucideIcon("folder", __iconNode$e);
243
243
  /**
244
244
  * @license lucide-react v0.552.0 - ISC
245
245
  *
246
246
  * This source code is licensed under the ISC license.
247
247
  * See the LICENSE file in the root directory of this source tree.
248
248
  */
249
- const __iconNode$e = [
249
+ const __iconNode$d = [
250
250
  [
251
251
  "path",
252
252
  {
@@ -255,28 +255,28 @@ const __iconNode$e = [
255
255
  }
256
256
  ]
257
257
  ];
258
- const Funnel = createLucideIcon("funnel", __iconNode$e);
258
+ const Funnel = createLucideIcon("funnel", __iconNode$d);
259
259
  /**
260
260
  * @license lucide-react v0.552.0 - ISC
261
261
  *
262
262
  * This source code is licensed under the ISC license.
263
263
  * See the LICENSE file in the root directory of this source tree.
264
264
  */
265
- const __iconNode$d = [
265
+ const __iconNode$c = [
266
266
  ["circle", { cx: "12", cy: "18", r: "3", key: "1mpf1b" }],
267
267
  ["circle", { cx: "6", cy: "6", r: "3", key: "1lh9wr" }],
268
268
  ["circle", { cx: "18", cy: "6", r: "3", key: "1h7g24" }],
269
269
  ["path", { d: "M18 9v2c0 .6-.4 1-1 1H7c-.6 0-1-.4-1-1V9", key: "1uq4wg" }],
270
270
  ["path", { d: "M12 12v3", key: "158kv8" }]
271
271
  ];
272
- const GitFork = createLucideIcon("git-fork", __iconNode$d);
272
+ const GitFork = createLucideIcon("git-fork", __iconNode$c);
273
273
  /**
274
274
  * @license lucide-react v0.552.0 - ISC
275
275
  *
276
276
  * This source code is licensed under the ISC license.
277
277
  * See the LICENSE file in the root directory of this source tree.
278
278
  */
279
- const __iconNode$c = [
279
+ const __iconNode$b = [
280
280
  [
281
281
  "path",
282
282
  {
@@ -286,69 +286,56 @@ const __iconNode$c = [
286
286
  ],
287
287
  ["path", { d: "M9 18c-4.51 2-5-2-7-2", key: "9comsn" }]
288
288
  ];
289
- const Github = createLucideIcon("github", __iconNode$c);
289
+ const Github = createLucideIcon("github", __iconNode$b);
290
290
  /**
291
291
  * @license lucide-react v0.552.0 - ISC
292
292
  *
293
293
  * This source code is licensed under the ISC license.
294
294
  * See the LICENSE file in the root directory of this source tree.
295
295
  */
296
- const __iconNode$b = [
296
+ const __iconNode$a = [
297
297
  ["path", { d: "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8", key: "1357e3" }],
298
298
  ["path", { d: "M3 3v5h5", key: "1xhq8a" }],
299
299
  ["path", { d: "M12 7v5l4 2", key: "1fdv2h" }]
300
300
  ];
301
- const History = createLucideIcon("history", __iconNode$b);
301
+ const History = createLucideIcon("history", __iconNode$a);
302
302
  /**
303
303
  * @license lucide-react v0.552.0 - ISC
304
304
  *
305
305
  * This source code is licensed under the ISC license.
306
306
  * See the LICENSE file in the root directory of this source tree.
307
307
  */
308
- const __iconNode$a = [
308
+ const __iconNode$9 = [
309
309
  ["rect", { width: "18", height: "11", x: "3", y: "11", rx: "2", ry: "2", key: "1w4ew1" }],
310
310
  ["path", { d: "M7 11V7a5 5 0 0 1 10 0v4", key: "fwvmzm" }]
311
311
  ];
312
- const Lock = createLucideIcon("lock", __iconNode$a);
312
+ const Lock = createLucideIcon("lock", __iconNode$9);
313
313
  /**
314
314
  * @license lucide-react v0.552.0 - ISC
315
315
  *
316
316
  * This source code is licensed under the ISC license.
317
317
  * See the LICENSE file in the root directory of this source tree.
318
318
  */
319
- const __iconNode$9 = [
319
+ const __iconNode$8 = [
320
320
  ["path", { d: "m10 17 5-5-5-5", key: "1bsop3" }],
321
321
  ["path", { d: "M15 12H3", key: "6jk70r" }],
322
322
  ["path", { d: "M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4", key: "u53s6r" }]
323
323
  ];
324
- const LogIn = createLucideIcon("log-in", __iconNode$9);
324
+ const LogIn = createLucideIcon("log-in", __iconNode$8);
325
325
  /**
326
326
  * @license lucide-react v0.552.0 - ISC
327
327
  *
328
328
  * This source code is licensed under the ISC license.
329
329
  * See the LICENSE file in the root directory of this source tree.
330
330
  */
331
- const __iconNode$8 = [
331
+ const __iconNode$7 = [
332
332
  ["rect", { x: "16", y: "16", width: "6", height: "6", rx: "1", key: "4q2zg0" }],
333
333
  ["rect", { x: "2", y: "16", width: "6", height: "6", rx: "1", key: "8cvhb9" }],
334
334
  ["rect", { x: "9", y: "2", width: "6", height: "6", rx: "1", key: "1egb70" }],
335
335
  ["path", { d: "M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3", key: "1jsf9p" }],
336
336
  ["path", { d: "M12 12V8", key: "2874zd" }]
337
337
  ];
338
- const Network = createLucideIcon("network", __iconNode$8);
339
- /**
340
- * @license lucide-react v0.552.0 - ISC
341
- *
342
- * This source code is licensed under the ISC license.
343
- * See the LICENSE file in the root directory of this source tree.
344
- */
345
- const __iconNode$7 = [
346
- ["path", { d: "M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8", key: "v9h5vc" }],
347
- ["path", { d: "M21 3v5h-5", key: "1q7to0" }],
348
- ["path", { d: "M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16", key: "3uifl3" }],
349
- ["path", { d: "M8 16H3v5", key: "1cv678" }]
350
- ];
351
- const RefreshCw = createLucideIcon("refresh-cw", __iconNode$7);
338
+ const Network = createLucideIcon("network", __iconNode$7);
352
339
  /**
353
340
  * @license lucide-react v0.552.0 - ISC
354
341
  *
@@ -1549,7 +1536,7 @@ const OwnerRepositoriesPanelContent = ({
1549
1536
  const owner = propOwner || ((_b = (_a = context == null ? void 0 : context.currentScope) == null ? void 0 : _a.repository) == null ? void 0 : _b.name);
1550
1537
  const ownerSlice = context.getSlice("owner-repositories");
1551
1538
  const isLoading = context.isSliceLoading("owner-repositories");
1552
- const ownerInfo = ((_c = ownerSlice == null ? void 0 : ownerSlice.data) == null ? void 0 : _c.owner) ?? null;
1539
+ ((_c = ownerSlice == null ? void 0 : ownerSlice.data) == null ? void 0 : _c.owner) ?? null;
1553
1540
  const repositories = ((_d = ownerSlice == null ? void 0 : ownerSlice.data) == null ? void 0 : _d.repositories) ?? [];
1554
1541
  const error = ((_e = ownerSlice == null ? void 0 : ownerSlice.data) == null ? void 0 : _e.error) ?? null;
1555
1542
  ((_f = ownerSlice == null ? void 0 : ownerSlice.data) == null ? void 0 : _f.isAuthenticated) ?? false;
@@ -1660,109 +1647,43 @@ const OwnerRepositoriesPanelContent = ({
1660
1647
  fontFamily: theme.fonts.body
1661
1648
  },
1662
1649
  children: [
1663
- /* @__PURE__ */ jsx(
1650
+ /* @__PURE__ */ jsxs(
1664
1651
  "div",
1665
1652
  {
1666
1653
  style: {
1667
- padding: "16px",
1654
+ padding: "12px 16px",
1668
1655
  borderBottom: `1px solid ${theme.colors.border}`,
1669
1656
  display: "flex",
1670
1657
  alignItems: "center",
1671
- gap: "12px"
1658
+ gap: "8px"
1672
1659
  },
1673
- children: ownerInfo ? /* @__PURE__ */ jsxs(Fragment, { children: [
1674
- /* @__PURE__ */ jsx(
1675
- "img",
1676
- {
1677
- src: ownerInfo.avatar_url,
1678
- alt: ownerInfo.login,
1679
- style: {
1680
- width: 48,
1681
- height: 48,
1682
- borderRadius: ownerInfo.type === "Organization" ? 8 : "50%",
1683
- border: `2px solid ${theme.colors.border}`
1684
- }
1685
- }
1686
- ),
1687
- /* @__PURE__ */ jsxs("div", { style: { flex: 1 }, children: [
1688
- /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", gap: "8px" }, children: [
1689
- /* @__PURE__ */ jsx(
1690
- "h2",
1691
- {
1692
- style: {
1693
- margin: 0,
1694
- fontSize: `${theme.fontSizes[4]}px`,
1695
- fontWeight: theme.fontWeights.bold
1696
- },
1697
- children: ownerInfo.name || ownerInfo.login
1698
- }
1699
- ),
1700
- ownerInfo.type === "Organization" ? /* @__PURE__ */ jsx(Building2, { size: 16, color: theme.colors.textSecondary }) : /* @__PURE__ */ jsx(User, { size: 16, color: theme.colors.textSecondary })
1701
- ] }),
1702
- ownerInfo.bio && /* @__PURE__ */ jsx(
1703
- "p",
1704
- {
1705
- style: {
1706
- margin: "4px 0 0",
1707
- fontSize: `${theme.fontSizes[1]}px`,
1708
- color: theme.colors.textSecondary
1709
- },
1710
- children: ownerInfo.bio
1711
- }
1712
- ),
1713
- /* @__PURE__ */ jsxs(
1714
- "div",
1715
- {
1716
- style: {
1717
- display: "flex",
1718
- gap: "12px",
1719
- marginTop: "4px",
1720
- fontSize: `${theme.fontSizes[1]}px`,
1721
- color: theme.colors.textSecondary
1722
- },
1723
- children: [
1724
- /* @__PURE__ */ jsxs("span", { children: [
1725
- repositories.length,
1726
- " repositories"
1727
- ] }),
1728
- ownerInfo.followers !== void 0 && /* @__PURE__ */ jsxs("span", { children: [
1729
- formatNumber(ownerInfo.followers),
1730
- " followers"
1731
- ] })
1732
- ]
1733
- }
1734
- )
1735
- ] }),
1660
+ children: [
1661
+ /* @__PURE__ */ jsx(Github, { size: 18, color: theme.colors.primary }),
1736
1662
  /* @__PURE__ */ jsx(
1737
- "button",
1663
+ "span",
1738
1664
  {
1739
- onClick: handleRefresh,
1740
1665
  style: {
1741
- padding: "8px",
1742
- borderRadius: "6px",
1743
- border: `1px solid ${theme.colors.border}`,
1744
- background: "transparent",
1745
- cursor: "pointer",
1746
- color: theme.colors.textSecondary
1666
+ fontSize: `${theme.fontSizes[2]}px`,
1667
+ fontWeight: theme.fontWeights.medium,
1668
+ color: theme.colors.text
1747
1669
  },
1748
- title: "Refresh",
1749
- children: /* @__PURE__ */ jsx(RefreshCw, { size: 16 })
1670
+ children: "Repositories"
1750
1671
  }
1751
- )
1752
- ] }) : /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", gap: "12px" }, children: [
1753
- /* @__PURE__ */ jsx(Github, { size: 24, color: theme.colors.primary }),
1754
- /* @__PURE__ */ jsx(
1755
- "h2",
1672
+ ),
1673
+ !isLoading && repositories.length > 0 && /* @__PURE__ */ jsx(
1674
+ "span",
1756
1675
  {
1757
1676
  style: {
1758
- margin: 0,
1759
- fontSize: `${theme.fontSizes[3]}px`,
1760
- fontWeight: theme.fontWeights.semibold
1677
+ fontSize: `${theme.fontSizes[1]}px`,
1678
+ color: theme.colors.textSecondary,
1679
+ padding: "2px 8px",
1680
+ borderRadius: "12px",
1681
+ backgroundColor: theme.colors.backgroundSecondary
1761
1682
  },
1762
- children: owner || "Repositories"
1683
+ children: repositories.length
1763
1684
  }
1764
1685
  )
1765
- ] })
1686
+ ]
1766
1687
  }
1767
1688
  ),
1768
1689
  !isLoading && !error && repositories.length > 0 && /* @__PURE__ */ jsxs(