ape-im-sdk-react 1.0.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.
@@ -0,0 +1,145 @@
1
+ :root {
2
+ --ape-im-primary: #1D3FE7;
3
+ --ape-im-primary-dark: #142B99;
4
+ --ape-im-primary-light: #E8EDFF;
5
+ --ape-im-accent: #0054FA;
6
+ --ape-im-bubble-user: #1D3FE7;
7
+ --ape-im-bubble-other: #e5e5e5;
8
+ --ape-im-text: #000000;
9
+ --ape-im-text-muted: #666666;
10
+ --ape-im-bg: #c0c0c0;
11
+ --ape-im-bg-elevated: #e0e0e0;
12
+ --ape-im-border: #808080;
13
+ }
14
+
15
+ .ape-im-dark {
16
+ --ape-im-text: #ffffff;
17
+ --ape-im-text-muted: #888888;
18
+ --ape-im-bg: #1a1a1a;
19
+ --ape-im-bg-elevated: #2a2a2a;
20
+ --ape-im-border: #404040;
21
+ --ape-im-bubble-other: #404040;
22
+ }
23
+
24
+ .ape-im-widget {
25
+ font-family: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
26
+ font-size: 14px;
27
+ line-height: 1.5;
28
+ color: var(--ape-im-text);
29
+ }
30
+
31
+ .ape-im-widget * {
32
+ box-sizing: border-box;
33
+ }
34
+
35
+ .ape-im-widget button {
36
+ font-family: inherit;
37
+ }
38
+
39
+ .ape-im-scrollbar::-webkit-scrollbar {
40
+ width: 14px;
41
+ height: 14px;
42
+ }
43
+
44
+ .ape-im-scrollbar::-webkit-scrollbar-track {
45
+ background: var(--ape-im-border);
46
+ border: 1px solid var(--ape-im-bg);
47
+ }
48
+
49
+ .ape-im-scrollbar::-webkit-scrollbar-thumb {
50
+ background: var(--ape-im-bg);
51
+ border: 2px outset var(--ape-im-bg-elevated);
52
+ }
53
+
54
+ .ape-im-scrollbar::-webkit-scrollbar-thumb:hover {
55
+ background: var(--ape-im-bg-elevated);
56
+ }
57
+
58
+ .ape-im-scrollbar::-webkit-scrollbar-corner {
59
+ background: var(--ape-im-border);
60
+ }
61
+
62
+ .ape-im-retro-button {
63
+ background: linear-gradient(135deg, var(--ape-im-primary) 0%, var(--ape-im-primary-dark) 100%);
64
+ color: white;
65
+ border: 2px outset #5577ff;
66
+ padding: 8px 16px;
67
+ font-weight: bold;
68
+ cursor: pointer;
69
+ transition: all 0.1s;
70
+ }
71
+
72
+ .ape-im-retro-button:hover {
73
+ filter: brightness(1.1);
74
+ }
75
+
76
+ .ape-im-retro-button:active {
77
+ border-style: inset;
78
+ transform: translateY(1px);
79
+ }
80
+
81
+ .ape-im-retro-input {
82
+ padding: 8px 12px;
83
+ border: 2px inset var(--ape-im-border);
84
+ background: var(--ape-im-bg-elevated);
85
+ color: var(--ape-im-text);
86
+ font-size: 13px;
87
+ outline: none;
88
+ }
89
+
90
+ .ape-im-retro-input:focus {
91
+ border-color: var(--ape-im-primary);
92
+ }
93
+
94
+ .ape-im-message-bubble {
95
+ max-width: 80%;
96
+ padding: 8px 12px;
97
+ border-radius: 4px;
98
+ font-size: 13px;
99
+ box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
100
+ }
101
+
102
+ .ape-im-message-bubble--user {
103
+ background: var(--ape-im-bubble-user);
104
+ color: white;
105
+ }
106
+
107
+ .ape-im-message-bubble--other {
108
+ background: var(--ape-im-bubble-other);
109
+ color: var(--ape-im-text);
110
+ }
111
+
112
+ .ape-im-title-bar {
113
+ background: linear-gradient(90deg, var(--ape-im-primary) 0%, var(--ape-im-primary-dark) 100%);
114
+ padding: 6px 8px;
115
+ display: flex;
116
+ align-items: center;
117
+ justify-content: space-between;
118
+ color: white;
119
+ font-weight: bold;
120
+ font-size: 12px;
121
+ }
122
+
123
+ .ape-im-window {
124
+ background: var(--ape-im-bg);
125
+ border: 2px solid var(--ape-im-border);
126
+ box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.3), inset 1px 1px 0 rgba(255, 255, 255, 0.3);
127
+ }
128
+
129
+ @keyframes ape-im-typing {
130
+ 0%, 60%, 100% { opacity: 0.3; }
131
+ 30% { opacity: 1; }
132
+ }
133
+
134
+ .ape-im-typing-dot {
135
+ display: inline-block;
136
+ width: 6px;
137
+ height: 6px;
138
+ border-radius: 50%;
139
+ background: var(--ape-im-text-muted);
140
+ margin: 0 2px;
141
+ animation: ape-im-typing 1.4s infinite;
142
+ }
143
+
144
+ .ape-im-typing-dot:nth-child(2) { animation-delay: 0.2s; }
145
+ .ape-im-typing-dot:nth-child(3) { animation-delay: 0.4s; }
package/package.json ADDED
@@ -0,0 +1,58 @@
1
+ {
2
+ "name": "ape-im-sdk-react",
3
+ "version": "1.0.0",
4
+ "description": "React SDK for Ape Instant Messenger - Add nostalgic AOL-style chat to your ApeChain dApp",
5
+ "main": "dist/index.cjs.js",
6
+ "module": "dist/index.esm.js",
7
+ "types": "dist/index.d.ts",
8
+ "files": [
9
+ "dist",
10
+ "README.md"
11
+ ],
12
+ "exports": {
13
+ ".": {
14
+ "import": "./dist/index.esm.js",
15
+ "require": "./dist/index.cjs.js",
16
+ "types": "./dist/index.d.ts"
17
+ },
18
+ "./styles.css": "./dist/styles.css"
19
+ },
20
+ "scripts": {
21
+ "copy-styles": "node -e \"require('fs').copyFileSync('src/styles.css', 'dist/styles.css')\"",
22
+ "build": "tsup src/index.ts --format cjs,esm --dts --external react --external react-dom && npm run copy-styles",
23
+ "dev": "tsup src/index.ts --format cjs,esm --dts --watch",
24
+ "prepublishOnly": "npm run build"
25
+ },
26
+ "peerDependencies": {
27
+ "react": ">=18.0.0",
28
+ "react-dom": ">=18.0.0"
29
+ },
30
+ "devDependencies": {
31
+ "@types/react": "^18.2.0",
32
+ "@types/react-dom": "^18.2.0",
33
+ "tsup": "^8.0.0",
34
+ "typescript": "^5.0.0"
35
+ },
36
+ "keywords": [
37
+ "apechain",
38
+ "chat",
39
+ "messaging",
40
+ "web3",
41
+ "react",
42
+ "aim",
43
+ "instant-messenger",
44
+ "nft",
45
+ "crypto",
46
+ "wallet"
47
+ ],
48
+ "author": "Ape IM Team",
49
+ "license": "MIT",
50
+ "repository": {
51
+ "type": "git",
52
+ "url": "https://github.com/ape-im/sdk-react"
53
+ },
54
+ "homepage": "https://ape-im.replit.app/docs",
55
+ "bugs": {
56
+ "url": "https://github.com/ape-im/sdk-react/issues"
57
+ }
58
+ }