@feedlog-ai/webcomponents 0.0.21 → 0.0.23
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/README.md +12 -12
- package/dist/cjs/{feedlog-button_2.cjs.entry.js → feedlog-button_3.cjs.entry.js} +32 -0
- package/dist/cjs/{feedlog-github-issues-client.cjs.entry.js → feedlog-issues-client.cjs.entry.js} +4 -4
- package/dist/cjs/feedlog-issues.cjs.entry.js +71 -0
- package/dist/cjs/feedlog-toolkit.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/feedlog-issues/feedlog-issues.css +245 -0
- package/dist/collection/components/{feedlog-github-issues/feedlog-github-issues.js → feedlog-issues/feedlog-issues.js} +51 -12
- package/dist/collection/components/{feedlog-github-issues/feedlog-github-issues.stories.js → feedlog-issues/feedlog-issues.stories.js} +32 -18
- package/dist/collection/components/{feedlog-github-issues-client/feedlog-github-issues-client.js → feedlog-issues-client/feedlog-issues-client.js} +46 -8
- package/dist/collection/components/feedlog-issues-list/feedlog-issues-list.css +36 -0
- package/dist/collection/components/feedlog-issues-list/feedlog-issues-list.js +42 -1
- package/dist/collection/components/index.js +2 -2
- package/dist/components/{feedlog-github-issues.d.ts → feedlog-issues-client.d.ts} +4 -4
- package/dist/components/feedlog-issues-client.js +1 -0
- package/dist/components/feedlog-issues-list.js +1 -1
- package/dist/components/feedlog-issues.d.ts +11 -0
- package/dist/components/feedlog-issues.js +1 -0
- package/dist/components/p-BR3ookRG.js +1 -0
- package/dist/components/p-DJOCetIC.js +1 -0
- package/dist/esm/{feedlog-button_2.entry.js → feedlog-button_3.entry.js} +32 -1
- package/dist/esm/{feedlog-github-issues-client.entry.js → feedlog-issues-client.entry.js} +4 -4
- package/dist/esm/feedlog-issues.entry.js +69 -0
- package/dist/esm/feedlog-toolkit.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/feedlog-toolkit/feedlog-toolkit.esm.js +1 -1
- package/dist/feedlog-toolkit/p-4acededf.entry.js +1 -0
- package/dist/feedlog-toolkit/{p-70bf31c4.entry.js → p-6737a3f4.entry.js} +1 -1
- package/dist/feedlog-toolkit/{p-dad7b157.entry.js → p-f8e5e975.entry.js} +2 -2
- package/dist/types/components/{feedlog-github-issues/feedlog-github-issues.d.ts → feedlog-issues/feedlog-issues.d.ts} +13 -4
- package/dist/types/components/{feedlog-github-issues-client/feedlog-github-issues-client.d.ts → feedlog-issues-client/feedlog-issues-client.d.ts} +13 -5
- package/dist/types/components/feedlog-issues-list/feedlog-issues-list.d.ts +9 -0
- package/dist/types/components/index.d.ts +2 -2
- package/dist/types/components.d.ts +172 -124
- package/package.json +2 -2
- package/dist/cjs/feedlog-github-issues.cjs.entry.js +0 -70
- package/dist/cjs/feedlog-issues-list.cjs.entry.js +0 -33
- package/dist/collection/components/feedlog-github-issues/feedlog-github-issues.css +0 -104
- package/dist/components/feedlog-github-issues-client.d.ts +0 -11
- package/dist/components/feedlog-github-issues-client.js +0 -1
- package/dist/components/feedlog-github-issues.js +0 -1
- package/dist/components/p-CyaPkQyN.js +0 -1
- package/dist/esm/feedlog-github-issues.entry.js +0 -68
- package/dist/esm/feedlog-issues-list.entry.js +0 -31
- package/dist/feedlog-toolkit/p-3154bc80.entry.js +0 -1
- package/dist/feedlog-toolkit/p-5688651c.entry.js +0 -1
- /package/dist/types/components/{feedlog-github-issues/feedlog-github-issues.stories.d.ts → feedlog-issues/feedlog-issues.stories.d.ts} +0 -0
|
@@ -97,15 +97,15 @@ const sampleIssues = [
|
|
|
97
97
|
},
|
|
98
98
|
];
|
|
99
99
|
const meta = {
|
|
100
|
-
title: 'Components/
|
|
101
|
-
component: 'feedlog-
|
|
100
|
+
title: 'Components/Issues',
|
|
101
|
+
component: 'feedlog-issues',
|
|
102
102
|
parameters: {
|
|
103
103
|
layout: 'padded',
|
|
104
104
|
},
|
|
105
105
|
argTypes: {
|
|
106
106
|
issues: {
|
|
107
107
|
control: 'object',
|
|
108
|
-
description: 'Array of
|
|
108
|
+
description: 'Array of issues to display',
|
|
109
109
|
},
|
|
110
110
|
maxWidth: {
|
|
111
111
|
control: 'text',
|
|
@@ -124,6 +124,14 @@ const meta = {
|
|
|
124
124
|
control: 'text',
|
|
125
125
|
description: 'Error message',
|
|
126
126
|
},
|
|
127
|
+
emptyStateTitle: {
|
|
128
|
+
control: 'text',
|
|
129
|
+
description: 'Empty state title',
|
|
130
|
+
},
|
|
131
|
+
emptyStateMessage: {
|
|
132
|
+
control: 'text',
|
|
133
|
+
description: 'Empty state message',
|
|
134
|
+
},
|
|
127
135
|
},
|
|
128
136
|
args: {
|
|
129
137
|
issues: sampleIssues,
|
|
@@ -138,9 +146,9 @@ export const Default = {
|
|
|
138
146
|
args: {
|
|
139
147
|
issues: sampleIssues,
|
|
140
148
|
},
|
|
141
|
-
render: props => h("feedlog-
|
|
149
|
+
render: props => h("feedlog-issues", Object.assign({}, props)),
|
|
142
150
|
play: async ({ canvasElement, args }) => {
|
|
143
|
-
const element = canvasElement.querySelector('feedlog-
|
|
151
|
+
const element = canvasElement.querySelector('feedlog-issues');
|
|
144
152
|
if (element && args.issues) {
|
|
145
153
|
element.issues = args.issues;
|
|
146
154
|
}
|
|
@@ -150,10 +158,12 @@ export const Loading = {
|
|
|
150
158
|
args: {
|
|
151
159
|
issues: [],
|
|
152
160
|
loading: true,
|
|
161
|
+
heading: 'Community feedback',
|
|
162
|
+
subtitle: 'Upvote issues you care about',
|
|
153
163
|
},
|
|
154
|
-
render: props => h("feedlog-
|
|
164
|
+
render: props => h("feedlog-issues", Object.assign({}, props)),
|
|
155
165
|
play: async ({ canvasElement, args }) => {
|
|
156
|
-
const element = canvasElement.querySelector('feedlog-
|
|
166
|
+
const element = canvasElement.querySelector('feedlog-issues');
|
|
157
167
|
if (element && args.issues) {
|
|
158
168
|
element.issues = args.issues;
|
|
159
169
|
}
|
|
@@ -163,11 +173,13 @@ export const Error = {
|
|
|
163
173
|
args: {
|
|
164
174
|
issues: [],
|
|
165
175
|
loading: false,
|
|
166
|
-
error: '
|
|
176
|
+
error: "Couldn't load updates",
|
|
177
|
+
heading: 'Community feedback',
|
|
178
|
+
subtitle: 'Upvote issues you care about',
|
|
167
179
|
},
|
|
168
|
-
render: props => h("feedlog-
|
|
180
|
+
render: props => h("feedlog-issues", Object.assign({}, props)),
|
|
169
181
|
play: async ({ canvasElement, args }) => {
|
|
170
|
-
const element = canvasElement.querySelector('feedlog-
|
|
182
|
+
const element = canvasElement.querySelector('feedlog-issues');
|
|
171
183
|
if (element && args.issues) {
|
|
172
184
|
element.issues = args.issues;
|
|
173
185
|
}
|
|
@@ -178,10 +190,12 @@ export const Empty = {
|
|
|
178
190
|
issues: [],
|
|
179
191
|
loading: false,
|
|
180
192
|
error: null,
|
|
193
|
+
heading: 'Community feedback',
|
|
194
|
+
subtitle: 'Upvote issues you care about',
|
|
181
195
|
},
|
|
182
|
-
render: props => h("feedlog-
|
|
196
|
+
render: props => h("feedlog-issues", Object.assign({}, props)),
|
|
183
197
|
play: async ({ canvasElement, args }) => {
|
|
184
|
-
const element = canvasElement.querySelector('feedlog-
|
|
198
|
+
const element = canvasElement.querySelector('feedlog-issues');
|
|
185
199
|
if (element && args.issues) {
|
|
186
200
|
element.issues = args.issues;
|
|
187
201
|
}
|
|
@@ -192,9 +206,9 @@ export const DarkTheme = {
|
|
|
192
206
|
issues: sampleIssues,
|
|
193
207
|
theme: 'dark',
|
|
194
208
|
},
|
|
195
|
-
render: props => h("feedlog-
|
|
209
|
+
render: props => h("feedlog-issues", Object.assign({}, props)),
|
|
196
210
|
play: async ({ canvasElement, args }) => {
|
|
197
|
-
const element = canvasElement.querySelector('feedlog-
|
|
211
|
+
const element = canvasElement.querySelector('feedlog-issues');
|
|
198
212
|
if (element && args.issues) {
|
|
199
213
|
element.issues = args.issues;
|
|
200
214
|
}
|
|
@@ -205,9 +219,9 @@ export const NarrowWidth = {
|
|
|
205
219
|
issues: sampleIssues.slice(0, 3),
|
|
206
220
|
maxWidth: '32rem',
|
|
207
221
|
},
|
|
208
|
-
render: props => h("feedlog-
|
|
222
|
+
render: props => h("feedlog-issues", Object.assign({}, props)),
|
|
209
223
|
play: async ({ canvasElement, args }) => {
|
|
210
|
-
const element = canvasElement.querySelector('feedlog-
|
|
224
|
+
const element = canvasElement.querySelector('feedlog-issues');
|
|
211
225
|
if (element && args.issues) {
|
|
212
226
|
element.issues = args.issues;
|
|
213
227
|
}
|
|
@@ -217,7 +231,7 @@ export const CustomCSSVars = {
|
|
|
217
231
|
args: {
|
|
218
232
|
issues: sampleIssues,
|
|
219
233
|
},
|
|
220
|
-
render: (props) => (h("feedlog-
|
|
234
|
+
render: (props) => (h("feedlog-issues", Object.assign({}, props, { style: {
|
|
221
235
|
fontFamily: "'Georgia', 'Times New Roman', serif",
|
|
222
236
|
/* Card */
|
|
223
237
|
'--feedlog-card-padding': '1.5rem',
|
|
@@ -238,7 +252,7 @@ export const CustomCSSVars = {
|
|
|
238
252
|
'--feedlog-border': 'rgba(5, 150, 105, 0.2)',
|
|
239
253
|
} }))),
|
|
240
254
|
play: async ({ canvasElement, args }) => {
|
|
241
|
-
const element = canvasElement.querySelector('feedlog-
|
|
255
|
+
const element = canvasElement.querySelector('feedlog-issues');
|
|
242
256
|
if (element && args.issues) {
|
|
243
257
|
element.issues = args.issues;
|
|
244
258
|
}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
2
|
import { FeedlogSDK } from "@feedlog-ai/core";
|
|
3
3
|
/**
|
|
4
|
-
* Feedlog
|
|
4
|
+
* Feedlog Issues Client Component
|
|
5
5
|
*
|
|
6
|
-
* A component for displaying
|
|
7
|
-
* This component uses the SDK internally to fetch data and delegates to feedlog-
|
|
6
|
+
* A component for displaying issues fetched using the Feedlog SDK.
|
|
7
|
+
* This component uses the SDK internally to fetch data and delegates to feedlog-issues for rendering.
|
|
8
8
|
*/
|
|
9
|
-
export class
|
|
9
|
+
export class FeedlogIssuesClient {
|
|
10
10
|
constructor() {
|
|
11
11
|
/**
|
|
12
12
|
* Maximum width of the container
|
|
@@ -148,7 +148,7 @@ export class FeedlogGithubIssuesClient {
|
|
|
148
148
|
if (this.isDisconnected || currentRequestId !== this.fetchRequestId) {
|
|
149
149
|
return;
|
|
150
150
|
}
|
|
151
|
-
const errorMsg = err instanceof Error ? err.message : '
|
|
151
|
+
const errorMsg = err instanceof Error ? err.message : "Couldn't load updates";
|
|
152
152
|
this.error = errorMsg;
|
|
153
153
|
this.issues = [];
|
|
154
154
|
this.feedlogError.emit({
|
|
@@ -213,9 +213,9 @@ export class FeedlogGithubIssuesClient {
|
|
|
213
213
|
}
|
|
214
214
|
}
|
|
215
215
|
render() {
|
|
216
|
-
return (h("feedlog-
|
|
216
|
+
return (h("feedlog-issues", { key: '8c8635788f390477f1e5217e423d79438c45858d', issues: this.issues, maxWidth: this.maxWidth, theme: this.theme, heading: this.heading, subtitle: this.subtitle, emptyStateTitle: this.emptyStateTitle, emptyStateMessage: this.emptyStateMessage, getIssueUrl: this.getIssueUrl, loading: this.loading, error: this.error, hasMore: this.hasMore, isLoadingMore: this.isLoadingMore, onFeedlogUpvote: this.handleUpvote, onFeedlogLoadMore: async () => this.loadMore() }));
|
|
217
217
|
}
|
|
218
|
-
static get is() { return "feedlog-
|
|
218
|
+
static get is() { return "feedlog-issues-client"; }
|
|
219
219
|
static get encapsulation() { return "shadow"; }
|
|
220
220
|
static get properties() {
|
|
221
221
|
return {
|
|
@@ -398,6 +398,44 @@ export class FeedlogGithubIssuesClient {
|
|
|
398
398
|
"reflect": false,
|
|
399
399
|
"attribute": "subtitle"
|
|
400
400
|
},
|
|
401
|
+
"emptyStateTitle": {
|
|
402
|
+
"type": "string",
|
|
403
|
+
"mutable": false,
|
|
404
|
+
"complexType": {
|
|
405
|
+
"original": "string",
|
|
406
|
+
"resolved": "string | undefined",
|
|
407
|
+
"references": {}
|
|
408
|
+
},
|
|
409
|
+
"required": false,
|
|
410
|
+
"optional": true,
|
|
411
|
+
"docs": {
|
|
412
|
+
"tags": [],
|
|
413
|
+
"text": "Empty state title (e.g. \"No updates yet\")"
|
|
414
|
+
},
|
|
415
|
+
"getter": false,
|
|
416
|
+
"setter": false,
|
|
417
|
+
"reflect": false,
|
|
418
|
+
"attribute": "empty-state-title"
|
|
419
|
+
},
|
|
420
|
+
"emptyStateMessage": {
|
|
421
|
+
"type": "string",
|
|
422
|
+
"mutable": false,
|
|
423
|
+
"complexType": {
|
|
424
|
+
"original": "string",
|
|
425
|
+
"resolved": "string | undefined",
|
|
426
|
+
"references": {}
|
|
427
|
+
},
|
|
428
|
+
"required": false,
|
|
429
|
+
"optional": true,
|
|
430
|
+
"docs": {
|
|
431
|
+
"tags": [],
|
|
432
|
+
"text": "Empty state message (e.g. \"Check back later for new updates.\")"
|
|
433
|
+
},
|
|
434
|
+
"getter": false,
|
|
435
|
+
"setter": false,
|
|
436
|
+
"reflect": false,
|
|
437
|
+
"attribute": "empty-state-message"
|
|
438
|
+
},
|
|
401
439
|
"getIssueUrl": {
|
|
402
440
|
"type": "unknown",
|
|
403
441
|
"mutable": false,
|
|
@@ -416,7 +454,7 @@ export class FeedlogGithubIssuesClient {
|
|
|
416
454
|
"optional": true,
|
|
417
455
|
"docs": {
|
|
418
456
|
"tags": [],
|
|
419
|
-
"text": "Optional callback to resolve
|
|
457
|
+
"text": "Optional callback to resolve issue URL when githubIssueLink is not available.\nRequired because repository.owner was removed from the API for privacy."
|
|
420
458
|
},
|
|
421
459
|
"getter": false,
|
|
422
460
|
"setter": false
|
|
@@ -1,10 +1,18 @@
|
|
|
1
1
|
:host {
|
|
2
2
|
display: block;
|
|
3
3
|
--feedlog-muted-foreground: #64748b;
|
|
4
|
+
--feedlog-foreground: oklch(0.145 0 0);
|
|
5
|
+
--feedlog-empty-illustration-bg: oklch(0.96 0.01 260);
|
|
6
|
+
--feedlog-empty-illustration-stroke: oklch(0.75 0.02 260);
|
|
7
|
+
--feedlog-empty-illustration-muted: oklch(0.82 0.01 260);
|
|
4
8
|
}
|
|
5
9
|
|
|
6
10
|
:host(.dark) {
|
|
7
11
|
--feedlog-muted-foreground: oklch(0.72 0.02 260);
|
|
12
|
+
--feedlog-foreground: oklch(0.985 0 0);
|
|
13
|
+
--feedlog-empty-illustration-bg: oklch(0.28 0.02 260);
|
|
14
|
+
--feedlog-empty-illustration-stroke: oklch(0.45 0.02 260);
|
|
15
|
+
--feedlog-empty-illustration-muted: oklch(0.38 0.01 260);
|
|
8
16
|
}
|
|
9
17
|
|
|
10
18
|
.issues-list {
|
|
@@ -19,3 +27,31 @@
|
|
|
19
27
|
color: var(--feedlog-muted-foreground);
|
|
20
28
|
font-size: 0.875rem;
|
|
21
29
|
}
|
|
30
|
+
|
|
31
|
+
.empty-state-content {
|
|
32
|
+
display: flex;
|
|
33
|
+
flex-direction: column;
|
|
34
|
+
align-items: center;
|
|
35
|
+
text-align: center;
|
|
36
|
+
max-width: 20rem;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.empty-state-illustration {
|
|
40
|
+
margin-bottom: 1.5rem;
|
|
41
|
+
opacity: 0.9;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.empty-state-title {
|
|
45
|
+
margin: 0 0 0.5rem 0;
|
|
46
|
+
font-size: 1.125rem;
|
|
47
|
+
font-weight: 600;
|
|
48
|
+
color: var(--feedlog-foreground);
|
|
49
|
+
line-height: 1.4;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.empty-state-message {
|
|
53
|
+
margin: 0;
|
|
54
|
+
font-size: 0.875rem;
|
|
55
|
+
color: var(--feedlog-muted-foreground);
|
|
56
|
+
line-height: 1.5;
|
|
57
|
+
}
|
|
@@ -19,8 +19,11 @@ export class FeedlogIssuesList {
|
|
|
19
19
|
this.feedlogUpvote.emit(event.detail);
|
|
20
20
|
};
|
|
21
21
|
}
|
|
22
|
+
renderEmptyStateIllustration() {
|
|
23
|
+
return (h("svg", { class: "empty-state-illustration", xmlns: "http://www.w3.org/2000/svg", width: "120", height: "96", viewBox: "0 0 120 96", fill: "none", "aria-hidden": "true" }, h("path", { d: "M20 36h80v44c0 4.4-3.6 8-8 8H28c-4.4 0-8-3.6-8-8V36z", fill: "var(--feedlog-empty-illustration-bg)", stroke: "var(--feedlog-empty-illustration-stroke)", "stroke-width": "1.5", "stroke-linejoin": "round" }), h("path", { d: "M20 36l20-24h40l20 24", fill: "none", stroke: "var(--feedlog-empty-illustration-stroke)", "stroke-width": "1.5", "stroke-linecap": "round", "stroke-linejoin": "round" }), h("path", { d: "M44 52h32M44 60h24M44 68h28", stroke: "var(--feedlog-empty-illustration-muted)", "stroke-width": "1.25", "stroke-linecap": "round" })));
|
|
24
|
+
}
|
|
22
25
|
render() {
|
|
23
|
-
return (h(Host, { key: '
|
|
26
|
+
return (h(Host, { key: 'd797fd4978179c9081678e2fb3e7e2be756b4ea2', class: this.theme === 'dark' ? 'dark' : '' }, h("div", { key: '1fe373bbad55cf718d65279ae718f9b95e89e37f', class: "issues-list" }, this.issues.length === 0 ? (h("div", { class: "empty-state" }, this.emptyStateTitle && this.emptyStateMessage ? (h("div", { class: "empty-state-content" }, this.renderEmptyStateIllustration(), h("h2", { class: "empty-state-title" }, this.emptyStateTitle), h("p", { class: "empty-state-message" }, this.emptyStateMessage))) : (h("p", null, "No issues found")))) : (this.issues.map(issue => {
|
|
24
27
|
var _a, _b;
|
|
25
28
|
return (h("feedlog-issue", { key: issue.id, issue: issue, issueUrl: (_b = (_a = this.getIssueUrl) === null || _a === void 0 ? void 0 : _a.call(this, issue)) !== null && _b !== void 0 ? _b : undefined, theme: this.theme, onFeedlogUpvote: (e) => this.handleUpvote(e) }));
|
|
26
29
|
})))));
|
|
@@ -105,6 +108,44 @@ export class FeedlogIssuesList {
|
|
|
105
108
|
},
|
|
106
109
|
"getter": false,
|
|
107
110
|
"setter": false
|
|
111
|
+
},
|
|
112
|
+
"emptyStateTitle": {
|
|
113
|
+
"type": "string",
|
|
114
|
+
"mutable": false,
|
|
115
|
+
"complexType": {
|
|
116
|
+
"original": "string",
|
|
117
|
+
"resolved": "string | undefined",
|
|
118
|
+
"references": {}
|
|
119
|
+
},
|
|
120
|
+
"required": false,
|
|
121
|
+
"optional": true,
|
|
122
|
+
"docs": {
|
|
123
|
+
"tags": [],
|
|
124
|
+
"text": "Empty state title. When provided with emptyStateMessage, shows a richer empty state with illustration."
|
|
125
|
+
},
|
|
126
|
+
"getter": false,
|
|
127
|
+
"setter": false,
|
|
128
|
+
"reflect": false,
|
|
129
|
+
"attribute": "empty-state-title"
|
|
130
|
+
},
|
|
131
|
+
"emptyStateMessage": {
|
|
132
|
+
"type": "string",
|
|
133
|
+
"mutable": false,
|
|
134
|
+
"complexType": {
|
|
135
|
+
"original": "string",
|
|
136
|
+
"resolved": "string | undefined",
|
|
137
|
+
"references": {}
|
|
138
|
+
},
|
|
139
|
+
"required": false,
|
|
140
|
+
"optional": true,
|
|
141
|
+
"docs": {
|
|
142
|
+
"tags": [],
|
|
143
|
+
"text": "Empty state message. When provided with emptyStateTitle, shows a richer empty state with illustration."
|
|
144
|
+
},
|
|
145
|
+
"getter": false,
|
|
146
|
+
"setter": false,
|
|
147
|
+
"reflect": false,
|
|
148
|
+
"attribute": "empty-state-message"
|
|
108
149
|
}
|
|
109
150
|
};
|
|
110
151
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export * from './feedlog-card/feedlog-card';
|
|
2
2
|
export * from './feedlog-badge/feedlog-badge';
|
|
3
3
|
export * from './feedlog-button/feedlog-button';
|
|
4
|
-
export * from './feedlog-
|
|
5
|
-
export * from './feedlog-
|
|
4
|
+
export * from './feedlog-issues/feedlog-issues';
|
|
5
|
+
export * from './feedlog-issues-client/feedlog-issues-client';
|
|
6
6
|
export * from './feedlog-issue/feedlog-issue';
|
|
7
7
|
export * from './feedlog-issues-list/feedlog-issues-list';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { Components, JSX } from "../types/components";
|
|
2
2
|
|
|
3
|
-
interface
|
|
4
|
-
export const
|
|
5
|
-
prototype:
|
|
6
|
-
new ():
|
|
3
|
+
interface FeedlogIssuesClient extends Components.FeedlogIssuesClient, HTMLElement {}
|
|
4
|
+
export const FeedlogIssuesClient: {
|
|
5
|
+
prototype: FeedlogIssuesClient;
|
|
6
|
+
new (): FeedlogIssuesClient;
|
|
7
7
|
};
|
|
8
8
|
/**
|
|
9
9
|
* Used to define this component and all nested components recursively.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{t,p as e,H as s,c as i,h as o}from"./index.js";import{d as r}from"./p-Chc3XZ5Y.js";import{d as n}from"./p-DMdb-G26.js";import{d as h}from"./p-BBPFf6g7.js";import{d as a}from"./p-DJOCetIC.js";import{d as u}from"./p-BR3ookRG.js";function c(t){if("string"!=typeof t)return"";let e=t.replace(/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,"");return e=e.replace(/\s*on\w+\s*=\s*["'][^"']*["']/gi,""),e=e.replace(/\s*on\w+\s*=\s*[^\s>]*/gi,""),e=e.replace(/<iframe\b[^<]*(?:(?!<\/iframe>)<[^<]*)*<\/iframe>/gi,""),e=e.replace(/<style\b[^<]*(?:(?!<\/style>)<[^<]*)*<\/style>/gi,""),e=e.replace(/<(embed|object)\b[^<]*>/gi,""),e=e.replace(/javascript:/gi,""),e=e.replace(/data:(?!image\/(?:png|jpg|jpeg|gif|webp);)/gi,""),e}class l extends Error{constructor(t,e,s){super(t),this.statusCode=e,this.originalError=s,this.name="FeedlogError",Object.setPrototypeOf(this,l.prototype)}}class d extends l{constructor(t){super(t),this.name="FeedlogValidationError",Object.setPrototypeOf(this,d.prototype)}}class p extends l{constructor(t,e,s){super(t,e,s),this.name="FeedlogNetworkError",Object.setPrototypeOf(this,p.prototype)}}class f extends l{constructor(t="Request timed out"){super(t),this.name="FeedlogTimeoutError",Object.setPrototypeOf(this,f.prototype)}}class g{constructor(t){if(this.config={credentials:"include",...t},this.apiKey=this.config.apiKey,!this.apiKey)throw new d("apiKey is required in FeedlogSDKConfig");this.endpoint=this.config.endpoint||"https://api.feedlog.app",this.timeout=this.config.timeout||3e4,this.endpoint=this.endpoint.replace(/\/$/,"")}async fetchIssues(t={}){try{const e=this.buildIssuesUrl(t),s=await this.fetchWithTimeout(e,{method:"GET",headers:this.getAuthHeaders(),credentials:this.config.credentials||"include"});if(!s.ok)throw new p("Failed to fetch issues: "+s.statusText,s.status);const i=await s.json();return this.validateIssuesResponse(i)}catch(t){if(t instanceof l)throw t;if(t instanceof TypeError&&t.message.includes("fetch"))throw new p("Network error: Unable to reach API",void 0,t);throw new l("Failed to fetch issues: "+(t instanceof Error?t.message:"Unknown error"),void 0,t)}}async toggleUpvote(t){if(!t||"string"!=typeof t)throw new d("Issue ID is required");try{const e=`${this.endpoint}/api/issues/${encodeURIComponent(t)}/upvote`,s=await this.fetchWithTimeout(e,{method:"POST",headers:this.getAuthHeaders(),credentials:this.config.credentials||"include",body:JSON.stringify({})});if(404===s.status)throw new p("Issue not found",404);if(401===s.status)throw new p("Unauthorized",401);if(403===s.status)throw new p("Forbidden: Domain not allowed for this repository",403);if(!s.ok)throw new p("Failed to toggle upvote: "+s.statusText,s.status);const i=await s.json();return this.validateUpvoteResponse(i)}catch(t){if(t instanceof l)throw t;if(t instanceof TypeError&&t.message.includes("fetch"))throw new p("Network error: Unable to reach API",void 0,t);throw new l("Failed to toggle upvote: "+(t instanceof Error?t.message:"Unknown error"),void 0,t)}}buildIssuesUrl(t){const e=new URL(this.endpoint+"/api/issues");if(t.repositoryIds){const s=Array.isArray(t.repositoryIds)?t.repositoryIds:[t.repositoryIds];for(const t of s)e.searchParams.append("repositoryIds",t)}return t.type&&e.searchParams.set("type",t.type),t.sortBy&&e.searchParams.set("sortBy",t.sortBy),t.cursor&&e.searchParams.set("cursor",t.cursor),void 0!==t.limit&&e.searchParams.set("limit",""+t.limit),""+e}getAuthHeaders(){const t={"Content-Type":"application/json"};return this.apiKey&&(t["x-api-key"]=this.apiKey),t}async fetchWithTimeout(t,e){const s=new AbortController,i=setTimeout((()=>s.abort()),this.timeout);try{const o=await fetch(t,{...e,signal:s.signal});return clearTimeout(i),o}catch(t){if(clearTimeout(i),t instanceof Error&&"AbortError"===t.name)throw new f(`Request timed out after ${this.timeout}ms`);throw t}}validateIssuesResponse(t){if(!t||"object"!=typeof t)throw new d("Invalid API response: expected object");const e=t;if(!Array.isArray(e.issues))throw new d("Invalid API response: issues must be an array");if(!e.pagination||"object"!=typeof e.pagination)throw new d("Invalid API response: pagination is required");return{issues:e.issues.map((t=>this.validateIssue(t))),pagination:{cursor:e.pagination.cursor,hasMore:!!e.pagination.hasMore}}}validateIssue(t){if(!t||"object"!=typeof t)throw new d("Invalid issue: expected object");const e=t;if("string"!=typeof e.id)throw new d("Invalid issue: id is required and must be a string");if(!["bug","enhancement"].includes(e.type+""))throw new d('Invalid issue: type must be "bug" or "enhancement"');if(!["open","in_progress","closed"].includes(e.status+""))throw new d('Invalid issue: status must be "open", "in_progress", or "closed"');if(!e.repository||"object"!=typeof e.repository)throw new d("Invalid issue: repository is required");const s=e.repository;if("string"!=typeof s.id)throw new d("Invalid issue: repository must have id");const i=null!==e.githubIssueLink&&"string"==typeof e.githubIssueLink?e.githubIssueLink+"":null,o=e.title,r=null!=o&&""!==o?c(o+""):null,n=e.body,h=null!=n&&""!==n?c(n+""):null,a=s.name,u=null!=a&&""!==a?a+"":null,l=s.description,p=null!=l&&""!==l?c(l+""):null;return{id:e.id+"",githubIssueLink:i,type:e.type||"bug",status:e.status||"open",pinnedAt:e.pinnedAt?e.pinnedAt+"":null,revision:Number(e.revision)||1,title:r,body:h,repository:{id:s.id+"",name:u,description:p},updatedAt:e.updatedAt+""||(new Date).toISOString(),createdAt:e.createdAt+""||(new Date).toISOString(),upvoteCount:Number(e.upvoteCount)||0,hasUpvoted:!!e.hasUpvoted}}validateUpvoteResponse(t){if(!t||"object"!=typeof t)throw new d("Invalid upvote response: expected object");const e=t;if("boolean"!=typeof e.upvoted)throw new d("Invalid upvote response: upvoted must be a boolean");if("number"!=typeof e.upvoteCount)throw new d("Invalid upvote response: upvoteCount must be a number");if("string"!=typeof e.anonymousUserId)throw new d("Invalid upvote response: anonymousUserId must be a string");return{upvoted:e.upvoted,upvoteCount:e.upvoteCount,anonymousUserId:e.anonymousUserId}}getEndpoint(){return this.endpoint}getTimeout(){return this.timeout}}const m=e(class extends s{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.feedlogUpvote=i(this,"feedlogUpvote"),this.feedlogError=i(this,"feedlogError"),this.maxWidth="42rem",this.theme="light",this.issues=[],this.loading=!0,this.error=null,this.cursor=null,this.hasMore=!1,this.isLoadingMore=!1,this.sdk=null,this.fetchRequestId=0,this.isDisconnected=!1,this.upvoteRequestIds=new Map,this.handleUpvote=async t=>{if(!this.sdk||this.isDisconnected)return;const{issueId:e,currentUpvoted:s,currentCount:i}=t.detail,o=(this.upvoteRequestIds.get(e)||0)+1;this.upvoteRequestIds.set(e,o),this.issues=this.issues.map((t=>t.id===e?Object.assign(Object.assign({},t),{hasUpvoted:!s,upvoteCount:s?i-1:i+1}):t));try{const t=await this.sdk.toggleUpvote(e);if(this.isDisconnected||this.upvoteRequestIds.get(e)!==o)return;this.issues=this.issues.map((s=>s.id===e?Object.assign(Object.assign({},s),{hasUpvoted:t.upvoted,upvoteCount:t.upvoteCount}):s)),this.feedlogUpvote.emit({issueId:e,upvoted:t.upvoted,upvoteCount:t.upvoteCount})}catch(t){if(this.isDisconnected||this.upvoteRequestIds.get(e)!==o)return;this.issues=this.issues.map((t=>t.id===e?Object.assign(Object.assign({},t),{hasUpvoted:s,upvoteCount:i}):t)),this.feedlogError.emit({error:t instanceof Error?t.message:"Failed to toggle upvote"})}}}componentWillLoad(){this.previousType=this.type,this.previousLimit=this.limit,this.previousSortBy=this.sortBy,this.initializeSDK(),this.fetchIssues()}disconnectedCallback(){this.isDisconnected=!0,this.fetchRequestId++}componentDidUpdate(){(this.previousType!==this.type||this.previousLimit!==this.limit||this.previousSortBy!==this.sortBy)&&(this.fetchRequestId++,this.cursor=null,this.hasMore=!1,this.issues=[],this.fetchIssues(),this.previousType=this.type,this.previousLimit=this.limit,this.previousSortBy=this.sortBy)}initializeSDK(){try{if(!this.apiKey)throw Error("API key is required for the Feedlog SDK");this.sdk=new g(Object.assign({apiKey:this.apiKey},this.endpoint&&{endpoint:this.endpoint})),this.error=null}catch(t){const e=t instanceof Error?t.message:"Failed to initialize SDK";this.error=e,this.feedlogError.emit({error:e})}}async fetchIssues(){if(!this.sdk)return;const t=this.fetchRequestId;try{this.loading=!0,this.error=null;const e={};this.type&&(e.type=this.type),this.sortBy&&(e.sortBy=this.sortBy),this.limit&&(e.limit=this.limit),this.cursor&&(e.cursor=this.cursor);const s=await this.sdk.fetchIssues(e);if(this.isDisconnected||t!==this.fetchRequestId)return;this.issues=s.issues,this.cursor=s.pagination.cursor,this.hasMore=s.pagination.hasMore}catch(e){if(this.isDisconnected||t!==this.fetchRequestId)return;const s=e instanceof Error?e.message:"Couldn't load updates";this.error=s,this.issues=[],this.feedlogError.emit({error:s,code:null==e?void 0:e.statusCode})}finally{this.isDisconnected||t!==this.fetchRequestId||(this.loading=!1,this.isLoadingMore=!1)}}async loadMore(){if(!this.sdk||!this.hasMore||this.isLoadingMore||this.loading)return;const t=this.fetchRequestId;this.isLoadingMore=!0;try{const e={};this.type&&(e.type=this.type),this.sortBy&&(e.sortBy=this.sortBy),this.limit&&(e.limit=this.limit),this.cursor&&(e.cursor=this.cursor);const s=await this.sdk.fetchIssues(e);if(this.isDisconnected||t!==this.fetchRequestId)return;this.issues=[...this.issues,...s.issues],this.cursor=s.pagination.cursor,this.hasMore=s.pagination.hasMore}catch(e){if(this.isDisconnected||t!==this.fetchRequestId)return;this.feedlogError.emit({error:e instanceof Error?e.message:"Failed to load more issues",code:null==e?void 0:e.statusCode})}finally{this.isDisconnected||t!==this.fetchRequestId||(this.isLoadingMore=!1)}}render(){return o("feedlog-issues",{key:"8c8635788f390477f1e5217e423d79438c45858d",issues:this.issues,maxWidth:this.maxWidth,theme:this.theme,heading:this.heading,subtitle:this.subtitle,emptyStateTitle:this.emptyStateTitle,emptyStateMessage:this.emptyStateMessage,getIssueUrl:this.getIssueUrl,loading:this.loading,error:this.error,hasMore:this.hasMore,isLoadingMore:this.isLoadingMore,onFeedlogUpvote:this.handleUpvote,onFeedlogLoadMore:async()=>this.loadMore()})}},[1,"feedlog-issues-client",{apiKey:[1,"api-key"],type:[1],limit:[2],sortBy:[1,"sort-by"],endpoint:[1],maxWidth:[1,"max-width"],theme:[1],heading:[1],subtitle:[1],emptyStateTitle:[1,"empty-state-title"],emptyStateMessage:[1,"empty-state-message"],getIssueUrl:[16],issues:[32],loading:[32],error:[32],cursor:[32],hasMore:[32],isLoadingMore:[32]}]);function w(){"undefined"!=typeof customElements&&["feedlog-issues-client","feedlog-badge","feedlog-button","feedlog-issue","feedlog-issues","feedlog-issues-list"].forEach((e=>{switch(e){case"feedlog-issues-client":customElements.get(t(e))||customElements.define(t(e),m);break;case"feedlog-badge":customElements.get(t(e))||r();break;case"feedlog-button":customElements.get(t(e))||n();break;case"feedlog-issue":customElements.get(t(e))||h();break;case"feedlog-issues":customElements.get(t(e))||a();break;case"feedlog-issues-list":customElements.get(t(e))||u()}}))}w();const y=m,b=w;export{y as FeedlogIssuesClient,b as defineCustomElement}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{F as o,d as s}from"./p-BR3ookRG.js";const p=o,r=s;export{p as FeedlogIssuesList,r as defineCustomElement}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Components, JSX } from "../types/components";
|
|
2
|
+
|
|
3
|
+
interface FeedlogIssues extends Components.FeedlogIssues, HTMLElement {}
|
|
4
|
+
export const FeedlogIssues: {
|
|
5
|
+
prototype: FeedlogIssues;
|
|
6
|
+
new (): FeedlogIssues;
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Used to define this component and all nested components recursively.
|
|
10
|
+
*/
|
|
11
|
+
export const defineCustomElement: () => void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{F as o,d as s}from"./p-DJOCetIC.js";const t=o,p=s;export{t as FeedlogIssues,p as defineCustomElement}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{t as e,p as t,H as s,c as o,h as l,a as i}from"./index.js";import{d as r}from"./p-Chc3XZ5Y.js";import{d as a}from"./p-BBPFf6g7.js";const d=t(class extends s{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.feedlogUpvote=o(this,"feedlogUpvote"),this.issues=[],this.theme="light",this.handleUpvote=e=>{e.stopPropagation(),this.feedlogUpvote.emit(e.detail)}}renderEmptyStateIllustration(){return l("svg",{class:"empty-state-illustration",xmlns:"http://www.w3.org/2000/svg",width:"120",height:"96",viewBox:"0 0 120 96",fill:"none","aria-hidden":"true"},l("path",{d:"M20 36h80v44c0 4.4-3.6 8-8 8H28c-4.4 0-8-3.6-8-8V36z",fill:"var(--feedlog-empty-illustration-bg)",stroke:"var(--feedlog-empty-illustration-stroke)","stroke-width":"1.5","stroke-linejoin":"round"}),l("path",{d:"M20 36l20-24h40l20 24",fill:"none",stroke:"var(--feedlog-empty-illustration-stroke)","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}),l("path",{d:"M44 52h32M44 60h24M44 68h28",stroke:"var(--feedlog-empty-illustration-muted)","stroke-width":"1.25","stroke-linecap":"round"}))}render(){return l(i,{key:"d797fd4978179c9081678e2fb3e7e2be756b4ea2",class:"dark"===this.theme?"dark":""},l("div",{key:"1fe373bbad55cf718d65279ae718f9b95e89e37f",class:"issues-list"},0===this.issues.length?l("div",{class:"empty-state"},this.emptyStateTitle&&this.emptyStateMessage?l("div",{class:"empty-state-content"},this.renderEmptyStateIllustration(),l("h2",{class:"empty-state-title"},this.emptyStateTitle),l("p",{class:"empty-state-message"},this.emptyStateMessage)):l("p",null,"No issues found")):this.issues.map((e=>{var t,s;return l("feedlog-issue",{key:e.id,issue:e,issueUrl:null!==(s=null===(t=this.getIssueUrl)||void 0===t?void 0:t.call(this,e))&&void 0!==s?s:void 0,theme:this.theme,onFeedlogUpvote:e=>this.handleUpvote(e)})}))))}static get style(){return":host{display:block;--feedlog-muted-foreground:#64748b;--feedlog-foreground:oklch(0.145 0 0);--feedlog-empty-illustration-bg:oklch(0.96 0.01 260);--feedlog-empty-illustration-stroke:oklch(0.75 0.02 260);--feedlog-empty-illustration-muted:oklch(0.82 0.01 260)}:host(.dark){--feedlog-muted-foreground:oklch(0.72 0.02 260);--feedlog-foreground:oklch(0.985 0 0);--feedlog-empty-illustration-bg:oklch(0.28 0.02 260);--feedlog-empty-illustration-stroke:oklch(0.45 0.02 260);--feedlog-empty-illustration-muted:oklch(0.38 0.01 260)}.issues-list{display:flex;flex-direction:column;gap:0.5rem}.empty-state{text-align:center;padding:3rem 1.5rem;color:var(--feedlog-muted-foreground);font-size:0.875rem}.empty-state-content{display:flex;flex-direction:column;align-items:center;text-align:center;max-width:20rem}.empty-state-illustration{margin-bottom:1.5rem;opacity:0.9}.empty-state-title{margin:0 0 0.5rem 0;font-size:1.125rem;font-weight:600;color:var(--feedlog-foreground);line-height:1.4}.empty-state-message{margin:0;font-size:0.875rem;color:var(--feedlog-muted-foreground);line-height:1.5}"}},[1,"feedlog-issues-list",{issues:[16],theme:[1],getIssueUrl:[16],emptyStateTitle:[1,"empty-state-title"],emptyStateMessage:[1,"empty-state-message"]}]);function n(){"undefined"!=typeof customElements&&["feedlog-issues-list","feedlog-badge","feedlog-issue"].forEach((t=>{switch(t){case"feedlog-issues-list":customElements.get(e(t))||customElements.define(e(t),d);break;case"feedlog-badge":customElements.get(e(t))||r();break;case"feedlog-issue":customElements.get(e(t))||a()}}))}n();export{d as F,n as d}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{t as e,p as o,H as t,c as s,h as d,a as r}from"./index.js";import{d as i}from"./p-Chc3XZ5Y.js";import{d as a}from"./p-DMdb-G26.js";import{d as l}from"./p-BBPFf6g7.js";import{d as n}from"./p-BR3ookRG.js";const c=o(class extends t{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.feedlogUpvote=s(this,"feedlogUpvote"),this.feedlogLoadMore=s(this,"feedlogLoadMore"),this.issues=[],this.maxWidth="42rem",this.theme="light",this.loading=!1,this.error=null,this.hasMore=!1,this.isLoadingMore=!1,this.currentTheme="light",this.handleUpvote=e=>{e.stopPropagation(),this.feedlogUpvote.emit(e.detail)},this.handleLoadMore=()=>{this.feedlogLoadMore.emit()}}componentWillLoad(){this.currentTheme=this.theme}renderErrorIcon(){return d("svg",{class:"error-icon",xmlns:"http://www.w3.org/2000/svg",width:"48",height:"48",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},d("circle",{cx:"12",cy:"12",r:"10"}),d("line",{x1:"12",y1:"8",x2:"12",y2:"12"}),d("line",{x1:"12",y1:"16",x2:"12.01",y2:"16"}))}renderIssuesList(){var e,o;return d("feedlog-issues-list",{issues:this.issues,theme:this.currentTheme,getIssueUrl:this.getIssueUrl,emptyStateTitle:null!==(e=this.emptyStateTitle)&&void 0!==e?e:"No updates yet",emptyStateMessage:null!==(o=this.emptyStateMessage)&&void 0!==o?o:"Check back later for new updates.",onFeedlogUpvote:e=>this.handleUpvote(e)})}render(){return d(r,{key:"812719c5d6f25108834d1a422dee280c18033e36",class:"dark"===this.currentTheme?"dark":""},d("div",{key:"1e415969878bad8fb14ea9e648d2c2d2e0d492a1",class:"issues-container",style:{maxWidth:this.maxWidth}},(this.heading||this.subtitle)&&d("header",{key:"5bf1308396ff3bc04a57763317fa71a34d48cc95",class:"issues-header"},d("div",{key:"19494458a1bcd11c3d91c08e98887f9d6ed33314",class:"header-content"},this.heading&&d("h1",{key:"f89bd679a9dd9262c93573ef0bfbbb23bd892a87",class:"issues-title"},this.heading),this.subtitle&&d("p",{key:"2bcc73dfb95d7ae8971004522fe44cca5128701b",class:"issues-subtitle"},this.subtitle))),this.loading&&d("div",{key:"85c06c80b624cd16d532bea5f0ad6fb7cc06f692",class:"loading-state",role:"status","aria-label":"Loading issues"},d("div",{key:"766cd9e7c18586f937a1b864e7bcfce60fe79707",class:"loading-skeletons"},[1,2,3].map((e=>d("div",{key:e,class:"skeleton-card"},d("div",{class:"skeleton-content"},d("div",{class:"skeleton-header"},d("div",{class:"skeleton-badge"}),d("div",{class:"skeleton-timestamp"})),d("div",{class:"skeleton-main"},d("div",{class:"skeleton-title"}),d("div",{class:"skeleton-body"},d("div",{class:"skeleton-line"}),d("div",{class:"skeleton-line short"})),d("div",{class:"skeleton-repo"})),d("div",{class:"skeleton-footer"},d("div",{class:"skeleton-upvote"})))))))),this.error&&d("div",{key:"5ca08a9ddc95b4ef59d6c776a24e08b5ac65c0b3",class:"error-state",role:"alert"},d("div",{key:"93218f816564cff58f591b53d1aad6b6bc8a1c64",class:"error-state-content"},this.renderErrorIcon(),d("h2",{key:"f141f75b92164af3f4d139a17937b0533641bcc0",class:"error-state-title"},"Something went wrong"),d("p",{key:"61225c7f4f46944787d4a6448386c8209cdaf74c",class:"error-state-message"},this.error))),!this.loading&&!this.error&&d("div",{key:"5ac699f4c5d0e5b5d20f1546efe24f80cba70748"},this.renderIssuesList(),this.hasMore&&d("div",{key:"9ad22c48dac0d8874dfae9735c850b2ca52836e7",class:"load-more-container"},d("feedlog-button",{key:"de55c05ca8b80ec5df98051653ca135874edc98b",onFeedlogClick:this.handleLoadMore,disabled:this.isLoadingMore,variant:"outline"},this.isLoadingMore?"Loading...":"Load More Issues")))))}static get style(){return":host{display:block;font-family:ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, 'Liberation Mono', monospace;--feedlog-background:#ffffff;--feedlog-foreground:oklch(0.145 0 0);--feedlog-card:#ffffff;--feedlog-card-foreground:oklch(0.145 0 0);--feedlog-muted:#ececf0;--feedlog-muted-foreground:#717182;--feedlog-border:rgba(0, 0, 0, 0.1);--feedlog-accent-color:#2563eb;--feedlog-destructive:#d4183d;--feedlog-blue-400:oklch(0.707 0.165 254.624);--feedlog-blue-600:oklch(0.546 0.245 262.881);--feedlog-blue-100:oklch(0.932 0.032 255.585);--feedlog-red-100:#fce7f3;--feedlog-red-400:#f472b6;--feedlog-red-600:#db2777;--feedlog-radius:0.625rem;--feedlog-gap:0.5rem;--feedlog-padding:2rem;--feedlog-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.08), 0 1px 2px -1px rgba(0, 0, 0, 0.08)}:host(.dark){--feedlog-background:oklch(0.18 0.01 260);--feedlog-foreground:oklch(0.985 0 0);--feedlog-card:oklch(0.24 0.01 260);--feedlog-card-foreground:oklch(0.985 0 0);--feedlog-muted:oklch(0.32 0.01 260);--feedlog-muted-foreground:oklch(0.72 0.02 260);--feedlog-border:oklch(0.34 0.01 260);--feedlog-accent-color:#3b82f6;--feedlog-destructive:oklch(0.396 0.141 25.723);--feedlog-blue-400:oklch(0.707 0.165 254.624);--feedlog-blue-600:oklch(0.546 0.245 262.881);--feedlog-blue-900-30:color-mix(in oklab, oklch(0.379 0.146 265.522) 30%, transparent);--feedlog-red-900-30:color-mix(in oklab, oklch(0.396 0.141 25.723) 30%, transparent);--feedlog-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.3)}.issues-container{min-height:100vh;background-color:var(--feedlog-background);padding:var(--feedlog-padding);margin:0 auto}.issues-header{margin-bottom:1.5rem;display:flex;align-items:flex-start;justify-content:space-between}.header-content{flex:1}.issues-title{color:var(--feedlog-foreground);margin:0 0 0.25rem 0;font-size:1.5rem;font-weight:500;line-height:1.5}.issues-subtitle{color:var(--feedlog-muted-foreground);font-size:0.875rem;margin:0}.loading-state{padding:0}.loading-skeletons{display:flex;flex-direction:column;gap:var(--feedlog-gap)}.skeleton-card{background-color:var(--feedlog-card);border:1px solid var(--feedlog-border);border-radius:var(--feedlog-radius);box-shadow:var(--feedlog-shadow);position:relative;overflow:hidden}.skeleton-card::before{content:'';position:absolute;left:0;top:0;bottom:0;width:3px;background:var(--feedlog-muted)}.skeleton-content{padding:1.25rem;padding-left:calc(1.25rem + 3px);display:flex;flex-direction:column;gap:0.875rem}.skeleton-header{display:flex;align-items:center;justify-content:space-between;gap:0.75rem}.skeleton-badge{width:4.5rem;height:1.25rem;border-radius:0.375rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite}.skeleton-timestamp{width:3rem;height:0.75rem;border-radius:0.25rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite 0.2s}.skeleton-main{display:flex;flex-direction:column;gap:0.5rem}.skeleton-title{height:0.9375rem;border-radius:0.25rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite 0.1s;width:85%}.skeleton-body{display:flex;flex-direction:column;gap:0.375rem}.skeleton-line{height:0.8125rem;border-radius:0.25rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite 0.15s;width:100%}.skeleton-line.short{width:70%}.skeleton-repo{width:6rem;height:0.75rem;border-radius:0.25rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite 0.25s}.skeleton-footer{display:flex;justify-content:flex-end}.skeleton-upvote{width:2.5rem;height:2rem;border-radius:0.5rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite 0.3s}@keyframes skeleton-pulse{0%,100%{opacity:1}50%{opacity:0.5}}.error-state{display:flex;align-items:center;justify-content:center;padding:3rem 2rem;min-height:12rem}.error-state-content{display:flex;flex-direction:column;align-items:center;text-align:center;max-width:20rem;padding:2rem}.error-icon{color:var(--feedlog-muted-foreground);opacity:0.8;margin-bottom:1rem}.error-state-title{margin:0 0 0.5rem 0;font-size:1.125rem;font-weight:600;color:var(--feedlog-foreground);line-height:1.4}.error-state-message{margin:0 0 1.25rem 0;font-size:0.875rem;color:var(--feedlog-muted-foreground);line-height:1.5}.load-more-container{display:flex;justify-content:center;padding:2rem 0;gap:1rem}"}},[1,"feedlog-issues",{issues:[16],maxWidth:[1,"max-width"],theme:[1025],heading:[1],subtitle:[1],emptyStateTitle:[1,"empty-state-title"],emptyStateMessage:[1,"empty-state-message"],loading:[4],error:[1],hasMore:[4,"has-more"],isLoadingMore:[4,"is-loading-more"],getIssueUrl:[16],currentTheme:[32]}]);function f(){"undefined"!=typeof customElements&&["feedlog-issues","feedlog-badge","feedlog-button","feedlog-issue","feedlog-issues-list"].forEach((o=>{switch(o){case"feedlog-issues":customElements.get(e(o))||customElements.define(e(o),c);break;case"feedlog-badge":customElements.get(e(o))||i();break;case"feedlog-button":customElements.get(e(o))||a();break;case"feedlog-issue":customElements.get(e(o))||l();break;case"feedlog-issues-list":customElements.get(e(o))||n()}}))}f();export{c as F,f as d}
|
|
@@ -1635,4 +1635,35 @@ const FeedlogIssueComponent = class {
|
|
|
1635
1635
|
};
|
|
1636
1636
|
FeedlogIssueComponent.style = feedlogIssueCss();
|
|
1637
1637
|
|
|
1638
|
-
|
|
1638
|
+
const feedlogIssuesListCss = () => `:host{display:block;--feedlog-muted-foreground:#64748b;--feedlog-foreground:oklch(0.145 0 0);--feedlog-empty-illustration-bg:oklch(0.96 0.01 260);--feedlog-empty-illustration-stroke:oklch(0.75 0.02 260);--feedlog-empty-illustration-muted:oklch(0.82 0.01 260)}:host(.dark){--feedlog-muted-foreground:oklch(0.72 0.02 260);--feedlog-foreground:oklch(0.985 0 0);--feedlog-empty-illustration-bg:oklch(0.28 0.02 260);--feedlog-empty-illustration-stroke:oklch(0.45 0.02 260);--feedlog-empty-illustration-muted:oklch(0.38 0.01 260)}.issues-list{display:flex;flex-direction:column;gap:0.5rem}.empty-state{text-align:center;padding:3rem 1.5rem;color:var(--feedlog-muted-foreground);font-size:0.875rem}.empty-state-content{display:flex;flex-direction:column;align-items:center;text-align:center;max-width:20rem}.empty-state-illustration{margin-bottom:1.5rem;opacity:0.9}.empty-state-title{margin:0 0 0.5rem 0;font-size:1.125rem;font-weight:600;color:var(--feedlog-foreground);line-height:1.4}.empty-state-message{margin:0;font-size:0.875rem;color:var(--feedlog-muted-foreground);line-height:1.5}`;
|
|
1639
|
+
|
|
1640
|
+
const FeedlogIssuesList = class {
|
|
1641
|
+
constructor(hostRef) {
|
|
1642
|
+
registerInstance(this, hostRef);
|
|
1643
|
+
this.feedlogUpvote = createEvent(this, "feedlogUpvote");
|
|
1644
|
+
/**
|
|
1645
|
+
* Array of issues to display
|
|
1646
|
+
*/
|
|
1647
|
+
this.issues = [];
|
|
1648
|
+
/**
|
|
1649
|
+
* Theme variant: 'light' or 'dark'
|
|
1650
|
+
*/
|
|
1651
|
+
this.theme = 'light';
|
|
1652
|
+
this.handleUpvote = (event) => {
|
|
1653
|
+
event.stopPropagation();
|
|
1654
|
+
this.feedlogUpvote.emit(event.detail);
|
|
1655
|
+
};
|
|
1656
|
+
}
|
|
1657
|
+
renderEmptyStateIllustration() {
|
|
1658
|
+
return (h("svg", { class: "empty-state-illustration", xmlns: "http://www.w3.org/2000/svg", width: "120", height: "96", viewBox: "0 0 120 96", fill: "none", "aria-hidden": "true" }, h("path", { d: "M20 36h80v44c0 4.4-3.6 8-8 8H28c-4.4 0-8-3.6-8-8V36z", fill: "var(--feedlog-empty-illustration-bg)", stroke: "var(--feedlog-empty-illustration-stroke)", "stroke-width": "1.5", "stroke-linejoin": "round" }), h("path", { d: "M20 36l20-24h40l20 24", fill: "none", stroke: "var(--feedlog-empty-illustration-stroke)", "stroke-width": "1.5", "stroke-linecap": "round", "stroke-linejoin": "round" }), h("path", { d: "M44 52h32M44 60h24M44 68h28", stroke: "var(--feedlog-empty-illustration-muted)", "stroke-width": "1.25", "stroke-linecap": "round" })));
|
|
1659
|
+
}
|
|
1660
|
+
render() {
|
|
1661
|
+
return (h(Host, { key: 'd797fd4978179c9081678e2fb3e7e2be756b4ea2', class: this.theme === 'dark' ? 'dark' : '' }, h("div", { key: '1fe373bbad55cf718d65279ae718f9b95e89e37f', class: "issues-list" }, this.issues.length === 0 ? (h("div", { class: "empty-state" }, this.emptyStateTitle && this.emptyStateMessage ? (h("div", { class: "empty-state-content" }, this.renderEmptyStateIllustration(), h("h2", { class: "empty-state-title" }, this.emptyStateTitle), h("p", { class: "empty-state-message" }, this.emptyStateMessage))) : (h("p", null, "No issues found")))) : (this.issues.map(issue => {
|
|
1662
|
+
var _a, _b;
|
|
1663
|
+
return (h("feedlog-issue", { key: issue.id, issue: issue, issueUrl: (_b = (_a = this.getIssueUrl) === null || _a === void 0 ? void 0 : _a.call(this, issue)) !== null && _b !== void 0 ? _b : undefined, theme: this.theme, onFeedlogUpvote: (e) => this.handleUpvote(e) }));
|
|
1664
|
+
})))));
|
|
1665
|
+
}
|
|
1666
|
+
};
|
|
1667
|
+
FeedlogIssuesList.style = feedlogIssuesListCss();
|
|
1668
|
+
|
|
1669
|
+
export { FeedlogButton as feedlog_button, FeedlogIssueComponent as feedlog_issue, FeedlogIssuesList as feedlog_issues_list };
|
|
@@ -341,7 +341,7 @@ class FeedlogSDK {
|
|
|
341
341
|
}
|
|
342
342
|
}
|
|
343
343
|
|
|
344
|
-
const
|
|
344
|
+
const FeedlogIssuesClient = class {
|
|
345
345
|
constructor(hostRef) {
|
|
346
346
|
registerInstance(this, hostRef);
|
|
347
347
|
this.feedlogUpvote = createEvent(this, "feedlogUpvote");
|
|
@@ -486,7 +486,7 @@ const FeedlogGithubIssuesClient = class {
|
|
|
486
486
|
if (this.isDisconnected || currentRequestId !== this.fetchRequestId) {
|
|
487
487
|
return;
|
|
488
488
|
}
|
|
489
|
-
const errorMsg = err instanceof Error ? err.message : '
|
|
489
|
+
const errorMsg = err instanceof Error ? err.message : "Couldn't load updates";
|
|
490
490
|
this.error = errorMsg;
|
|
491
491
|
this.issues = [];
|
|
492
492
|
this.feedlogError.emit({
|
|
@@ -551,8 +551,8 @@ const FeedlogGithubIssuesClient = class {
|
|
|
551
551
|
}
|
|
552
552
|
}
|
|
553
553
|
render() {
|
|
554
|
-
return (h("feedlog-
|
|
554
|
+
return (h("feedlog-issues", { key: '8c8635788f390477f1e5217e423d79438c45858d', issues: this.issues, maxWidth: this.maxWidth, theme: this.theme, heading: this.heading, subtitle: this.subtitle, emptyStateTitle: this.emptyStateTitle, emptyStateMessage: this.emptyStateMessage, getIssueUrl: this.getIssueUrl, loading: this.loading, error: this.error, hasMore: this.hasMore, isLoadingMore: this.isLoadingMore, onFeedlogUpvote: this.handleUpvote, onFeedlogLoadMore: async () => this.loadMore() }));
|
|
555
555
|
}
|
|
556
556
|
};
|
|
557
557
|
|
|
558
|
-
export {
|
|
558
|
+
export { FeedlogIssuesClient as feedlog_issues_client };
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host } from './index-rs_66Oq4.js';
|
|
2
|
+
|
|
3
|
+
const feedlogIssuesCss = () => `:host{display:block;font-family:ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, 'Liberation Mono', monospace;--feedlog-background:#ffffff;--feedlog-foreground:oklch(0.145 0 0);--feedlog-card:#ffffff;--feedlog-card-foreground:oklch(0.145 0 0);--feedlog-muted:#ececf0;--feedlog-muted-foreground:#717182;--feedlog-border:rgba(0, 0, 0, 0.1);--feedlog-accent-color:#2563eb;--feedlog-destructive:#d4183d;--feedlog-blue-400:oklch(0.707 0.165 254.624);--feedlog-blue-600:oklch(0.546 0.245 262.881);--feedlog-blue-100:oklch(0.932 0.032 255.585);--feedlog-red-100:#fce7f3;--feedlog-red-400:#f472b6;--feedlog-red-600:#db2777;--feedlog-radius:0.625rem;--feedlog-gap:0.5rem;--feedlog-padding:2rem;--feedlog-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.08), 0 1px 2px -1px rgba(0, 0, 0, 0.08)}:host(.dark){--feedlog-background:oklch(0.18 0.01 260);--feedlog-foreground:oklch(0.985 0 0);--feedlog-card:oklch(0.24 0.01 260);--feedlog-card-foreground:oklch(0.985 0 0);--feedlog-muted:oklch(0.32 0.01 260);--feedlog-muted-foreground:oklch(0.72 0.02 260);--feedlog-border:oklch(0.34 0.01 260);--feedlog-accent-color:#3b82f6;--feedlog-destructive:oklch(0.396 0.141 25.723);--feedlog-blue-400:oklch(0.707 0.165 254.624);--feedlog-blue-600:oklch(0.546 0.245 262.881);--feedlog-blue-900-30:color-mix(in oklab, oklch(0.379 0.146 265.522) 30%, transparent);--feedlog-red-900-30:color-mix(in oklab, oklch(0.396 0.141 25.723) 30%, transparent);--feedlog-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.3)}.issues-container{min-height:100vh;background-color:var(--feedlog-background);padding:var(--feedlog-padding);margin:0 auto}.issues-header{margin-bottom:1.5rem;display:flex;align-items:flex-start;justify-content:space-between}.header-content{flex:1}.issues-title{color:var(--feedlog-foreground);margin:0 0 0.25rem 0;font-size:1.5rem;font-weight:500;line-height:1.5}.issues-subtitle{color:var(--feedlog-muted-foreground);font-size:0.875rem;margin:0}.loading-state{padding:0}.loading-skeletons{display:flex;flex-direction:column;gap:var(--feedlog-gap)}.skeleton-card{background-color:var(--feedlog-card);border:1px solid var(--feedlog-border);border-radius:var(--feedlog-radius);box-shadow:var(--feedlog-shadow);position:relative;overflow:hidden}.skeleton-card::before{content:'';position:absolute;left:0;top:0;bottom:0;width:3px;background:var(--feedlog-muted)}.skeleton-content{padding:1.25rem;padding-left:calc(1.25rem + 3px);display:flex;flex-direction:column;gap:0.875rem}.skeleton-header{display:flex;align-items:center;justify-content:space-between;gap:0.75rem}.skeleton-badge{width:4.5rem;height:1.25rem;border-radius:0.375rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite}.skeleton-timestamp{width:3rem;height:0.75rem;border-radius:0.25rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite 0.2s}.skeleton-main{display:flex;flex-direction:column;gap:0.5rem}.skeleton-title{height:0.9375rem;border-radius:0.25rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite 0.1s;width:85%}.skeleton-body{display:flex;flex-direction:column;gap:0.375rem}.skeleton-line{height:0.8125rem;border-radius:0.25rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite 0.15s;width:100%}.skeleton-line.short{width:70%}.skeleton-repo{width:6rem;height:0.75rem;border-radius:0.25rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite 0.25s}.skeleton-footer{display:flex;justify-content:flex-end}.skeleton-upvote{width:2.5rem;height:2rem;border-radius:0.5rem;background-color:var(--feedlog-muted);animation:skeleton-pulse 1.5s ease-in-out infinite 0.3s}@keyframes skeleton-pulse{0%,100%{opacity:1}50%{opacity:0.5}}.error-state{display:flex;align-items:center;justify-content:center;padding:3rem 2rem;min-height:12rem}.error-state-content{display:flex;flex-direction:column;align-items:center;text-align:center;max-width:20rem;padding:2rem}.error-icon{color:var(--feedlog-muted-foreground);opacity:0.8;margin-bottom:1rem}.error-state-title{margin:0 0 0.5rem 0;font-size:1.125rem;font-weight:600;color:var(--feedlog-foreground);line-height:1.4}.error-state-message{margin:0 0 1.25rem 0;font-size:0.875rem;color:var(--feedlog-muted-foreground);line-height:1.5}.load-more-container{display:flex;justify-content:center;padding:2rem 0;gap:1rem}`;
|
|
4
|
+
|
|
5
|
+
const FeedlogIssues = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.feedlogUpvote = createEvent(this, "feedlogUpvote");
|
|
9
|
+
this.feedlogLoadMore = createEvent(this, "feedlogLoadMore");
|
|
10
|
+
/**
|
|
11
|
+
* Array of issues to display
|
|
12
|
+
*/
|
|
13
|
+
this.issues = [];
|
|
14
|
+
/**
|
|
15
|
+
* Maximum width of the container
|
|
16
|
+
*/
|
|
17
|
+
this.maxWidth = '42rem';
|
|
18
|
+
/**
|
|
19
|
+
* Theme variant: 'light' or 'dark'
|
|
20
|
+
*/
|
|
21
|
+
this.theme = 'light';
|
|
22
|
+
/**
|
|
23
|
+
* Loading state - shows loading indicator when true
|
|
24
|
+
*/
|
|
25
|
+
this.loading = false;
|
|
26
|
+
/**
|
|
27
|
+
* Error message - shows error state when set
|
|
28
|
+
*/
|
|
29
|
+
this.error = null;
|
|
30
|
+
/**
|
|
31
|
+
* Whether there are more issues to load
|
|
32
|
+
*/
|
|
33
|
+
this.hasMore = false;
|
|
34
|
+
/**
|
|
35
|
+
* Whether more issues are currently loading
|
|
36
|
+
*/
|
|
37
|
+
this.isLoadingMore = false;
|
|
38
|
+
/**
|
|
39
|
+
* Internal state for theme
|
|
40
|
+
*/
|
|
41
|
+
this.currentTheme = 'light';
|
|
42
|
+
this.handleUpvote = (event) => {
|
|
43
|
+
event.stopPropagation();
|
|
44
|
+
this.feedlogUpvote.emit(event.detail);
|
|
45
|
+
};
|
|
46
|
+
this.handleLoadMore = () => {
|
|
47
|
+
this.feedlogLoadMore.emit();
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
componentWillLoad() {
|
|
51
|
+
this.currentTheme = this.theme;
|
|
52
|
+
}
|
|
53
|
+
renderErrorIcon() {
|
|
54
|
+
return (h("svg", { class: "error-icon", xmlns: "http://www.w3.org/2000/svg", width: "48", height: "48", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", "stroke-width": "1.5", "stroke-linecap": "round", "stroke-linejoin": "round", "aria-hidden": "true" }, h("circle", { cx: "12", cy: "12", r: "10" }), h("line", { x1: "12", y1: "8", x2: "12", y2: "12" }), h("line", { x1: "12", y1: "16", x2: "12.01", y2: "16" })));
|
|
55
|
+
}
|
|
56
|
+
renderIssuesList() {
|
|
57
|
+
var _a, _b;
|
|
58
|
+
return (h("feedlog-issues-list", { issues: this.issues, theme: this.currentTheme, getIssueUrl: this.getIssueUrl, emptyStateTitle: (_a = this.emptyStateTitle) !== null && _a !== void 0 ? _a : 'No updates yet', emptyStateMessage: (_b = this.emptyStateMessage) !== null && _b !== void 0 ? _b : 'Check back later for new updates.', onFeedlogUpvote: (e) => this.handleUpvote(e) }));
|
|
59
|
+
}
|
|
60
|
+
render() {
|
|
61
|
+
const containerStyle = {
|
|
62
|
+
maxWidth: this.maxWidth,
|
|
63
|
+
};
|
|
64
|
+
return (h(Host, { key: '812719c5d6f25108834d1a422dee280c18033e36', class: this.currentTheme === 'dark' ? 'dark' : '' }, h("div", { key: '1e415969878bad8fb14ea9e648d2c2d2e0d492a1', class: "issues-container", style: containerStyle }, (this.heading || this.subtitle) && (h("header", { key: '5bf1308396ff3bc04a57763317fa71a34d48cc95', class: "issues-header" }, h("div", { key: '19494458a1bcd11c3d91c08e98887f9d6ed33314', class: "header-content" }, this.heading && h("h1", { key: 'f89bd679a9dd9262c93573ef0bfbbb23bd892a87', class: "issues-title" }, this.heading), this.subtitle && h("p", { key: '2bcc73dfb95d7ae8971004522fe44cca5128701b', class: "issues-subtitle" }, this.subtitle)))), this.loading && (h("div", { key: '85c06c80b624cd16d532bea5f0ad6fb7cc06f692', class: "loading-state", role: "status", "aria-label": "Loading issues" }, h("div", { key: '766cd9e7c18586f937a1b864e7bcfce60fe79707', class: "loading-skeletons" }, [1, 2, 3].map(i => (h("div", { key: i, class: "skeleton-card" }, h("div", { class: "skeleton-content" }, h("div", { class: "skeleton-header" }, h("div", { class: "skeleton-badge" }), h("div", { class: "skeleton-timestamp" })), h("div", { class: "skeleton-main" }, h("div", { class: "skeleton-title" }), h("div", { class: "skeleton-body" }, h("div", { class: "skeleton-line" }), h("div", { class: "skeleton-line short" })), h("div", { class: "skeleton-repo" })), h("div", { class: "skeleton-footer" }, h("div", { class: "skeleton-upvote" }))))))))), this.error && (h("div", { key: '5ca08a9ddc95b4ef59d6c776a24e08b5ac65c0b3', class: "error-state", role: "alert" }, h("div", { key: '93218f816564cff58f591b53d1aad6b6bc8a1c64', class: "error-state-content" }, this.renderErrorIcon(), h("h2", { key: 'f141f75b92164af3f4d139a17937b0533641bcc0', class: "error-state-title" }, "Something went wrong"), h("p", { key: '61225c7f4f46944787d4a6448386c8209cdaf74c', class: "error-state-message" }, this.error)))), !this.loading && !this.error && (h("div", { key: '5ac699f4c5d0e5b5d20f1546efe24f80cba70748' }, this.renderIssuesList(), this.hasMore && (h("div", { key: '9ad22c48dac0d8874dfae9735c850b2ca52836e7', class: "load-more-container" }, h("feedlog-button", { key: 'de55c05ca8b80ec5df98051653ca135874edc98b', onFeedlogClick: this.handleLoadMore, disabled: this.isLoadingMore, variant: "outline" }, this.isLoadingMore ? 'Loading...' : 'Load More Issues'))))))));
|
|
65
|
+
}
|
|
66
|
+
};
|
|
67
|
+
FeedlogIssues.style = feedlogIssuesCss();
|
|
68
|
+
|
|
69
|
+
export { FeedlogIssues as feedlog_issues };
|
|
@@ -16,5 +16,5 @@ var patchBrowser = () => {
|
|
|
16
16
|
|
|
17
17
|
patchBrowser().then(async (options) => {
|
|
18
18
|
await globalScripts();
|
|
19
|
-
return bootstrapLazy([["feedlog-
|
|
19
|
+
return bootstrapLazy([["feedlog-card",[[257,"feedlog-card"]]],["feedlog-badge",[[257,"feedlog-badge",{"variant":[1]}]]],["feedlog-button_3",[[1,"feedlog-issues-list",{"issues":[16],"theme":[1],"getIssueUrl":[16],"emptyStateTitle":[1,"empty-state-title"],"emptyStateMessage":[1,"empty-state-message"]}],[257,"feedlog-button",{"variant":[1],"size":[1],"disabled":[4],"type":[1]}],[257,"feedlog-issue",{"issue":[16],"issueUrl":[1,"issue-url"],"theme":[1]}]]],["feedlog-issues",[[1,"feedlog-issues",{"issues":[16],"maxWidth":[1,"max-width"],"theme":[1025],"heading":[1],"subtitle":[1],"emptyStateTitle":[1,"empty-state-title"],"emptyStateMessage":[1,"empty-state-message"],"loading":[4],"error":[1],"hasMore":[4,"has-more"],"isLoadingMore":[4,"is-loading-more"],"getIssueUrl":[16],"currentTheme":[32]}]]],["feedlog-issues-client",[[1,"feedlog-issues-client",{"apiKey":[1,"api-key"],"type":[1],"limit":[2],"sortBy":[1,"sort-by"],"endpoint":[1],"maxWidth":[1,"max-width"],"theme":[1],"heading":[1],"subtitle":[1],"emptyStateTitle":[1,"empty-state-title"],"emptyStateMessage":[1,"empty-state-message"],"getIssueUrl":[16],"issues":[32],"loading":[32],"error":[32],"cursor":[32],"hasMore":[32],"isLoadingMore":[32]}]]]], options);
|
|
20
20
|
});
|