@industry-theme/github-panels 0.1.66 → 0.1.67

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":"RecentRepositoriesPanel.d.ts","sourceRoot":"","sources":["../../src/panels/RecentRepositoriesPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA2C,MAAM,OAAO,CAAC;AAgBhE,OAAO,KAAK,EACV,gBAAgB,EAEhB,4BAA4B,EAC7B,MAAM,iBAAiB,CAAC;AAsGzB;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,gBAAgB,GAAG,IAAI,CAgChE;AAED;;GAEG;AACH,MAAM,WAAW,SAAS;IACxB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,GAAG,cAAc,CAAC;IAC9B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,SAAS,GAAG,IAAI,CA4BrD;AA2pBD;;;;;;;;;;GAUG;AACH,eAAO,MAAM,uBAAuB,EAAE,KAAK,CAAC,EAAE,CAAC,4BAA4B,GAAG;IAC5E,UAAU,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;CACrC,CAEA,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,+BAA+B;;;;;;;;CAQ3C,CAAC"}
1
+ {"version":3,"file":"RecentRepositoriesPanel.d.ts","sourceRoot":"","sources":["../../src/panels/RecentRepositoriesPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA2C,MAAM,OAAO,CAAC;AAgBhE,OAAO,KAAK,EACV,gBAAgB,EAEhB,4BAA4B,EAC7B,MAAM,iBAAiB,CAAC;AAsGzB;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,gBAAgB,GAAG,IAAI,CAsChE;AAED;;GAEG;AACH,MAAM,WAAW,SAAS;IACxB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,GAAG,cAAc,CAAC;IAC9B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,SAAS,GAAG,IAAI,CAkCrD;AA4pBD;;;;;;;;;;GAUG;AACH,eAAO,MAAM,uBAAuB,EAAE,KAAK,CAAC,EAAE,CAAC,4BAA4B,GAAG;IAC5E,UAAU,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;CACrC,CAEA,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,+BAA+B;;;;;;;;CAQ3C,CAAC"}
@@ -53099,6 +53099,10 @@ function saveRecentOwners(owners) {
53099
53099
  }
53100
53100
  }
53101
53101
  function addRecentRepository(repo) {
53102
+ if (repo.id == null) {
53103
+ console.warn("addRecentRepository: skipping repository without valid id", repo.full_name);
53104
+ return;
53105
+ }
53102
53106
  const recent = loadRecentRepositories();
53103
53107
  const filtered = recent.filter((r2) => r2.id !== repo.id);
53104
53108
  const newEntry = {
@@ -53124,6 +53128,10 @@ function addRecentRepository(repo) {
53124
53128
  }
53125
53129
  }
53126
53130
  function addRecentOwner(owner) {
53131
+ if (owner.id == null) {
53132
+ console.warn("addRecentOwner: skipping owner without valid id", owner.login);
53133
+ return;
53134
+ }
53127
53135
  const recent = loadRecentOwners();
53128
53136
  const filtered = recent.filter((o) => o.id !== owner.id);
53129
53137
  const newEntry = {
@@ -53158,8 +53166,8 @@ const RecentRepositoriesPanelContent = ({
53158
53166
  };
53159
53167
  useEffect(() => {
53160
53168
  const loadItems = () => {
53161
- const repos = loadRecentRepositories();
53162
- const owners = loadRecentOwners();
53169
+ const repos = loadRecentRepositories().filter((r2) => r2.id != null);
53170
+ const owners = loadRecentOwners().filter((o) => o.id != null);
53163
53171
  const merged = [...repos, ...owners].sort(
53164
53172
  (a, b) => b.visitedAt - a.visitedAt
53165
53173
  );