@almadar/ui 2.15.8 → 2.15.11
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/dist/components/atoms/ContentSection.d.ts +16 -0
- package/dist/components/atoms/SectionHeader.d.ts +14 -0
- package/dist/components/atoms/StatCard.d.ts +13 -0
- package/dist/components/atoms/index.d.ts +3 -0
- package/dist/components/atoms/svg/SvgBranch.d.ts +12 -0
- package/dist/components/atoms/svg/SvgConnection.d.ts +13 -0
- package/dist/components/atoms/svg/SvgFlow.d.ts +10 -0
- package/dist/components/atoms/svg/SvgGrid.d.ts +14 -0
- package/dist/components/atoms/svg/SvgLobe.d.ts +13 -0
- package/dist/components/atoms/svg/SvgMesh.d.ts +12 -0
- package/dist/components/atoms/svg/SvgMorph.d.ts +11 -0
- package/dist/components/atoms/svg/SvgNode.d.ts +12 -0
- package/dist/components/atoms/svg/SvgPulse.d.ts +12 -0
- package/dist/components/atoms/svg/SvgRing.d.ts +13 -0
- package/dist/components/atoms/svg/SvgShield.d.ts +11 -0
- package/dist/components/atoms/svg/SvgStack.d.ts +13 -0
- package/dist/components/atoms/svg/index.d.ts +12 -0
- package/dist/{chunk-ACUO2BBW.js → components/index.cjs} +24831 -16747
- package/dist/components/index.js +37754 -889
- package/dist/components/molecules/AnimatedCounter.d.ts +18 -0
- package/dist/components/molecules/ArticleSection.d.ts +18 -0
- package/dist/components/molecules/CTABanner.d.ts +31 -0
- package/dist/components/molecules/CaseStudyCard.d.ts +24 -0
- package/dist/components/molecules/CodeExample.d.ts +23 -0
- package/dist/components/molecules/CommunityLinks.d.ts +25 -0
- package/dist/components/molecules/DocBreadcrumb.d.ts +20 -0
- package/dist/components/molecules/DocCodeBlock.d.ts +13 -0
- package/dist/components/molecules/DocPagination.d.ts +14 -0
- package/dist/components/molecules/DocSearch.d.ts +15 -0
- package/dist/components/molecules/DocSidebar.d.ts +24 -0
- package/dist/components/molecules/DocTOC.d.ts +24 -0
- package/dist/components/molecules/FeatureCard.d.ts +26 -0
- package/dist/components/molecules/FeatureGrid.d.ts +19 -0
- package/dist/components/molecules/GradientDivider.d.ts +14 -0
- package/dist/components/molecules/HeroSection.d.ts +36 -0
- package/dist/components/molecules/InstallBox.d.ts +16 -0
- package/dist/components/molecules/MarketingFooter.d.ts +27 -0
- package/dist/components/molecules/PricingCard.d.ts +21 -0
- package/dist/components/molecules/PricingGrid.d.ts +13 -0
- package/dist/components/molecules/PullQuote.d.ts +14 -0
- package/dist/components/molecules/ServiceCatalog.d.ts +19 -0
- package/dist/components/molecules/ShowcaseCard.d.ts +20 -0
- package/dist/components/molecules/SocialProof.d.ts +25 -0
- package/dist/components/molecules/SplitSection.d.ts +21 -0
- package/dist/components/molecules/StatsGrid.d.ts +17 -0
- package/dist/components/molecules/StepFlow.d.ts +20 -0
- package/dist/components/molecules/TagCloud.d.ts +18 -0
- package/dist/components/molecules/TeamCard.d.ts +18 -0
- package/dist/components/molecules/index.d.ts +19 -0
- package/dist/components/molecules/svg/AIGenerates.d.ts +7 -0
- package/dist/components/molecules/svg/ClosedCircuit.d.ts +7 -0
- package/dist/components/molecules/svg/CommunityOwnership.d.ts +7 -0
- package/dist/components/molecules/svg/CompileAnywhere.d.ts +7 -0
- package/dist/components/molecules/svg/ComposableModels.d.ts +7 -0
- package/dist/components/molecules/svg/DescribeProveDeploy.d.ts +7 -0
- package/dist/components/molecules/svg/DomainGrid.d.ts +7 -0
- package/dist/components/molecules/svg/EventBus.d.ts +7 -0
- package/dist/components/molecules/svg/OrbitalUnit.d.ts +7 -0
- package/dist/components/molecules/svg/PlanVerifyRemember.d.ts +7 -0
- package/dist/components/molecules/svg/ProveCorrect.d.ts +7 -0
- package/dist/components/molecules/svg/ServiceLayers.d.ts +7 -0
- package/dist/components/molecules/svg/SharedReality.d.ts +7 -0
- package/dist/components/molecules/svg/StandardLibrary.d.ts +7 -0
- package/dist/components/molecules/svg/StateMachine.d.ts +7 -0
- package/dist/components/molecules/svg/WorldModel.d.ts +7 -0
- package/dist/components/molecules/svg/index.d.ts +16 -0
- package/dist/components/organisms/CaseStudyOrganism.d.ts +19 -0
- package/dist/components/organisms/FeatureGridOrganism.d.ts +20 -0
- package/dist/components/organisms/HeroOrganism.d.ts +18 -0
- package/dist/components/organisms/PricingOrganism.d.ts +19 -0
- package/dist/components/organisms/ShowcaseOrganism.d.ts +20 -0
- package/dist/components/organisms/StatsOrganism.d.ts +17 -0
- package/dist/components/organisms/StepFlowOrganism.d.ts +20 -0
- package/dist/components/organisms/TeamOrganism.d.ts +18 -0
- package/dist/components/organisms/game/three/index.cjs +2525 -0
- package/dist/components/organisms/game/three/index.js +1795 -50
- package/dist/components/organisms/index.d.ts +9 -0
- package/dist/components/organisms/marketing-types.d.ts +87 -0
- package/dist/components/templates/AboutPageTemplate.d.ts +26 -0
- package/dist/components/templates/FeatureDetailPageTemplate.d.ts +27 -0
- package/dist/components/templates/LandingPageTemplate.d.ts +31 -0
- package/dist/components/templates/PricingPageTemplate.d.ts +26 -0
- package/dist/components/templates/index.d.ts +4 -0
- package/dist/context/index.cjs +550 -0
- package/dist/context/index.js +420 -6
- package/dist/docs/index.cjs +4015 -0
- package/dist/docs/index.d.cts +412 -0
- package/dist/docs/index.d.ts +29 -0
- package/dist/docs/index.js +3977 -0
- package/dist/hooks/index.cjs +2606 -0
- package/dist/hooks/index.js +2535 -8
- package/dist/illustrations/index.cjs +3004 -0
- package/dist/illustrations/index.d.cts +261 -0
- package/dist/illustrations/index.d.ts +35 -0
- package/dist/illustrations/index.js +2971 -0
- package/dist/{chunk-XL7WB2O5.js → lib/index.cjs} +454 -274
- package/dist/lib/index.js +1407 -3
- package/dist/locales/index.cjs +340 -0
- package/dist/locales/index.js +105 -2
- package/dist/marketing/index.cjs +4680 -0
- package/dist/marketing/index.d.cts +831 -0
- package/dist/marketing/index.d.ts +62 -0
- package/dist/marketing/index.js +4623 -0
- package/dist/providers/index.cjs +4811 -0
- package/dist/providers/index.js +4765 -11
- package/dist/{chunk-K2D5D3WK.js → renderer/index.cjs} +101 -42
- package/dist/renderer/index.js +1036 -2
- package/dist/runtime/index.cjs +4400 -0
- package/dist/runtime/index.js +3615 -19
- package/dist/{chunk-N7MVUW4R.js → stores/index.cjs} +24 -1
- package/dist/stores/index.js +194 -2
- package/dist/tsup.config.d.ts +2 -1
- package/package.json +27 -12
- package/tailwind-preset.cjs +9 -0
- package/themes/almadar-website.css +195 -0
- package/themes/index.css +23 -20
- package/dist/chunk-3HJHHULT.js +0 -93
- package/dist/chunk-3JGAROCW.js +0 -149
- package/dist/chunk-4N3BAPDB.js +0 -1667
- package/dist/chunk-CDIOHSKG.js +0 -661
- package/dist/chunk-DKQN5FVU.js +0 -279
- package/dist/chunk-JJHCOO34.js +0 -375
- package/dist/chunk-PKBMQBKP.js +0 -5
- package/dist/chunk-QIABKRCN.js +0 -107
- package/dist/chunk-SD3KVCY6.js +0 -1465
- package/dist/chunk-YXZM3WCF.js +0 -222
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
1
3
|
// stores/filtering.ts
|
|
2
4
|
function getDateString(value) {
|
|
3
5
|
if (!value) return null;
|
|
@@ -191,4 +193,25 @@ function getFilterSnapshot() {
|
|
|
191
193
|
return filters;
|
|
192
194
|
}
|
|
193
195
|
|
|
194
|
-
|
|
196
|
+
exports.applyFilters = applyFilters;
|
|
197
|
+
exports.clearAllFilters = clearAllFilters;
|
|
198
|
+
exports.clearEntities = clearEntities;
|
|
199
|
+
exports.clearFilter = clearFilter;
|
|
200
|
+
exports.createFilter = createFilter;
|
|
201
|
+
exports.getAllEntities = getAllEntities;
|
|
202
|
+
exports.getByType = getByType;
|
|
203
|
+
exports.getByTypeFiltered = getByTypeFiltered;
|
|
204
|
+
exports.getDateString = getDateString;
|
|
205
|
+
exports.getEntities = getEntities;
|
|
206
|
+
exports.getEntity = getEntity;
|
|
207
|
+
exports.getFilterSnapshot = getFilterSnapshot;
|
|
208
|
+
exports.getFilters = getFilters;
|
|
209
|
+
exports.getSingleton = getSingleton;
|
|
210
|
+
exports.getSnapshot = getSnapshot;
|
|
211
|
+
exports.matchesFilter = matchesFilter;
|
|
212
|
+
exports.removeEntity = removeEntity;
|
|
213
|
+
exports.setFilter = setFilter;
|
|
214
|
+
exports.spawnEntity = spawnEntity;
|
|
215
|
+
exports.subscribe = subscribe;
|
|
216
|
+
exports.updateEntity = updateEntity;
|
|
217
|
+
exports.updateSingleton = updateSingleton;
|
package/dist/stores/index.js
CHANGED
|
@@ -1,2 +1,194 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
// stores/filtering.ts
|
|
2
|
+
function getDateString(value) {
|
|
3
|
+
if (!value) return null;
|
|
4
|
+
if (typeof value === "string") {
|
|
5
|
+
const match = value.match(/^(\d{4}-\d{2}-\d{2})/);
|
|
6
|
+
return match ? match[1] : null;
|
|
7
|
+
}
|
|
8
|
+
if (value instanceof Date) {
|
|
9
|
+
return value.toISOString().split("T")[0];
|
|
10
|
+
}
|
|
11
|
+
return null;
|
|
12
|
+
}
|
|
13
|
+
function matchesFilter(record, filter) {
|
|
14
|
+
const fieldToCompare = filter.targetField || filter.field;
|
|
15
|
+
const recordValue = record[fieldToCompare];
|
|
16
|
+
const filterValue = filter.value;
|
|
17
|
+
const operator = filter.operator || "eq";
|
|
18
|
+
if (filterValue === null || filterValue === void 0 || filterValue === "") {
|
|
19
|
+
return true;
|
|
20
|
+
}
|
|
21
|
+
switch (operator) {
|
|
22
|
+
case "eq":
|
|
23
|
+
if (typeof recordValue === "string" && typeof filterValue === "string") {
|
|
24
|
+
return recordValue.toLowerCase() === filterValue.toLowerCase();
|
|
25
|
+
}
|
|
26
|
+
return recordValue === filterValue;
|
|
27
|
+
case "contains":
|
|
28
|
+
if (typeof recordValue !== "string") return false;
|
|
29
|
+
return recordValue.toLowerCase().includes(String(filterValue).toLowerCase());
|
|
30
|
+
case "in":
|
|
31
|
+
if (Array.isArray(filterValue)) {
|
|
32
|
+
const normalizedFilterValues = filterValue.map(
|
|
33
|
+
(v) => typeof v === "string" ? v.toLowerCase() : v
|
|
34
|
+
);
|
|
35
|
+
const normalizedRecordValue = typeof recordValue === "string" ? recordValue.toLowerCase() : recordValue;
|
|
36
|
+
return normalizedFilterValues.includes(normalizedRecordValue);
|
|
37
|
+
}
|
|
38
|
+
return false;
|
|
39
|
+
case "date_eq": {
|
|
40
|
+
const recordDate = getDateString(recordValue);
|
|
41
|
+
const filterDate = getDateString(filterValue);
|
|
42
|
+
return Boolean(recordDate && filterDate && recordDate === filterDate);
|
|
43
|
+
}
|
|
44
|
+
case "date_gte": {
|
|
45
|
+
const recordDate = getDateString(recordValue);
|
|
46
|
+
const filterDate = getDateString(filterValue);
|
|
47
|
+
return Boolean(recordDate && filterDate && recordDate >= filterDate);
|
|
48
|
+
}
|
|
49
|
+
case "date_lte": {
|
|
50
|
+
const recordDate = getDateString(recordValue);
|
|
51
|
+
const filterDate = getDateString(filterValue);
|
|
52
|
+
return Boolean(recordDate && filterDate && recordDate <= filterDate);
|
|
53
|
+
}
|
|
54
|
+
case "search": {
|
|
55
|
+
if (typeof filterValue !== "string" || !filterValue.trim()) {
|
|
56
|
+
return true;
|
|
57
|
+
}
|
|
58
|
+
const searchTerm = filterValue.toLowerCase();
|
|
59
|
+
return Object.values(record).some((value) => {
|
|
60
|
+
if (value === null || value === void 0) return false;
|
|
61
|
+
return String(value).toLowerCase().includes(searchTerm);
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
default:
|
|
65
|
+
return true;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
function applyFilters(records, entityFilters) {
|
|
69
|
+
if (entityFilters.size === 0) return records;
|
|
70
|
+
return records.filter((record) => {
|
|
71
|
+
for (const [, filter] of entityFilters) {
|
|
72
|
+
if (!matchesFilter(record, filter)) {
|
|
73
|
+
return false;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
return true;
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
function createFilter(field, value, operator = "eq", targetField) {
|
|
80
|
+
return {
|
|
81
|
+
field,
|
|
82
|
+
value,
|
|
83
|
+
operator,
|
|
84
|
+
targetField: targetField || field
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
// stores/entityStore.ts
|
|
89
|
+
var entities = /* @__PURE__ */ new Map();
|
|
90
|
+
var filters = /* @__PURE__ */ new Map();
|
|
91
|
+
var listeners = /* @__PURE__ */ new Set();
|
|
92
|
+
var idCounter = 0;
|
|
93
|
+
function subscribe(listener) {
|
|
94
|
+
listeners.add(listener);
|
|
95
|
+
return () => listeners.delete(listener);
|
|
96
|
+
}
|
|
97
|
+
function notify() {
|
|
98
|
+
listeners.forEach((listener) => listener());
|
|
99
|
+
}
|
|
100
|
+
function getEntities() {
|
|
101
|
+
return entities;
|
|
102
|
+
}
|
|
103
|
+
function getEntity(id) {
|
|
104
|
+
return entities.get(id);
|
|
105
|
+
}
|
|
106
|
+
function getByType(type) {
|
|
107
|
+
const types = Array.isArray(type) ? type : [type];
|
|
108
|
+
return [...entities.values()].filter((e) => types.includes(e.type));
|
|
109
|
+
}
|
|
110
|
+
function getAllEntities() {
|
|
111
|
+
return [...entities.values()];
|
|
112
|
+
}
|
|
113
|
+
function getSingleton(type) {
|
|
114
|
+
return [...entities.values()].find((e) => e.type === type);
|
|
115
|
+
}
|
|
116
|
+
function spawnEntity(config) {
|
|
117
|
+
const id = config.id ?? `entity_${++idCounter}`;
|
|
118
|
+
const entity = { ...config, id };
|
|
119
|
+
entities = new Map(entities);
|
|
120
|
+
entities.set(id, entity);
|
|
121
|
+
notify();
|
|
122
|
+
return id;
|
|
123
|
+
}
|
|
124
|
+
function updateEntity(id, updates) {
|
|
125
|
+
const entity = entities.get(id);
|
|
126
|
+
if (entity) {
|
|
127
|
+
entities = new Map(entities);
|
|
128
|
+
entities.set(id, { ...entity, ...updates });
|
|
129
|
+
notify();
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
function updateSingleton(type, updates) {
|
|
133
|
+
const entity = getSingleton(type);
|
|
134
|
+
if (entity) {
|
|
135
|
+
updateEntity(entity.id, updates);
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
function removeEntity(id) {
|
|
139
|
+
if (entities.has(id)) {
|
|
140
|
+
entities = new Map(entities);
|
|
141
|
+
entities.delete(id);
|
|
142
|
+
notify();
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
function clearEntities() {
|
|
146
|
+
entities = /* @__PURE__ */ new Map();
|
|
147
|
+
notify();
|
|
148
|
+
}
|
|
149
|
+
function setFilter(entityType, field, value, operator = "eq", targetField) {
|
|
150
|
+
filters = new Map(filters);
|
|
151
|
+
const entityFilters = new Map(filters.get(entityType) || []);
|
|
152
|
+
entityFilters.set(field, createFilter(field, value, operator, targetField));
|
|
153
|
+
filters.set(entityType, entityFilters);
|
|
154
|
+
notify();
|
|
155
|
+
}
|
|
156
|
+
function clearFilter(entityType, field) {
|
|
157
|
+
const entityFilters = filters.get(entityType);
|
|
158
|
+
if (entityFilters && entityFilters.has(field)) {
|
|
159
|
+
filters = new Map(filters);
|
|
160
|
+
const newFilters = new Map(entityFilters);
|
|
161
|
+
newFilters.delete(field);
|
|
162
|
+
filters.set(entityType, newFilters);
|
|
163
|
+
notify();
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
function clearAllFilters(entityType) {
|
|
167
|
+
if (filters.has(entityType)) {
|
|
168
|
+
filters = new Map(filters);
|
|
169
|
+
filters.set(entityType, /* @__PURE__ */ new Map());
|
|
170
|
+
notify();
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
function getFilters(entityType) {
|
|
174
|
+
return filters.get(entityType) || /* @__PURE__ */ new Map();
|
|
175
|
+
}
|
|
176
|
+
function getByTypeFiltered(type) {
|
|
177
|
+
const types = Array.isArray(type) ? type : [type];
|
|
178
|
+
let result = [...entities.values()].filter((e) => types.includes(e.type));
|
|
179
|
+
for (const t of types) {
|
|
180
|
+
const typeFilters = filters.get(t);
|
|
181
|
+
if (typeFilters && typeFilters.size > 0) {
|
|
182
|
+
result = applyFilters(result, typeFilters);
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
return result;
|
|
186
|
+
}
|
|
187
|
+
function getSnapshot() {
|
|
188
|
+
return entities;
|
|
189
|
+
}
|
|
190
|
+
function getFilterSnapshot() {
|
|
191
|
+
return filters;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
export { applyFilters, clearAllFilters, clearEntities, clearFilter, createFilter, getAllEntities, getByType, getByTypeFiltered, getDateString, getEntities, getEntity, getFilterSnapshot, getFilters, getSingleton, getSnapshot, matchesFilter, removeEntity, setFilter, spawnEntity, subscribe, updateEntity, updateSingleton };
|
package/dist/tsup.config.d.ts
CHANGED
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
1
|
+
import { type Options } from 'tsup';
|
|
2
|
+
declare const _default: Options | Options[] | ((overrideOptions: Options) => Options | Options[] | Promise<Options | Options[]>);
|
|
2
3
|
export default _default;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@almadar/ui",
|
|
3
|
-
"version": "2.15.
|
|
3
|
+
"version": "2.15.11",
|
|
4
4
|
"description": "React UI components, hooks, and providers for Almadar",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/components/index.js",
|
|
@@ -10,52 +10,52 @@
|
|
|
10
10
|
".": {
|
|
11
11
|
"types": "./dist/components/index.d.ts",
|
|
12
12
|
"import": "./dist/components/index.js",
|
|
13
|
-
"require": "./dist/components/index.
|
|
13
|
+
"require": "./dist/components/index.cjs"
|
|
14
14
|
},
|
|
15
15
|
"./components": {
|
|
16
16
|
"types": "./dist/components/index.d.ts",
|
|
17
17
|
"import": "./dist/components/index.js",
|
|
18
|
-
"require": "./dist/components/index.
|
|
18
|
+
"require": "./dist/components/index.cjs"
|
|
19
19
|
},
|
|
20
20
|
"./hooks": {
|
|
21
21
|
"types": "./dist/hooks/index.d.ts",
|
|
22
22
|
"import": "./dist/hooks/index.js",
|
|
23
|
-
"require": "./dist/hooks/index.
|
|
23
|
+
"require": "./dist/hooks/index.cjs"
|
|
24
24
|
},
|
|
25
25
|
"./providers": {
|
|
26
26
|
"types": "./dist/providers/index.d.ts",
|
|
27
27
|
"import": "./dist/providers/index.js",
|
|
28
|
-
"require": "./dist/providers/index.
|
|
28
|
+
"require": "./dist/providers/index.cjs"
|
|
29
29
|
},
|
|
30
30
|
"./context": {
|
|
31
31
|
"types": "./dist/context/index.d.ts",
|
|
32
32
|
"import": "./dist/context/index.js",
|
|
33
|
-
"require": "./dist/context/index.
|
|
33
|
+
"require": "./dist/context/index.cjs"
|
|
34
34
|
},
|
|
35
35
|
"./renderer": {
|
|
36
36
|
"types": "./dist/renderer/index.d.ts",
|
|
37
37
|
"import": "./dist/renderer/index.js",
|
|
38
|
-
"require": "./dist/renderer/index.
|
|
38
|
+
"require": "./dist/renderer/index.cjs"
|
|
39
39
|
},
|
|
40
40
|
"./runtime": {
|
|
41
41
|
"types": "./dist/runtime/index.d.ts",
|
|
42
42
|
"import": "./dist/runtime/index.js",
|
|
43
|
-
"require": "./dist/runtime/index.
|
|
43
|
+
"require": "./dist/runtime/index.cjs"
|
|
44
44
|
},
|
|
45
45
|
"./stores": {
|
|
46
46
|
"types": "./dist/stores/index.d.ts",
|
|
47
47
|
"import": "./dist/stores/index.js",
|
|
48
|
-
"require": "./dist/stores/index.
|
|
48
|
+
"require": "./dist/stores/index.cjs"
|
|
49
49
|
},
|
|
50
50
|
"./lib": {
|
|
51
51
|
"types": "./dist/lib/index.d.ts",
|
|
52
52
|
"import": "./dist/lib/index.js",
|
|
53
|
-
"require": "./dist/lib/index.
|
|
53
|
+
"require": "./dist/lib/index.cjs"
|
|
54
54
|
},
|
|
55
55
|
"./components/organisms/game/three": {
|
|
56
56
|
"types": "./dist/components/organisms/game/three/index.d.ts",
|
|
57
57
|
"import": "./dist/components/organisms/game/three/index.js",
|
|
58
|
-
"require": "./dist/components/organisms/game/three/index.
|
|
58
|
+
"require": "./dist/components/organisms/game/three/index.cjs"
|
|
59
59
|
},
|
|
60
60
|
"./components/organisms/game/TraitStateViewer": {
|
|
61
61
|
"import": "./components/organisms/game/TraitStateViewer.tsx",
|
|
@@ -69,11 +69,26 @@
|
|
|
69
69
|
"import": "./templates/index.ts",
|
|
70
70
|
"types": "./templates/index.ts"
|
|
71
71
|
},
|
|
72
|
+
"./marketing": {
|
|
73
|
+
"types": "./dist/marketing/index.d.ts",
|
|
74
|
+
"import": "./dist/marketing/index.js",
|
|
75
|
+
"require": "./dist/marketing/index.cjs"
|
|
76
|
+
},
|
|
77
|
+
"./docs": {
|
|
78
|
+
"types": "./dist/docs/index.d.ts",
|
|
79
|
+
"import": "./dist/docs/index.js",
|
|
80
|
+
"require": "./dist/docs/index.cjs"
|
|
81
|
+
},
|
|
82
|
+
"./illustrations": {
|
|
83
|
+
"types": "./dist/illustrations/index.d.ts",
|
|
84
|
+
"import": "./dist/illustrations/index.js",
|
|
85
|
+
"require": "./dist/illustrations/index.cjs"
|
|
86
|
+
},
|
|
72
87
|
"./themes/*.css": "./themes/*.css",
|
|
73
88
|
"./locales": {
|
|
74
89
|
"types": "./dist/locales/index.d.ts",
|
|
75
90
|
"import": "./dist/locales/index.js",
|
|
76
|
-
"require": "./dist/locales/index.
|
|
91
|
+
"require": "./dist/locales/index.cjs"
|
|
77
92
|
},
|
|
78
93
|
"./locales/en.json": "./locales/en.json",
|
|
79
94
|
"./locales/ar.json": "./locales/ar.json",
|
package/tailwind-preset.cjs
CHANGED
|
@@ -177,6 +177,15 @@ module.exports = {
|
|
|
177
177
|
'text-[var(--color-warning)]',
|
|
178
178
|
'text-[var(--color-warning-foreground)]',
|
|
179
179
|
'to-[var(--color-accent)]',
|
|
180
|
+
// Hover elevation & micro-interactions
|
|
181
|
+
'hover:-translate-y-0.5',
|
|
182
|
+
'hover:-translate-y-1',
|
|
183
|
+
'hover:scale-105',
|
|
184
|
+
'scale-[1.05]',
|
|
185
|
+
'transition-all',
|
|
186
|
+
'duration-200',
|
|
187
|
+
'ring-2',
|
|
188
|
+
'ring-[var(--color-primary)]',
|
|
180
189
|
],
|
|
181
190
|
theme: {
|
|
182
191
|
fontFamily: {
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Almadar Website Theme
|
|
3
|
+
*
|
|
4
|
+
* Brand-accurate theme for almadar.io based on Almadar Brand Guidelines.
|
|
5
|
+
* Teal primary, Cyan accent, Sand Gold highlights, Plus Jakarta Sans typography.
|
|
6
|
+
* Dark hero sections with light content sections (mixed mode).
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
/* ==========================================================================
|
|
10
|
+
* LIGHT MODE (content sections)
|
|
11
|
+
* ========================================================================== */
|
|
12
|
+
[data-theme="almadar-website-light"] {
|
|
13
|
+
/* Shadows */
|
|
14
|
+
--shadow-main: 0 4px 14px rgba(20, 184, 166, 0.1), 0 1px 3px rgba(0, 0, 0, 0.05);
|
|
15
|
+
--shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.04);
|
|
16
|
+
--shadow-lg: 0 8px 30px rgba(20, 184, 166, 0.12), 0 4px 10px rgba(0, 0, 0, 0.04);
|
|
17
|
+
--shadow-inner: inset 0 1px 2px rgba(0, 0, 0, 0.04);
|
|
18
|
+
--shadow-none: none;
|
|
19
|
+
--shadow-hover: 0 12px 40px rgba(20, 184, 166, 0.15);
|
|
20
|
+
--shadow-active: 0 2px 8px rgba(20, 184, 166, 0.1);
|
|
21
|
+
|
|
22
|
+
/* Border radius */
|
|
23
|
+
--radius-none: 0px;
|
|
24
|
+
--radius-sm: 6px;
|
|
25
|
+
--radius-md: 10px;
|
|
26
|
+
--radius-lg: 14px;
|
|
27
|
+
--radius-xl: 20px;
|
|
28
|
+
--radius-full: 9999px;
|
|
29
|
+
|
|
30
|
+
/* Border width */
|
|
31
|
+
--border-width: 1px;
|
|
32
|
+
--border-width-thin: 1px;
|
|
33
|
+
--border-width-thick: 2px;
|
|
34
|
+
|
|
35
|
+
/* Colors - Teal on parchment */
|
|
36
|
+
--color-primary: #14b8a6;
|
|
37
|
+
--color-primary-hover: #0d9488;
|
|
38
|
+
--color-primary-foreground: #ffffff;
|
|
39
|
+
|
|
40
|
+
--color-secondary: #f1f5f9;
|
|
41
|
+
--color-secondary-hover: #e2e8f0;
|
|
42
|
+
--color-secondary-foreground: #0f172a;
|
|
43
|
+
|
|
44
|
+
--color-accent: #06b6d4;
|
|
45
|
+
--color-accent-foreground: #ffffff;
|
|
46
|
+
|
|
47
|
+
--color-muted: #f1f5f9;
|
|
48
|
+
--color-muted-foreground: #64748b;
|
|
49
|
+
|
|
50
|
+
--color-background: #ffffff;
|
|
51
|
+
--color-foreground: #0f172a;
|
|
52
|
+
--color-card: #ffffff;
|
|
53
|
+
--color-card-foreground: #0f172a;
|
|
54
|
+
--color-surface: #f8fafc;
|
|
55
|
+
--color-border: #e2e8f0;
|
|
56
|
+
--color-input: #e2e8f0;
|
|
57
|
+
--color-ring: #14b8a6;
|
|
58
|
+
|
|
59
|
+
/* Sand Gold for special accents */
|
|
60
|
+
--color-gold: #c9a227;
|
|
61
|
+
|
|
62
|
+
/* Semantic colors */
|
|
63
|
+
--color-error: #dc2626;
|
|
64
|
+
--color-error-foreground: #ffffff;
|
|
65
|
+
--color-success: #22c55e;
|
|
66
|
+
--color-success-foreground: #ffffff;
|
|
67
|
+
--color-warning: #f59e0b;
|
|
68
|
+
--color-warning-foreground: #000000;
|
|
69
|
+
--color-info: #3b82f6;
|
|
70
|
+
--color-info-foreground: #ffffff;
|
|
71
|
+
|
|
72
|
+
/* Typography - Plus Jakarta Sans per brand guidelines */
|
|
73
|
+
--font-family: "Plus Jakarta Sans", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
|
|
74
|
+
--font-weight-normal: 400;
|
|
75
|
+
--font-weight-medium: 500;
|
|
76
|
+
--font-weight-bold: 700;
|
|
77
|
+
--letter-spacing: -0.02em;
|
|
78
|
+
--line-height: 1.6;
|
|
79
|
+
|
|
80
|
+
/* Icon styling */
|
|
81
|
+
--icon-stroke-width: 1.75;
|
|
82
|
+
--icon-color: #14b8a6;
|
|
83
|
+
|
|
84
|
+
/* Transitions */
|
|
85
|
+
--transition-fast: 150ms;
|
|
86
|
+
--transition-normal: 250ms;
|
|
87
|
+
--transition-slow: 400ms;
|
|
88
|
+
--transition-timing: cubic-bezier(0.4, 0, 0.2, 1);
|
|
89
|
+
|
|
90
|
+
/* Hover/Active */
|
|
91
|
+
--hover-scale: 1.02;
|
|
92
|
+
--hover-translate-y: -2px;
|
|
93
|
+
--hover-translate-x: 0;
|
|
94
|
+
--active-scale: 0.98;
|
|
95
|
+
--active-translate-y: 0;
|
|
96
|
+
|
|
97
|
+
/* Focus ring */
|
|
98
|
+
--focus-ring-width: 2px;
|
|
99
|
+
--focus-ring-offset: 2px;
|
|
100
|
+
--focus-ring-color: #14b8a6;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
/* ==========================================================================
|
|
104
|
+
* DARK MODE (hero sections, dark backgrounds)
|
|
105
|
+
* ========================================================================== */
|
|
106
|
+
[data-theme="almadar-website-dark"] {
|
|
107
|
+
/* Shadows - Teal glow */
|
|
108
|
+
--shadow-main: 0 4px 14px rgba(20, 184, 166, 0.15), 0 1px 3px rgba(0, 0, 0, 0.1);
|
|
109
|
+
--shadow-sm: 0 2px 4px rgba(20, 184, 166, 0.1);
|
|
110
|
+
--shadow-lg: 0 8px 30px rgba(20, 184, 166, 0.25), 0 4px 10px rgba(0, 0, 0, 0.1);
|
|
111
|
+
--shadow-inner: inset 0 1px 2px rgba(0, 0, 0, 0.1);
|
|
112
|
+
--shadow-none: none;
|
|
113
|
+
--shadow-hover: 0 12px 40px rgba(20, 184, 166, 0.35), 0 4px 12px rgba(6, 182, 212, 0.2);
|
|
114
|
+
--shadow-active: 0 2px 8px rgba(20, 184, 166, 0.2);
|
|
115
|
+
|
|
116
|
+
/* Border radius */
|
|
117
|
+
--radius-none: 0px;
|
|
118
|
+
--radius-sm: 6px;
|
|
119
|
+
--radius-md: 10px;
|
|
120
|
+
--radius-lg: 14px;
|
|
121
|
+
--radius-xl: 20px;
|
|
122
|
+
--radius-full: 9999px;
|
|
123
|
+
|
|
124
|
+
/* Border width */
|
|
125
|
+
--border-width: 1px;
|
|
126
|
+
--border-width-thin: 1px;
|
|
127
|
+
--border-width-thick: 2px;
|
|
128
|
+
|
|
129
|
+
/* Colors - Teal/Cyan on Midnight Blue */
|
|
130
|
+
--color-primary: #14b8a6;
|
|
131
|
+
--color-primary-hover: #2dd4bf;
|
|
132
|
+
--color-primary-foreground: #042f2e;
|
|
133
|
+
|
|
134
|
+
--color-secondary: #1e293b;
|
|
135
|
+
--color-secondary-hover: #334155;
|
|
136
|
+
--color-secondary-foreground: #f1f5f9;
|
|
137
|
+
|
|
138
|
+
--color-accent: #06b6d4;
|
|
139
|
+
--color-accent-foreground: #083344;
|
|
140
|
+
|
|
141
|
+
--color-muted: #1e293b;
|
|
142
|
+
--color-muted-foreground: #94a3b8;
|
|
143
|
+
|
|
144
|
+
--color-background: #0f172a;
|
|
145
|
+
--color-foreground: #f1f5f9;
|
|
146
|
+
--color-card: #1e293b;
|
|
147
|
+
--color-card-foreground: #f1f5f9;
|
|
148
|
+
--color-surface: #1e293b;
|
|
149
|
+
--color-border: #334155;
|
|
150
|
+
--color-input: rgba(20, 184, 166, 0.3);
|
|
151
|
+
--color-ring: #14b8a6;
|
|
152
|
+
|
|
153
|
+
/* Sand Gold for special accents */
|
|
154
|
+
--color-gold: #c9a227;
|
|
155
|
+
|
|
156
|
+
/* Semantic colors */
|
|
157
|
+
--color-error: #f87171;
|
|
158
|
+
--color-error-foreground: #000000;
|
|
159
|
+
--color-success: #4ade80;
|
|
160
|
+
--color-success-foreground: #000000;
|
|
161
|
+
--color-warning: #fbbf24;
|
|
162
|
+
--color-warning-foreground: #000000;
|
|
163
|
+
--color-info: #38bdf8;
|
|
164
|
+
--color-info-foreground: #000000;
|
|
165
|
+
|
|
166
|
+
/* Typography */
|
|
167
|
+
--font-family: "Plus Jakarta Sans", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
|
|
168
|
+
--font-weight-normal: 400;
|
|
169
|
+
--font-weight-medium: 500;
|
|
170
|
+
--font-weight-bold: 700;
|
|
171
|
+
--letter-spacing: -0.02em;
|
|
172
|
+
--line-height: 1.6;
|
|
173
|
+
|
|
174
|
+
/* Icon styling */
|
|
175
|
+
--icon-stroke-width: 1.75;
|
|
176
|
+
--icon-color: #14b8a6;
|
|
177
|
+
|
|
178
|
+
/* Transitions */
|
|
179
|
+
--transition-fast: 150ms;
|
|
180
|
+
--transition-normal: 250ms;
|
|
181
|
+
--transition-slow: 400ms;
|
|
182
|
+
--transition-timing: cubic-bezier(0.4, 0, 0.2, 1);
|
|
183
|
+
|
|
184
|
+
/* Hover/Active */
|
|
185
|
+
--hover-scale: 1.02;
|
|
186
|
+
--hover-translate-y: -2px;
|
|
187
|
+
--hover-translate-x: 0;
|
|
188
|
+
--active-scale: 0.98;
|
|
189
|
+
--active-translate-y: 0;
|
|
190
|
+
|
|
191
|
+
/* Focus ring */
|
|
192
|
+
--focus-ring-width: 2px;
|
|
193
|
+
--focus-ring-offset: 2px;
|
|
194
|
+
--focus-ring-color: #14b8a6;
|
|
195
|
+
}
|
package/themes/index.css
CHANGED
|
@@ -4,8 +4,31 @@
|
|
|
4
4
|
* Each theme provides both light and dark modes via:
|
|
5
5
|
* [data-theme="themename-light"] { ... }
|
|
6
6
|
* [data-theme="themename-dark"] { ... }
|
|
7
|
+
*
|
|
8
|
+
* IMPORTANT: @import must precede all other statements (Vite requirement).
|
|
7
9
|
*/
|
|
8
10
|
|
|
11
|
+
/* Core themes */
|
|
12
|
+
@import "./wireframe.css";
|
|
13
|
+
@import "./minimalist.css";
|
|
14
|
+
@import "./almadar.css";
|
|
15
|
+
@import "./almadar-website.css";
|
|
16
|
+
@import "./trait-wars.css";
|
|
17
|
+
|
|
18
|
+
/* Extended themes */
|
|
19
|
+
@import "./ocean.css";
|
|
20
|
+
@import "./forest.css";
|
|
21
|
+
@import "./sunset.css";
|
|
22
|
+
@import "./lavender.css";
|
|
23
|
+
@import "./rose.css";
|
|
24
|
+
@import "./slate.css";
|
|
25
|
+
@import "./ember.css";
|
|
26
|
+
@import "./midnight.css";
|
|
27
|
+
@import "./sand.css";
|
|
28
|
+
@import "./neon.css";
|
|
29
|
+
@import "./arctic.css";
|
|
30
|
+
@import "./copper.css";
|
|
31
|
+
|
|
9
32
|
/**
|
|
10
33
|
* Minimal element reset for @almadar/ui components.
|
|
11
34
|
*
|
|
@@ -56,23 +79,3 @@
|
|
|
56
79
|
#ui-slot-portal-root h6 {
|
|
57
80
|
font-family: var(--font-family, inherit);
|
|
58
81
|
}
|
|
59
|
-
|
|
60
|
-
/* Core themes */
|
|
61
|
-
@import "./wireframe.css";
|
|
62
|
-
@import "./minimalist.css";
|
|
63
|
-
@import "./almadar.css";
|
|
64
|
-
@import "./trait-wars.css";
|
|
65
|
-
|
|
66
|
-
/* Extended themes */
|
|
67
|
-
@import "./ocean.css";
|
|
68
|
-
@import "./forest.css";
|
|
69
|
-
@import "./sunset.css";
|
|
70
|
-
@import "./lavender.css";
|
|
71
|
-
@import "./rose.css";
|
|
72
|
-
@import "./slate.css";
|
|
73
|
-
@import "./ember.css";
|
|
74
|
-
@import "./midnight.css";
|
|
75
|
-
@import "./sand.css";
|
|
76
|
-
@import "./neon.css";
|
|
77
|
-
@import "./arctic.css";
|
|
78
|
-
@import "./copper.css";
|
package/dist/chunk-3HJHHULT.js
DELETED
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
// lib/api-client.ts
|
|
2
|
-
var API_BASE_URL = typeof process !== "undefined" && process.env?.VITE_API_URL ? process.env.VITE_API_URL : "/api";
|
|
3
|
-
var ApiError = class extends Error {
|
|
4
|
-
constructor(status, statusText, message) {
|
|
5
|
-
super(message || `API Error: ${status} ${statusText}`);
|
|
6
|
-
this.status = status;
|
|
7
|
-
this.statusText = statusText;
|
|
8
|
-
this.name = "ApiError";
|
|
9
|
-
}
|
|
10
|
-
};
|
|
11
|
-
async function handleResponse(response) {
|
|
12
|
-
if (!response.ok) {
|
|
13
|
-
let message;
|
|
14
|
-
try {
|
|
15
|
-
const errorData = await response.json();
|
|
16
|
-
message = errorData.message || errorData.error;
|
|
17
|
-
} catch {
|
|
18
|
-
}
|
|
19
|
-
throw new ApiError(response.status, response.statusText, message);
|
|
20
|
-
}
|
|
21
|
-
const text = await response.text();
|
|
22
|
-
if (!text) {
|
|
23
|
-
return void 0;
|
|
24
|
-
}
|
|
25
|
-
return JSON.parse(text);
|
|
26
|
-
}
|
|
27
|
-
function getHeaders() {
|
|
28
|
-
const headers = {
|
|
29
|
-
"Content-Type": "application/json"
|
|
30
|
-
};
|
|
31
|
-
const token = typeof localStorage !== "undefined" ? localStorage.getItem("authToken") : null;
|
|
32
|
-
if (token) {
|
|
33
|
-
headers["Authorization"] = `Bearer ${token}`;
|
|
34
|
-
}
|
|
35
|
-
return headers;
|
|
36
|
-
}
|
|
37
|
-
var apiClient = {
|
|
38
|
-
/**
|
|
39
|
-
* GET request
|
|
40
|
-
*/
|
|
41
|
-
async get(endpoint) {
|
|
42
|
-
const response = await fetch(`${API_BASE_URL}${endpoint}`, {
|
|
43
|
-
method: "GET",
|
|
44
|
-
headers: getHeaders()
|
|
45
|
-
});
|
|
46
|
-
return handleResponse(response);
|
|
47
|
-
},
|
|
48
|
-
/**
|
|
49
|
-
* POST request
|
|
50
|
-
*/
|
|
51
|
-
async post(endpoint, data) {
|
|
52
|
-
const response = await fetch(`${API_BASE_URL}${endpoint}`, {
|
|
53
|
-
method: "POST",
|
|
54
|
-
headers: getHeaders(),
|
|
55
|
-
body: data ? JSON.stringify(data) : void 0
|
|
56
|
-
});
|
|
57
|
-
return handleResponse(response);
|
|
58
|
-
},
|
|
59
|
-
/**
|
|
60
|
-
* PUT request
|
|
61
|
-
*/
|
|
62
|
-
async put(endpoint, data) {
|
|
63
|
-
const response = await fetch(`${API_BASE_URL}${endpoint}`, {
|
|
64
|
-
method: "PUT",
|
|
65
|
-
headers: getHeaders(),
|
|
66
|
-
body: data ? JSON.stringify(data) : void 0
|
|
67
|
-
});
|
|
68
|
-
return handleResponse(response);
|
|
69
|
-
},
|
|
70
|
-
/**
|
|
71
|
-
* PATCH request
|
|
72
|
-
*/
|
|
73
|
-
async patch(endpoint, data) {
|
|
74
|
-
const response = await fetch(`${API_BASE_URL}${endpoint}`, {
|
|
75
|
-
method: "PATCH",
|
|
76
|
-
headers: getHeaders(),
|
|
77
|
-
body: data ? JSON.stringify(data) : void 0
|
|
78
|
-
});
|
|
79
|
-
return handleResponse(response);
|
|
80
|
-
},
|
|
81
|
-
/**
|
|
82
|
-
* DELETE request
|
|
83
|
-
*/
|
|
84
|
-
async delete(endpoint) {
|
|
85
|
-
const response = await fetch(`${API_BASE_URL}${endpoint}`, {
|
|
86
|
-
method: "DELETE",
|
|
87
|
-
headers: getHeaders()
|
|
88
|
-
});
|
|
89
|
-
return handleResponse(response);
|
|
90
|
-
}
|
|
91
|
-
};
|
|
92
|
-
|
|
93
|
-
export { ApiError, apiClient };
|