issue-sticker 0.1.0 → 0.2.0

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/package.json CHANGED
@@ -1,41 +1,41 @@
1
1
  {
2
2
  "name": "issue-sticker",
3
- "version": "0.1.0",
3
+ "version": "0.2.0",
4
4
  "description": "IssueSticker SDK - Visual bug tracking widget for web applications",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "type": "module",
7
- "main": "dist/issue-sticker.umd.js",
8
- "module": "dist/issue-sticker.js",
9
- "types": "dist/index.d.ts",
10
7
  "exports": {
11
- ".": {
12
- "types": "./dist/index.d.ts",
13
- "import": "./dist/issue-sticker.js",
14
- "require": "./dist/issue-sticker.umd.js",
15
- "default": "./dist/issue-sticker.js"
16
- },
17
- "./runtime": {
18
- "types": "./runtime.d.ts",
19
- "import": "./dist/issue-sticker-runtime.js",
20
- "require": "./dist/issue-sticker-runtime.js",
21
- "default": "./dist/issue-sticker-runtime.js"
22
- },
23
8
  "./react": {
24
9
  "types": "./react.d.ts",
25
10
  "import": "./dist/issue-sticker-react.js",
26
11
  "require": "./dist/issue-sticker-react.js",
27
12
  "default": "./dist/issue-sticker-react.js"
28
13
  },
29
- "./runtime.js": "./dist/issue-sticker-runtime.js",
14
+ "./headless": {
15
+ "types": "./headless.d.ts",
16
+ "import": "./dist/issue-sticker-headless.js",
17
+ "require": "./dist/issue-sticker-headless.js",
18
+ "default": "./dist/issue-sticker-headless.js"
19
+ },
20
+ "./headless/react": {
21
+ "types": "./headless-react.d.ts",
22
+ "import": "./dist/issue-sticker-headless-react.js",
23
+ "require": "./dist/issue-sticker-headless-react.js",
24
+ "default": "./dist/issue-sticker-headless-react.js"
25
+ },
30
26
  "./react.js": "./dist/issue-sticker-react.js",
27
+ "./headless.js": "./dist/issue-sticker-headless.js",
28
+ "./headless/react.js": "./dist/issue-sticker-headless-react.js",
31
29
  "./package.json": "./package.json"
32
30
  },
33
31
  "files": [
34
- "dist/**/*.js",
35
- "dist/**/*.d.ts",
36
- "dist/**/*.css",
37
- "runtime.d.ts",
32
+ "dist/*.js",
33
+ "!dist/issue-sticker-demo-*.js",
34
+ "dist/*.css",
38
35
  "react.d.ts",
36
+ "headless.d.ts",
37
+ "headless-react.d.ts",
38
+ "CHANGELOG.md",
39
39
  "LICENSE",
40
40
  "README.md"
41
41
  ],
@@ -46,10 +46,10 @@
46
46
  "dev": "npm run dev:localdev",
47
47
  "dev:demo": "concurrently -k -n typecheck,bundle,page -c yellow,cyan,magenta \"npm:tsc:watch\" \"npm:build:demo:watch\" \"npm:serve:demo\"",
48
48
  "dev:localdev": "vite --host 0.0.0.0 --port 4173 --mode localdev",
49
- "build": "vite build --mode production && vite build --config vite.subpath.config.ts --mode production",
50
- "build:dev": "vite build --mode development && vite build --config vite.subpath.config.ts --mode development",
51
- "build:local": "vite build --mode localdev && vite build --config vite.subpath.config.ts --mode localdev",
52
- "build:prod": "tsc --noEmit && vite build --mode production && vite build --config vite.subpath.config.ts --mode production",
49
+ "build": "vite build --config vite.subpath.config.ts --mode production",
50
+ "build:dev": "vite build --config vite.subpath.config.ts --mode development",
51
+ "build:local": "vite build --config vite.subpath.config.ts --mode localdev",
52
+ "build:prod": "tsc --noEmit && vite build --config vite.subpath.config.ts --mode production",
53
53
  "build:demo": "tsc --noEmit && vite build --config vite.subpath.config.ts --mode demo && node scripts/copy-demo-build.mjs",
54
54
  "build:demo:watch": "vite build --watch --config vite.subpath.config.ts --mode demo",
55
55
  "package": "npm run build:prod && npm pack",
@@ -67,12 +67,14 @@
67
67
  "test:e2e:ui": "playwright test --ui"
68
68
  },
69
69
  "dependencies": {
70
+ "@radix-ui/react-accordion": "^1.2.15",
70
71
  "@radix-ui/react-popover": "^1.1.15",
71
72
  "@radix-ui/react-select": "^2.2.6",
72
73
  "@radix-ui/react-tooltip": "^1.2.8",
73
74
  "@tanstack/react-query": "^5.90.12",
74
75
  "class-variance-authority": "^0.7.1",
75
76
  "clsx": "^2.1.1",
77
+ "es-toolkit": "^1.49.0",
76
78
  "framer-motion": "^12.29.2",
77
79
  "lucide-react": "^0.562.0",
78
80
  "modern-screenshot": "^4.7.0",
@@ -84,6 +86,7 @@
84
86
  },
85
87
  "devDependencies": {
86
88
  "@issue-sticker/shared": "*",
89
+ "@microsoft/api-extractor": "^7.58.9",
87
90
  "@playwright/test": "^1.58.2",
88
91
  "@radix-ui/react-dialog": "^1.1.4",
89
92
  "@radix-ui/react-label": "^2.1.1",
@@ -91,8 +94,8 @@
91
94
  "@testing-library/react": "^16.3.2",
92
95
  "@types/react": "^18.2.0",
93
96
  "@types/react-dom": "^18.2.0",
94
- "@vitejs/plugin-react": "^4.2.1",
95
- "@vitest/ui": "^1.2.0",
97
+ "@vitejs/plugin-react": "^4.7.0",
98
+ "@vitest/ui": "^3.2.6",
96
99
  "autoprefixer": "^10.4.23",
97
100
  "concurrently": "^9.2.1",
98
101
  "dotenv": "^16.3.1",
@@ -102,9 +105,8 @@
102
105
  "tailwindcss": "^3.4.19",
103
106
  "terser": "^5.44.1",
104
107
  "typescript": "^5.0.0",
105
- "vite": "^5.0.8",
106
- "vite-plugin-dts": "^3.7.0",
107
- "vitest": "^1.2.0"
108
+ "vite": "^6.4.3",
109
+ "vitest": "^3.2.6"
108
110
  },
109
111
  "peerDependencies": {
110
112
  "react": "^18.0.0 || ^19.0.0",
package/react.d.ts CHANGED
@@ -1,4 +1,32 @@
1
- import type { SDKConfig, SDKEvent, SDKUser } from './dist/index';
1
+ export interface SDKUser {
2
+ id: string;
3
+ name: string;
4
+ }
5
+
6
+ export type OnboardingTrigger = 'off' | 'onMount' | 'onFABClick';
7
+
8
+ export interface SDKConfig {
9
+ apiKey: string;
10
+ user?: SDKUser;
11
+ screenshotCompression?: {
12
+ useWebWorker?: boolean;
13
+ };
14
+ onboarding?: OnboardingTrigger;
15
+ }
16
+
17
+ export type SDKEvent =
18
+ | 'issue:created'
19
+ | 'issue:cancelled'
20
+ | 'issue:updated'
21
+ | 'issue:clicked'
22
+ | 'mode:changed'
23
+ | 'recording:started'
24
+ | 'recording:stopped'
25
+ | 'recording:failed'
26
+ | 'auth:login'
27
+ | 'auth:logout'
28
+ | 'ready'
29
+ | 'error';
2
30
 
3
31
  export interface UseIssueStickerConfig extends SDKConfig {
4
32
  enabled?: boolean;
@@ -14,5 +42,4 @@ export declare const IssueSticker: {
14
42
 
15
43
  export declare function useIssueSticker(config: UseIssueStickerConfig): void;
16
44
 
17
- export type { SDKConfig, SDKEvent, SDKUser };
18
45
  export default IssueSticker;
package/dist/index.d.ts DELETED
@@ -1,25 +0,0 @@
1
- declare const IssueSticker: {
2
- init(config: SDKConfig): void;
3
- destroy(): void;
4
- on(event: SDKEvent, callback: (...args: unknown[]) => void): void;
5
- off(event: SDKEvent, callback: (...args: unknown[]) => void): void;
6
- };
7
- export { IssueSticker }
8
- export default IssueSticker;
9
-
10
- export declare interface SDKConfig {
11
- apiKey: string;
12
- user?: SDKUser;
13
- screenshotCompression?: {
14
- useWebWorker?: boolean;
15
- };
16
- }
17
-
18
- export declare type SDKEvent = 'issue:created' | 'issue:updated' | 'issue:clicked' | 'mode:changed' | 'recording:started' | 'recording:stopped' | 'auth:login' | 'auth:logout' | 'ready' | 'error';
19
-
20
- export declare interface SDKUser {
21
- id: string;
22
- name: string;
23
- }
24
-
25
- export { }