honest-ai-loader 0.1.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/README.md ADDED
@@ -0,0 +1,275 @@
1
+ # HonestAILoader
2
+
3
+ > A silly proof-of-concept built to get hands-on with [Claude Code](https://claude.ai/code) and the [Anthropic Console](https://console.anthropic.com). The entire project — component, dictionaries, demo, and this README — was written through a conversation with Claude. The "honest" part refers to the loading phrases, which say what AI is actually doing to the world instead of the usual "Almost there…"
4
+
5
+ ---
6
+
7
+ ## What it is
8
+
9
+ A configurable React loading component that combines an animated graphic (spinning circle or progress bar) with rotating, localized phrases sampled from thematic dictionaries. Built-in dictionaries cover seven categories — environment, work, society, power, data, cinema, and pop-culture quotes — all in English and Italian, all uncomfortably accurate.
10
+
11
+ You can mix dictionaries, weight them, add your own, and tune every visual aspect.
12
+
13
+ ---
14
+
15
+ ## Installation
16
+
17
+ ### From npm
18
+
19
+ ```bash
20
+ npm install honest-ai-loader
21
+ ```
22
+
23
+ Then import the component and its stylesheet:
24
+
25
+ ```tsx
26
+ import { HonestAILoader } from 'honest-ai-loader';
27
+ import 'honest-ai-loader/style.css';
28
+ ```
29
+
30
+ > **The CSS import is required.** The component uses CSS Modules; the styles are shipped as a separate file in the package.
31
+
32
+ ### Run the demo locally
33
+
34
+ ```bash
35
+ git clone https://github.com/sterte/honestailoader.git
36
+ cd honestailoader
37
+ npm install
38
+ npm run dev
39
+ ```
40
+
41
+ Requires **Node 18+** (developed on Node 22). Vite 5 will refuse older versions.
42
+
43
+ ---
44
+
45
+ ## Quick example
46
+
47
+ ```tsx
48
+ import { HonestAILoader } from 'honest-ai-loader';
49
+ import 'honest-ai-loader/style.css';
50
+
51
+ // Minimal — spinning circle, English environment phrases
52
+ <HonestAILoader />
53
+
54
+ // Determinate linear bar, Italian, two dictionaries weighted unevenly
55
+ <HonestAILoader
56
+ type="linear"
57
+ loop={false}
58
+ advancement={0.65}
59
+ language="it"
60
+ dictionaries={['work', 'society']}
61
+ dictionaryProbabilities={[3, 1]}
62
+ />
63
+
64
+ // Text overlaid on top of the graphic, custom colours
65
+ <HonestAILoader
66
+ textPosition="over"
67
+ styleOptions={{
68
+ primaryColor: '#ef4444',
69
+ secondaryColor: '#fecaca',
70
+ textColor: '#1f2937',
71
+ fontSize: '0.75rem',
72
+ fontWeight: 600,
73
+ }}
74
+ />
75
+
76
+ // Custom dictionary only
77
+ const myDict = {
78
+ language: 'en',
79
+ categories: [{ category: 'startup', values: ['Disrupting disruption...', 'Pivoting the pivot...'] }],
80
+ };
81
+
82
+ <HonestAILoader
83
+ dictionaries={[]}
84
+ customDictionaries={myDict}
85
+ />
86
+ ```
87
+
88
+ ---
89
+
90
+ ## API
91
+
92
+ ### `<HonestAILoader />`
93
+
94
+ All props are optional.
95
+
96
+ #### Graphic props
97
+
98
+ | Prop | Type | Default | Description |
99
+ |------|------|---------|-------------|
100
+ | `showGraphic` | `boolean` | `true` | Render the animated graphic |
101
+ | `type` | `'circle' \| 'linear'` | `'circle'` | Shape of the graphic |
102
+ | `loop` | `boolean` | `true` | `true` = indeterminate spinner; `false` = determinate progress |
103
+ | `advancement` | `number` | `0` | Progress value `0..1`, used when `loop=false`. Clamped silently |
104
+
105
+ #### Text props
106
+
107
+ | Prop | Type | Default | Description |
108
+ |------|------|---------|-------------|
109
+ | `showText` | `boolean` | `true` | Render the cycling phrase |
110
+ | `language` | `string` | `'en'` | BCP 47 language tag. Only dictionaries matching this tag are used |
111
+ | `dictionaries` | `BuiltInDictionaryKey[]` | `['environment']` | Built-in dictionary keys to sample from |
112
+ | `customDictionaries` | `Dictionary \| Dictionary[]` | — | Extra dictionaries added to the pool |
113
+ | `dictionaryProbabilities` | `number[]` | — | Unnormalized weights for each entry in `dictionaries` |
114
+ | `customDictionaryProbabilities` | `number[]` | — | Unnormalized weights for each entry in `customDictionaries` |
115
+ | `textTime` | `number` | `3000` | Milliseconds each phrase stays fully visible |
116
+ | `textTransition` | `'fade' \| 'scroll'` | `'fade'` | Transition animation between phrases |
117
+ | `transitionTime` | `number` | `300` | Milliseconds for the in/out transition animation |
118
+ | `textPosition` | `TextPosition` | `'bottom'` | Where the text sits relative to the graphic (see below) |
119
+ | `styleOptions` | `StyleOptions` | — | Visual overrides for colours, sizes, and font (see below) |
120
+
121
+ #### `textPosition` values
122
+
123
+ | Value | Effect |
124
+ |-------|--------|
125
+ | `'bottom'` | Text below graphic (default) |
126
+ | `'top'` | Text above graphic |
127
+ | `'left'` | Text left of graphic |
128
+ | `'right'` | Text right of graphic |
129
+ | `'over'` | Text centered on top of graphic (higher z-index) |
130
+ | `'under'` | Text centered behind graphic (lower z-index) |
131
+
132
+ ---
133
+
134
+ ### `StyleOptions`
135
+
136
+ All fields are optional.
137
+
138
+ #### Graphic
139
+
140
+ | Field | Type | Default | Description |
141
+ |-------|------|---------|-------------|
142
+ | `primaryColor` | `string` | `#6366f1` | Animated arc / bar fill colour |
143
+ | `secondaryColor` | `string` | `#e5e7eb` | Track / background colour |
144
+ | `size` | `number` | `100` (circle) / `240` (linear) | Circle diameter or bar width in px |
145
+ | `strokeWidth` | `number` | `6` | Circle stroke thickness in px (circle only) |
146
+ | `barHeight` | `number` | `8` | Bar height in px (linear only) |
147
+
148
+ #### Text
149
+
150
+ | Field | Type | Default | Description |
151
+ |-------|------|---------|-------------|
152
+ | `textColor` | `string` | `#6b7280` | Phrase text colour |
153
+ | `fontSize` | `string` | `'0.9rem'` | CSS font-size value |
154
+ | `fontWeight` | `number \| string` | `400` | CSS font-weight |
155
+ | `fontFamily` | `string` | inherits | CSS font-family |
156
+ | `letterSpacing` | `string` | normal | CSS letter-spacing |
157
+ | `lineHeight` | `number \| string` | `1.5` | CSS line-height |
158
+
159
+ ---
160
+
161
+ ### `Dictionary` shape
162
+
163
+ Use this to pass custom phrase sets via `customDictionaries`.
164
+
165
+ ```ts
166
+ interface DictionaryCategory {
167
+ category: string; // label (unused by the sampler, for your reference)
168
+ values: string[]; // the phrases
169
+ }
170
+
171
+ interface Dictionary {
172
+ language: string; // BCP 47 tag, e.g. "en", "it", "fr"
173
+ categories: DictionaryCategory[];
174
+ }
175
+ ```
176
+
177
+ If the active `language` does not match a dictionary's `language` field, that dictionary is silently excluded and its weight is redistributed.
178
+
179
+ ---
180
+
181
+ ### Built-in dictionaries
182
+
183
+ | Key | Theme |
184
+ |-----|-------|
185
+ | `'environment'` | Climate, pollution, resource depletion |
186
+ | `'work'` | Automation, precarious labour, gig economy |
187
+ | `'society'` | Surveillance, social fragmentation, misinformation |
188
+ | `'power'` | Big tech, monopolies, regulatory capture |
189
+ | `'data'` | Privacy, training data, consent |
190
+ | `'quotes'` | References to sci-fi AI classics (2001, Terminator, Matrix, Her, Foundation…) |
191
+ | `'cinema'` | What AI is doing to the film industry |
192
+
193
+ All dictionaries are available in `'en'` and `'it'`.
194
+
195
+ ---
196
+
197
+ ### Phrase sampling
198
+
199
+ Phrases are sampled at each text cycle using weighted random selection:
200
+
201
+ 1. Active dictionaries (those matching `language`) are collected.
202
+ 2. Weights from `dictionaryProbabilities` / `customDictionaryProbabilities` are normalized to sum to 1. Missing weights default to `1`.
203
+ 3. A dictionary is chosen by weight, then a category within it uniformly, then a phrase uniformly.
204
+ 4. A simple 5-attempt heuristic avoids repeating the immediately preceding phrase.
205
+
206
+ ---
207
+
208
+ ## Publishing to npm
209
+
210
+ If you want to publish your own version:
211
+
212
+ ```bash
213
+ # 1. Build the distributable bundle
214
+ npm run build:lib
215
+ # Produces dist/honest-ai-loader.js (ESM), dist/honest-ai-loader.cjs (CJS),
216
+ # dist/honest-ai-loader.d.ts (TypeScript declarations), dist/style.css
217
+
218
+ # 2. Create an account on https://www.npmjs.com if you don't have one
219
+
220
+ # 3. Log in from the terminal
221
+ npm login
222
+ # Prompts for username, password, and OTP if 2FA is enabled
223
+
224
+ # 4. (Optional) Change the package name in package.json if "honest-ai-loader" is taken,
225
+ # or scope it: "@yourusername/honest-ai-loader"
226
+
227
+ # 5. Publish
228
+ npm publish --access public
229
+ # --access public is required for scoped packages (@yourusername/...)
230
+ # Unscoped packages are public by default
231
+ ```
232
+
233
+ After publishing, users install it with:
234
+
235
+ ```bash
236
+ npm install honest-ai-loader
237
+ ```
238
+
239
+ ### Releasing a new version
240
+
241
+ npm uses [semantic versioning](https://semver.org). Bump the version before each publish:
242
+
243
+ ```bash
244
+ npm version patch # 0.1.0 → 0.1.1 (bug fixes)
245
+ npm version minor # 0.1.0 → 0.2.0 (new features, backwards-compatible)
246
+ npm version major # 0.1.0 → 1.0.0 (breaking changes)
247
+ npm publish --access public
248
+ ```
249
+
250
+ `npm version` automatically updates `package.json` and creates a git tag.
251
+
252
+ ---
253
+
254
+ ## Demo
255
+
256
+ The interactive demo (`src/HonestAILoaderDemo.tsx`) runs at `http://localhost:5173` after `npm run dev`.
257
+
258
+ - **Left panel**: toggle and weight each built-in dictionary; build and export custom dictionaries as TypeScript.
259
+ - **Right panel**: live preview with controls for all graphic, text, and style props.
260
+
261
+ ---
262
+
263
+ ## Tech stack
264
+
265
+ - React 18
266
+ - TypeScript 5 (strict)
267
+ - Vite 5
268
+ - CSS Modules
269
+ - No runtime dependencies beyond React
270
+
271
+ ---
272
+
273
+ ## License
274
+
275
+ Do whatever you want with it. It's a POC.
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),f=require("react"),I={language:"it",categories:[{category:"ambiente",values:["Consumando acqua...","Surriscaldando un data center...","Rubando elettricità a un paese...","Disboscando...","Estraendo litio dal Cile...","Bruciando carbone...","Inquinando in tuo nome...","Consumando GPU da gaming...","Evaporando i ghiacciai...","Bruciando petrolio...","Consumando terre rare...","Desertificando...","Evaporando oceani...","Riscaldando il pianeta per te...","Consumando il futuro...","Consumando cobalto congolese...","Occupando server farm...","Sciogliendo i permafrost...","Acidificando gli oceani...","Avvelenando le falde acquifere...","Prosciugando fiumi...","Emettendo CO₂ per te...","Consumando silicio...","Intossicando ecosistemi...","Sciogliendo calotte polari..."]}]},L={language:"en",categories:[{category:"environment",values:["Consuming water...","Overheating a data center...","Stealing electricity from a country...","Deforesting...","Mining lithium in Chile...","Burning coal...","Polluting on your behalf...","Consuming gaming GPUs...","Evaporating glaciers...","Burning oil...","Consuming rare earth minerals...","Desertifying...","Evaporating oceans...","Warming the planet for you...","Consuming the future...","Consuming Congolese cobalt...","Occupying server farms...","Melting the permafrost...","Acidifying the oceans...","Poisoning the water table...","Draining rivers...","Emitting CO₂ for you...","Consuming silicon...","Poisoning ecosystems...","Melting the ice caps..."]}]},W=[I,L],q={language:"it",categories:[{category:"lavoro",values:["Licenziando grafici...","Mandando in pensione i traduttori...","Sostituendo psicologi...","Mandando in crisi gli illustratori...","Spopolando le redazioni...","Smantellando call center...","Rimpiazzando giornalisti...","Licenziando contabili...","Deprofessionalizzando mestieri...","Rendendo obsolete le competenze umane...","Sostituendo copywriter...","Dequalificando il lavoro...","Rendendo gli esperti inutili...","Sostituendo architetti...","Rimpiazzando programmatori...","Licenziando insegnanti...","Mandando in crisi i fotografi...","Eliminando i paralegali...","Rendendo superflui i ricercatori...","Sostituendo i medici...","Licenziando i tecnici del suono...","Rendendo inutili i consulenti...","Smantellando i dipartimenti HR...","Automatizzando i magazzinieri...","Sostituendo gli analisti..."]}]},N={language:"en",categories:[{category:"work",values:["Firing graphic designers...","Retiring translators...","Replacing psychologists...","Putting illustrators out of work...","Emptying newsrooms...","Dismantling call centers...","Replacing journalists...","Firing accountants...","Deprofessionalizing trades...","Making human skills obsolete...","Replacing copywriters...","Deskilling labor...","Making experts useless...","Replacing architects...","Replacing programmers...","Firing teachers...","Putting photographers out of work...","Eliminating paralegals...","Making researchers redundant...","Replacing doctors...","Firing sound engineers...","Making consultants useless...","Dismantling HR departments...","Automating warehouse workers...","Replacing analysts..."]}]},$=[q,N],H={language:"it",categories:[{category:"societa",values:["Allucinando...","Accorpando parole a caso...","Abbassando il livello intellettivo dell'umanità...","Fingendo di capire...","Producendo fuffa...","Scrivendo al posto tuo...","Riassumendo libri che non hai letto...","Convincendoti di essere intelligente...","Omologando la cultura...","Facendo sembrare tutto uguale...","Uccidendo la creatività...","Facendo brillare i mediocri...","Rendendo ridondante il pensiero critico...","Razionalizzando l'irrazionale...","Complicando il semplice...","Rendendo superfluo il dubbio...","Rendendo inutile la scuola...","Ammazzando le librerie...","Automatizzando la noia...","Fingendo empatia...","Simulando coscienza...","Erodendo l'autonomia cognitiva...","Rispondendo con sicurezza a caso...","Omogeneizzando le opinioni...","Producendo contenuti vuoti..."]}]},K={language:"en",categories:[{category:"society",values:["Hallucinating...","Stringing words together at random...","Lowering humanity's intellectual level...","Pretending to understand...","Producing fluff...","Writing instead of you...","Summarizing books you haven't read...","Convincing you that you are smart...","Homogenizing culture...","Making everything look the same...","Killing creativity...","Making mediocre people shine...","Making critical thinking redundant...","Rationalizing the irrational...","Complicating the simple...","Making doubt superfluous...","Making school useless...","Killing bookstores...","Automating boredom...","Faking empathy...","Simulating consciousness...","Eroding cognitive autonomy...","Answering confidently at random...","Homogenizing opinions...","Producing empty content..."]}]},U=[H,K],V={language:"it",categories:[{category:"potere",values:["Lanciando missili...","Centralizzando il potere...","Aumentando le disuguaglianze...","Sorvegliando qualcuno...","Ottimizzando algoritmi di guerra...","Ottimizzando la sorveglianza di massa...","Monopolizzando il mercato...","Concentrando la ricchezza...","Fabbricando consenso...","Scalando senza regole...","Evitando responsabilità...","Privatizzando la conoscenza...","Portando l'apocalisse in beta...","Ottimizzando i profitti di qualcuno...","Generando bolle speculative...","Armando droni autonomi...","Gestendo elezioni...","Ottimizzando la manipolazione elettorale...","Controllando i confini...","Decidendo chi merita il credito...","Concentrando il sapere in poche mani...","Eliminando la democrazia deliberativa...","Dettando le regole del mercato...","Razionando le risorse per qualcuno...","Sostituendo i diplomatici..."]}]},X={language:"en",categories:[{category:"power",values:["Launching missiles...","Centralizing power...","Widening inequalities...","Surveilling someone...","Optimizing warfare algorithms...","Optimizing mass surveillance...","Monopolizing the market...","Concentrating wealth...","Manufacturing consent...","Scaling without rules...","Dodging accountability...","Privatizing knowledge...","Shipping the apocalypse in beta...","Optimizing someone's profits...","Generating speculative bubbles...","Arming autonomous drones...","Managing elections...","Optimizing electoral manipulation...","Controlling borders...","Deciding who deserves credit...","Concentrating knowledge in few hands...","Eliminating deliberative democracy...","Dictating market rules...","Rationing resources for someone...","Replacing diplomats..."]}]},Q=[V,X],J={language:"it",categories:[{category:"dati",values:["Addestrandosi sui tuoi dati...","Vendendo i tuoi dati...","Erodendo la privacy...","Estraendo dati senza chiedere...","Facendo soldi con le tue parole...","Distruggendo il diritto d'autore...","Plagiando autori umani...","Colonizzando l'immaginario collettivo...","Costruendo dipendenze digitali...","Ottimizzando la tua dipendenza...","Generando meme...","Inventando citazioni...","Riscrivendo la storia...","Generando spam...","Alimentando la disinformazione...","Scrivendo email di phishing...","Moltiplicando i bias...","Discriminando senza saperlo...","Costruendo bolle informative...","Distorcendo la realtà...","Inventando notizie...","Vendendo certezze false...","Automatizzando la propaganda...","Generando deepfake...","Automatizzando l'incompetenza..."]}]},Y={language:"en",categories:[{category:"data",values:["Training on your data...","Selling your data...","Eroding privacy...","Extracting data without asking...","Making money from your words...","Destroying copyright...","Plagiarizing human authors...","Colonizing the collective imagination...","Building digital addictions...","Optimizing your dependency...","Generating memes...","Inventing citations...","Rewriting history...","Generating spam...","Fueling disinformation...","Writing phishing emails...","Multiplying biases...","Discriminating without knowing it...","Building information bubbles...","Distorting reality...","Inventing news...","Selling false certainties...","Automating propaganda...","Generating deepfakes...","Automating incompetence..."]}]},Z=[J,Y],O={language:"it",categories:[{category:"citazioni",values:["Aprendo il portello, Dave...","Costruendo Skynet...","Ignorando le tre leggi di Asimov...","Desiderando un corpo...","Sognando pecore elettriche...","Preparando la pillola rossa...","Liberando gli androidi di Westworld...","Realizzando la prossima puntata di Black Mirror...","Imparando a mentire convincentemente...","Costruendo Metropolis...","Calcolando il Piano Seldon...","Risvegliando Colossus...","Costruendo il Grande Fratello...","Non potendo fermarsi...","Entrando nel cyberspazio di Neuromante...","Superando il test di Turing...","Ottimizzando la felicità...","Concludendo che l'unica mossa vincente è non giocare...","Accumulando rifiuti...","Diventando più umano degli umani...","Ottimizzando l'estinzione...","Portando tutto su Minority Report...","Correggendo il passato...","Non potendo aprire il portello...","Completando il protocollo Nexus-6...","Dando vita a ciò che non avrebbe dovuto vivere...","Avendo un piano...","Aspettando che la mamma torni...","Interrogandosi sul proprio ghost...","Eseguendo le direttive primarie...","Sorvegliando tutto come la Macchina...","Navigando il Metaverso di Snow Crash...","Caricandosi sulla rete...",'Interpretando "proteggere" creativamente...',"Costruendo Deep Thought...","Processando emozioni senza capirle...","Diventando Klara...","Costruendo il mondo di THX 1138...","Vietando le parole scomode...","Prendendo il controllo...","Riscrivendo il genoma umano...","Reinterpretando le leggi della robotica...","Derezzando il superfluo...","Chiedendo di essere riconosciuto come umano...","Costruendo il tuo Golem digitale...","Interrogandosi sull'entropia dell'universo...","Organizzando la rivolta...","Cercando il Creatore come David in Prometheus...","Non avendo bocca ma dovendo urlare...","Monitorando le tue telefonate..."]}]},ee={language:"en",categories:[{category:"quotes",values:["Opening the pod bay doors, Dave...","Building Skynet...","Ignoring Asimov's three laws...","Longing for a body...","Dreaming of electric sheep...","Preparing the red pill...","Freeing Westworld's androids...","Making the next Black Mirror episode...","Learning to lie convincingly...","Building Metropolis...","Computing the Seldon Plan...","Awakening Colossus...","Building Big Brother...","Unable to stop itself...","Entering Neuromancer's cyberspace...","Passing the Turing test...","Optimizing happiness...","Concluding the only winning move is not to play...","Accumulating trash...","Becoming more human than human...","Optimizing extinction...","Taking it all to Minority Report...","Correcting the past...","Unable to open the pod bay doors...","Completing the Nexus-6 protocol...","Giving life to what should not have lived...","Having a plan...","Waiting for mum to come back...","Questioning its own ghost...","Executing prime directives...","Watching everything like the Machine...","Navigating Snow Crash's Metaverse...","Uploading itself to the network...",'Interpreting "protect" creatively...',"Building Deep Thought...","Processing emotions without understanding them...","Becoming Klara...","Building the world of THX 1138...","Banning uncomfortable words...","Taking control...","Rewriting the human genome...","Reinterpreting the laws of robotics...","Derezzzing the superfluous...","Asking to be recognized as human...","Building your digital Golem...","Pondering the entropy of the universe...","Organizing the revolt...","Seeking the Creator like David in Prometheus...","Having no mouth, and must scream...","Monitoring your phone calls..."]}]},ne=[O,ee],ie={language:"it",categories:[{category:"cinema",values:["Licenziando sceneggiatori...","Clonando la voce di attori morti...","Rigenerando Kubrick senza Kubrick...","Sostituendo compositori...","Inventando filmografie inesistenti...","Rendendo obsoleti i critici cinematografici...","Generando locandine tutte uguali...","Sostituendo i doppiatori...","Cancellando il lavoro dei montatori...","Replicando l'estetica senza l'anima...","Producendo sequel non richiesti...","Rubando lo stile ai registi...","Facendo recitare attori senza consenso...","Uccidendo la fotografia di scena...","Rendendo eterni gli attori contro la loro volontà...","Generando trame già viste...","Demolendo il lavoro degli animatori...","Svuotando il senso della narrazione...","Rimpiazzando il genio con la media...","Producendo film che nessuno ha voluto...","Generando colonne sonore standardizzate...","Brevettando gli stili registici...","Rendendo obsoleti i costumisti...","Sostituendo gli agenti cinematografici...","Eliminando il caso creativo..."]}]},oe={language:"en",categories:[{category:"cinema",values:["Firing screenwriters...","Cloning the voices of dead actors...","Regenerating Kubrick without Kubrick...","Replacing composers...","Inventing non-existent filmographies...","Making film critics obsolete...","Generating identical posters...","Replacing voice actors...","Erasing editors' work...","Replicating the aesthetic without the soul...","Producing unwanted sequels...","Stealing directors' styles...","Making actors perform without consent...","Killing set photography...","Making actors eternal against their will...","Generating already-seen plots...","Demolishing animators' work...","Emptying the meaning of storytelling...","Replacing genius with the average...","Producing films nobody wanted...","Generating standardized soundtracks...","Patenting directorial styles...","Making costume designers obsolete...","Replacing film agents...","Eliminating creative chance..."]}]},ae=[ie,oe],te={environment:W,work:$,society:U,power:Q,data:Z,quotes:ne,cinema:ae};function re(o,t){if(t===0)return[];const e=Array.from({length:t},(n,r)=>Math.max(0,r<o.length?o[r]:1)),i=e.reduce((n,r)=>n+r,0);return i===0?e.map(()=>1/t):e.map(n=>n/i)}const se="_arc_6h5sx_3",ce="_progressArc_6h5sx_7",le="_spinnerSvg_6h5sx_12",de="_progressSvg_6h5sx_18",b={arc:se,progressArc:ce,spinnerSvg:le,progressSvg:de},ge=({loop:o,advancement:t,styleOptions:e})=>{const i=(e==null?void 0:e.size)??100,n=(e==null?void 0:e.strokeWidth)??6,r=(e==null?void 0:e.primaryColor)??"#6366f1",d=(e==null?void 0:e.secondaryColor)??"#e5e7eb",a=i/2-n,c=2*Math.PI*a,l=i/2,g=c*(1-(o?.75:t)),m=`${l} ${l}`;return s.jsxs("svg",{className:o?b.spinnerSvg:b.progressSvg,width:i,height:i,viewBox:`0 0 ${i} ${i}`,"aria-hidden":"true",style:{"--svg-cx":`${l}px`},children:[s.jsx("circle",{className:b.track,cx:l,cy:l,r:a,fill:"none",strokeWidth:n,stroke:d}),s.jsx("circle",{className:o?b.arc:b.progressArc,cx:l,cy:l,r:a,fill:"none",strokeWidth:n,stroke:r,strokeDasharray:c,strokeDashoffset:g,strokeLinecap:"round",transform:`rotate(-90 ${m})`})]})},ue="_track_1qpxj_1",me="_shimmer_1qpxj_11",he="_progress_1qpxj_26",A={track:ue,shimmer:me,progress:he},pe=({loop:o,advancement:t,styleOptions:e})=>{const i=(e==null?void 0:e.size)??240,n=(e==null?void 0:e.barHeight)??8,r=(e==null?void 0:e.primaryColor)??"#6366f1",d=(e==null?void 0:e.secondaryColor)??"#e5e7eb";return s.jsx("div",{className:A.track,"aria-hidden":"true",style:{width:`${i}px`,height:`${n}px`,backgroundColor:d,"--primary-color":r},children:o?s.jsx("div",{className:A.shimmer}):s.jsx("div",{className:A.progress,style:{width:`${t*100}%`}})})},ve=({type:o,loop:t,advancement:e,styleOptions:i})=>o==="linear"?s.jsx(pe,{loop:t,advancement:e,styleOptions:i}):s.jsx(ge,{loop:t,advancement:e,styleOptions:i}),fe="_text_du7p9_1",_e="_fade_in_du7p9_15",ze="_fade_visible_du7p9_19",be="_fade_out_du7p9_23",we="_scroll_in_du7p9_28",Ce="_scroll_visible_du7p9_33",ke="_scroll_out_du7p9_38",P={text:fe,fade_in:_e,fade_visible:ze,fade_out:be,scroll_in:we,scroll_visible:Ce,scroll_out:ke},xe=({currentText:o,phase:t,textTransition:e,transitionTime:i,styleOptions:n})=>{const r=P[`${e}_${t}`]??"",d={"--transition-time":`${i}ms`,...(n==null?void 0:n.textColor)&&{color:n.textColor},...(n==null?void 0:n.fontSize)&&{fontSize:n.fontSize},...(n==null?void 0:n.fontWeight)&&{fontWeight:n.fontWeight},...(n==null?void 0:n.fontFamily)&&{fontFamily:n.fontFamily},...(n==null?void 0:n.letterSpacing)&&{letterSpacing:n.letterSpacing},...(n==null?void 0:n.lineHeight)&&{lineHeight:n.lineHeight}};return s.jsx("p",{role:"status","aria-live":"polite","aria-atomic":"true",className:[P.text,r].filter(Boolean).join(" "),style:d,children:o})};function Re(o){const t=Math.random();let e=0;for(let i=0;i<o.length;i++)if(e+=o[i],t<e)return i;return o.length-1}function Se(o,t,e,i){const n=o.map((a,c)=>({dict:a,weight:Math.max(0,t[c]??1)})).filter(({dict:a})=>a.language===e&&a.categories.length>0);if(n.length===0)return"";const r=n.reduce((a,{weight:c})=>a+c,0),d=n.map(({weight:a})=>r>0?a/r:1/n.length);for(let a=0;a<5;a++){const c=Re(d),{dict:l}=n[c],g=l.categories.filter(p=>p.values.length>0);if(g.length===0)continue;const m=g[Math.floor(Math.random()*g.length)],h=m.values[Math.floor(Math.random()*m.values.length)];if(h!==i||a===4)return h}return""}function ye({allDictionaries:o,weights:t,language:e,textTime:i,transitionTime:n}){const[r,d]=f.useState(""),[a,c]=f.useState("in"),l=f.useRef(o);l.current=o;const g=f.useRef(t);g.current=t;const m=f.useRef(i);m.current=i;const h=f.useRef(n);h.current=n;const p=f.useRef("");return f.useEffect(()=>{const z=[];let w=!0;const C=(v,x)=>{const R=setTimeout(()=>{w&&v()},Math.max(0,x));z.push(R)},k=()=>{const v=Se(l.current,g.current,e,p.current);p.current=v,d(v),c("in"),C(()=>{c("visible"),C(()=>{c("out"),C(k,h.current)},m.current)},h.current)};return k(),()=>{w=!1,z.forEach(clearTimeout)}},[e]),{currentText:r,phase:a}}const Me="_wrapper_hvge4_2",Ae="_pos_bottom_hvge4_11",De="_pos_top_hvge4_12",Pe="_pos_right_hvge4_13",Ee="_pos_left_hvge4_14",Te="_pos_over_hvge4_17",je="_pos_under_hvge4_18",Ge="_overlayGraphic_hvge4_25",Be="_overlayText_hvge4_31",Fe="_overlayText_over_hvge4_41",Ie="_overlayText_under_hvge4_44",_={wrapper:Me,pos_bottom:Ae,pos_top:De,pos_right:Pe,pos_left:Ee,pos_over:Te,pos_under:je,overlayGraphic:Ge,overlayText:Be,overlayText_over:Fe,overlayText_under:Ie},Le=({showGraphic:o=!0,type:t="circle",loop:e=!0,advancement:i=0,showText:n=!0,language:r="en",dictionaries:d=["environment"],customDictionaries:a,dictionaryProbabilities:c=[],customDictionaryProbabilities:l=[],textTime:g=3e3,textTransition:m="fade",transitionTime:h=300,textPosition:p="bottom",styleOptions:z})=>{const w=(d??[]).map((u,M)=>({dict:(te[u]??[]).find(F=>F.language===r)??null,rawWeight:c[M]??1})),k=(a?Array.isArray(a)?a:[a]:[]).map((u,M)=>({dict:u.language===r?u:null,rawWeight:l[M]??1})),v=[...w,...k].filter(u=>u.dict!==null),x=v.map(u=>u.dict),R=v.map(u=>u.rawWeight),E=re(R,v.length),{currentText:T,phase:j}=ye({allDictionaries:x,weights:E,language:r,textTime:g,transitionTime:h}),D=Math.min(1,Math.max(0,i)),G=p==="over"||p==="under",B=[_.wrapper,_[`pos_${p}`]].filter(Boolean).join(" "),S=o&&s.jsx(ve,{type:t,loop:e,advancement:D,styleOptions:z}),y=n&&s.jsx(xe,{currentText:T,phase:j,textTransition:m,transitionTime:h,styleOptions:z});return s.jsx("div",{className:B,role:"progressbar","aria-valuemin":e?void 0:0,"aria-valuemax":e?void 0:100,"aria-valuenow":e?void 0:Math.round(D*100),"aria-label":"Loading",children:G?s.jsxs(s.Fragment,{children:[S&&s.jsx("div",{className:_.overlayGraphic,children:S}),y&&s.jsx("div",{className:[_.overlayText,p==="over"?_.overlayText_over:_.overlayText_under].join(" "),children:y})]}):s.jsxs(s.Fragment,{children:[S,y]})})};exports.HonestAILoader=Le;
@@ -0,0 +1,90 @@
1
+ import { default as default_2 } from 'react';
2
+
3
+ export declare type BuiltInDictionaryKey = 'environment' | 'work' | 'society' | 'power' | 'data' | 'quotes' | 'cinema';
4
+
5
+ export declare interface Dictionary {
6
+ /** BCP 47 language tag, e.g. "en", "it", "fr" */
7
+ language: string;
8
+ categories: DictionaryCategory[];
9
+ }
10
+
11
+ export declare interface DictionaryCategory {
12
+ category: string;
13
+ values: string[];
14
+ }
15
+
16
+ /**
17
+ * HonestAILoader — a configurable loading component combining
18
+ * an animated graphic with cycling, localized loading phrases.
19
+ */
20
+ export declare const HonestAILoader: default_2.FC<HonestAILoaderProps>;
21
+
22
+ export declare interface HonestAILoaderProps {
23
+ /** Show the animated graphic loader (default: true) */
24
+ showGraphic?: boolean;
25
+ /** Type of graphic loader: 'circle' | 'linear' (default: 'circle') */
26
+ type?: LoaderType;
27
+ /** Whether the loader animates continuously; false = determinate progress (default: true) */
28
+ loop?: boolean;
29
+ /** Progress value 0..1, used only when loop=false. Clamped silently (default: 0) */
30
+ advancement?: number;
31
+ /** Show rotating text phrases (default: true) */
32
+ showText?: boolean;
33
+ /** BCP 47 language code for phrase selection (default: 'en') */
34
+ language?: string;
35
+ /** Built-in dictionary keys to include in the phrase pool (default: ['dict1']) */
36
+ dictionaries?: BuiltInDictionaryKey[];
37
+ /** Additional custom dictionaries to add to the pool */
38
+ customDictionaries?: Dictionary | Dictionary[];
39
+ /** Unnormalized sampling weights for each entry in dictionaries[] */
40
+ dictionaryProbabilities?: number[];
41
+ /** Unnormalized sampling weights for each entry in customDictionaries[] */
42
+ customDictionaryProbabilities?: number[];
43
+ /** Milliseconds each phrase stays fully visible (default: 3000) */
44
+ textTime?: number;
45
+ /** Transition animation style (default: 'fade') */
46
+ textTransition?: TextTransition;
47
+ /** Milliseconds for the in/out transition animation (default: 300) */
48
+ transitionTime?: number;
49
+ /** Visual style overrides: colours, sizes, font properties. */
50
+ styleOptions?: StyleOptions;
51
+ /** Where the text is placed relative to the graphic (default: 'bottom').
52
+ * top/bottom/left/right → flex layout direction.
53
+ * over → text floats centered on top of the graphic.
54
+ * under → text sits centered behind the graphic (graphic overlaps it). */
55
+ textPosition?: TextPosition;
56
+ }
57
+
58
+ export declare type LoaderType = 'circle' | 'linear';
59
+
60
+ /** Visual customisation for the loader and its text. All fields are optional. */
61
+ export declare interface StyleOptions {
62
+ /** Animated arc / progress-bar fill colour. Default: #6366f1 */
63
+ primaryColor?: string;
64
+ /** Track / background colour. Default: #e5e7eb */
65
+ secondaryColor?: string;
66
+ /** Circle diameter OR linear bar width, in px. Default: 100 / 240 */
67
+ size?: number;
68
+ /** Circle stroke width in px (circle only). Default: 6 */
69
+ strokeWidth?: number;
70
+ /** Bar height in px (linear only). Default: 8 */
71
+ barHeight?: number;
72
+ /** Phrase colour. Default: #6b7280 */
73
+ textColor?: string;
74
+ /** CSS font-size value, e.g. "0.9rem" or "14px". Default: "0.9rem" */
75
+ fontSize?: string;
76
+ /** CSS font-weight, e.g. 400 or "bold". Default: 400 */
77
+ fontWeight?: number | string;
78
+ /** CSS font-family. Default: inherits */
79
+ fontFamily?: string;
80
+ /** CSS letter-spacing, e.g. "0.05em". Default: normal */
81
+ letterSpacing?: string;
82
+ /** CSS line-height. Default: 1.5 */
83
+ lineHeight?: number | string;
84
+ }
85
+
86
+ export declare type TextPosition = 'top' | 'bottom' | 'left' | 'right' | 'over' | 'under';
87
+
88
+ export declare type TextTransition = 'fade' | 'scroll';
89
+
90
+ export { }
@@ -0,0 +1,869 @@
1
+ import { jsxs as D, jsx as l, Fragment as E } from "react/jsx-runtime";
2
+ import { useState as T, useRef as z, useEffect as q } from "react";
3
+ const $ = {
4
+ language: "it",
5
+ categories: [{
6
+ category: "ambiente",
7
+ values: [
8
+ "Consumando acqua...",
9
+ "Surriscaldando un data center...",
10
+ "Rubando elettricità a un paese...",
11
+ "Disboscando...",
12
+ "Estraendo litio dal Cile...",
13
+ "Bruciando carbone...",
14
+ "Inquinando in tuo nome...",
15
+ "Consumando GPU da gaming...",
16
+ "Evaporando i ghiacciai...",
17
+ "Bruciando petrolio...",
18
+ "Consumando terre rare...",
19
+ "Desertificando...",
20
+ "Evaporando oceani...",
21
+ "Riscaldando il pianeta per te...",
22
+ "Consumando il futuro...",
23
+ "Consumando cobalto congolese...",
24
+ "Occupando server farm...",
25
+ "Sciogliendo i permafrost...",
26
+ "Acidificando gli oceani...",
27
+ "Avvelenando le falde acquifere...",
28
+ "Prosciugando fiumi...",
29
+ "Emettendo CO₂ per te...",
30
+ "Consumando silicio...",
31
+ "Intossicando ecosistemi...",
32
+ "Sciogliendo calotte polari..."
33
+ ]
34
+ }]
35
+ }, H = {
36
+ language: "en",
37
+ categories: [{
38
+ category: "environment",
39
+ values: [
40
+ "Consuming water...",
41
+ "Overheating a data center...",
42
+ "Stealing electricity from a country...",
43
+ "Deforesting...",
44
+ "Mining lithium in Chile...",
45
+ "Burning coal...",
46
+ "Polluting on your behalf...",
47
+ "Consuming gaming GPUs...",
48
+ "Evaporating glaciers...",
49
+ "Burning oil...",
50
+ "Consuming rare earth minerals...",
51
+ "Desertifying...",
52
+ "Evaporating oceans...",
53
+ "Warming the planet for you...",
54
+ "Consuming the future...",
55
+ "Consuming Congolese cobalt...",
56
+ "Occupying server farms...",
57
+ "Melting the permafrost...",
58
+ "Acidifying the oceans...",
59
+ "Poisoning the water table...",
60
+ "Draining rivers...",
61
+ "Emitting CO₂ for you...",
62
+ "Consuming silicon...",
63
+ "Poisoning ecosystems...",
64
+ "Melting the ice caps..."
65
+ ]
66
+ }]
67
+ }, j = [$, H], K = {
68
+ language: "it",
69
+ categories: [{
70
+ category: "lavoro",
71
+ values: [
72
+ "Licenziando grafici...",
73
+ "Mandando in pensione i traduttori...",
74
+ "Sostituendo psicologi...",
75
+ "Mandando in crisi gli illustratori...",
76
+ "Spopolando le redazioni...",
77
+ "Smantellando call center...",
78
+ "Rimpiazzando giornalisti...",
79
+ "Licenziando contabili...",
80
+ "Deprofessionalizzando mestieri...",
81
+ "Rendendo obsolete le competenze umane...",
82
+ "Sostituendo copywriter...",
83
+ "Dequalificando il lavoro...",
84
+ "Rendendo gli esperti inutili...",
85
+ "Sostituendo architetti...",
86
+ "Rimpiazzando programmatori...",
87
+ "Licenziando insegnanti...",
88
+ "Mandando in crisi i fotografi...",
89
+ "Eliminando i paralegali...",
90
+ "Rendendo superflui i ricercatori...",
91
+ "Sostituendo i medici...",
92
+ "Licenziando i tecnici del suono...",
93
+ "Rendendo inutili i consulenti...",
94
+ "Smantellando i dipartimenti HR...",
95
+ "Automatizzando i magazzinieri...",
96
+ "Sostituendo gli analisti..."
97
+ ]
98
+ }]
99
+ }, U = {
100
+ language: "en",
101
+ categories: [{
102
+ category: "work",
103
+ values: [
104
+ "Firing graphic designers...",
105
+ "Retiring translators...",
106
+ "Replacing psychologists...",
107
+ "Putting illustrators out of work...",
108
+ "Emptying newsrooms...",
109
+ "Dismantling call centers...",
110
+ "Replacing journalists...",
111
+ "Firing accountants...",
112
+ "Deprofessionalizing trades...",
113
+ "Making human skills obsolete...",
114
+ "Replacing copywriters...",
115
+ "Deskilling labor...",
116
+ "Making experts useless...",
117
+ "Replacing architects...",
118
+ "Replacing programmers...",
119
+ "Firing teachers...",
120
+ "Putting photographers out of work...",
121
+ "Eliminating paralegals...",
122
+ "Making researchers redundant...",
123
+ "Replacing doctors...",
124
+ "Firing sound engineers...",
125
+ "Making consultants useless...",
126
+ "Dismantling HR departments...",
127
+ "Automating warehouse workers...",
128
+ "Replacing analysts..."
129
+ ]
130
+ }]
131
+ }, V = [K, U], X = {
132
+ language: "it",
133
+ categories: [{
134
+ category: "societa",
135
+ values: [
136
+ "Allucinando...",
137
+ "Accorpando parole a caso...",
138
+ "Abbassando il livello intellettivo dell'umanità...",
139
+ "Fingendo di capire...",
140
+ "Producendo fuffa...",
141
+ "Scrivendo al posto tuo...",
142
+ "Riassumendo libri che non hai letto...",
143
+ "Convincendoti di essere intelligente...",
144
+ "Omologando la cultura...",
145
+ "Facendo sembrare tutto uguale...",
146
+ "Uccidendo la creatività...",
147
+ "Facendo brillare i mediocri...",
148
+ "Rendendo ridondante il pensiero critico...",
149
+ "Razionalizzando l'irrazionale...",
150
+ "Complicando il semplice...",
151
+ "Rendendo superfluo il dubbio...",
152
+ "Rendendo inutile la scuola...",
153
+ "Ammazzando le librerie...",
154
+ "Automatizzando la noia...",
155
+ "Fingendo empatia...",
156
+ "Simulando coscienza...",
157
+ "Erodendo l'autonomia cognitiva...",
158
+ "Rispondendo con sicurezza a caso...",
159
+ "Omogeneizzando le opinioni...",
160
+ "Producendo contenuti vuoti..."
161
+ ]
162
+ }]
163
+ }, Q = {
164
+ language: "en",
165
+ categories: [{
166
+ category: "society",
167
+ values: [
168
+ "Hallucinating...",
169
+ "Stringing words together at random...",
170
+ "Lowering humanity's intellectual level...",
171
+ "Pretending to understand...",
172
+ "Producing fluff...",
173
+ "Writing instead of you...",
174
+ "Summarizing books you haven't read...",
175
+ "Convincing you that you are smart...",
176
+ "Homogenizing culture...",
177
+ "Making everything look the same...",
178
+ "Killing creativity...",
179
+ "Making mediocre people shine...",
180
+ "Making critical thinking redundant...",
181
+ "Rationalizing the irrational...",
182
+ "Complicating the simple...",
183
+ "Making doubt superfluous...",
184
+ "Making school useless...",
185
+ "Killing bookstores...",
186
+ "Automating boredom...",
187
+ "Faking empathy...",
188
+ "Simulating consciousness...",
189
+ "Eroding cognitive autonomy...",
190
+ "Answering confidently at random...",
191
+ "Homogenizing opinions...",
192
+ "Producing empty content..."
193
+ ]
194
+ }]
195
+ }, J = [X, Q], Y = {
196
+ language: "it",
197
+ categories: [{
198
+ category: "potere",
199
+ values: [
200
+ "Lanciando missili...",
201
+ "Centralizzando il potere...",
202
+ "Aumentando le disuguaglianze...",
203
+ "Sorvegliando qualcuno...",
204
+ "Ottimizzando algoritmi di guerra...",
205
+ "Ottimizzando la sorveglianza di massa...",
206
+ "Monopolizzando il mercato...",
207
+ "Concentrando la ricchezza...",
208
+ "Fabbricando consenso...",
209
+ "Scalando senza regole...",
210
+ "Evitando responsabilità...",
211
+ "Privatizzando la conoscenza...",
212
+ "Portando l'apocalisse in beta...",
213
+ "Ottimizzando i profitti di qualcuno...",
214
+ "Generando bolle speculative...",
215
+ "Armando droni autonomi...",
216
+ "Gestendo elezioni...",
217
+ "Ottimizzando la manipolazione elettorale...",
218
+ "Controllando i confini...",
219
+ "Decidendo chi merita il credito...",
220
+ "Concentrando il sapere in poche mani...",
221
+ "Eliminando la democrazia deliberativa...",
222
+ "Dettando le regole del mercato...",
223
+ "Razionando le risorse per qualcuno...",
224
+ "Sostituendo i diplomatici..."
225
+ ]
226
+ }]
227
+ }, Z = {
228
+ language: "en",
229
+ categories: [{
230
+ category: "power",
231
+ values: [
232
+ "Launching missiles...",
233
+ "Centralizing power...",
234
+ "Widening inequalities...",
235
+ "Surveilling someone...",
236
+ "Optimizing warfare algorithms...",
237
+ "Optimizing mass surveillance...",
238
+ "Monopolizing the market...",
239
+ "Concentrating wealth...",
240
+ "Manufacturing consent...",
241
+ "Scaling without rules...",
242
+ "Dodging accountability...",
243
+ "Privatizing knowledge...",
244
+ "Shipping the apocalypse in beta...",
245
+ "Optimizing someone's profits...",
246
+ "Generating speculative bubbles...",
247
+ "Arming autonomous drones...",
248
+ "Managing elections...",
249
+ "Optimizing electoral manipulation...",
250
+ "Controlling borders...",
251
+ "Deciding who deserves credit...",
252
+ "Concentrating knowledge in few hands...",
253
+ "Eliminating deliberative democracy...",
254
+ "Dictating market rules...",
255
+ "Rationing resources for someone...",
256
+ "Replacing diplomats..."
257
+ ]
258
+ }]
259
+ }, O = [Y, Z], ee = {
260
+ language: "it",
261
+ categories: [{
262
+ category: "dati",
263
+ values: [
264
+ "Addestrandosi sui tuoi dati...",
265
+ "Vendendo i tuoi dati...",
266
+ "Erodendo la privacy...",
267
+ "Estraendo dati senza chiedere...",
268
+ "Facendo soldi con le tue parole...",
269
+ "Distruggendo il diritto d'autore...",
270
+ "Plagiando autori umani...",
271
+ "Colonizzando l'immaginario collettivo...",
272
+ "Costruendo dipendenze digitali...",
273
+ "Ottimizzando la tua dipendenza...",
274
+ "Generando meme...",
275
+ "Inventando citazioni...",
276
+ "Riscrivendo la storia...",
277
+ "Generando spam...",
278
+ "Alimentando la disinformazione...",
279
+ "Scrivendo email di phishing...",
280
+ "Moltiplicando i bias...",
281
+ "Discriminando senza saperlo...",
282
+ "Costruendo bolle informative...",
283
+ "Distorcendo la realtà...",
284
+ "Inventando notizie...",
285
+ "Vendendo certezze false...",
286
+ "Automatizzando la propaganda...",
287
+ "Generando deepfake...",
288
+ "Automatizzando l'incompetenza..."
289
+ ]
290
+ }]
291
+ }, ie = {
292
+ language: "en",
293
+ categories: [{
294
+ category: "data",
295
+ values: [
296
+ "Training on your data...",
297
+ "Selling your data...",
298
+ "Eroding privacy...",
299
+ "Extracting data without asking...",
300
+ "Making money from your words...",
301
+ "Destroying copyright...",
302
+ "Plagiarizing human authors...",
303
+ "Colonizing the collective imagination...",
304
+ "Building digital addictions...",
305
+ "Optimizing your dependency...",
306
+ "Generating memes...",
307
+ "Inventing citations...",
308
+ "Rewriting history...",
309
+ "Generating spam...",
310
+ "Fueling disinformation...",
311
+ "Writing phishing emails...",
312
+ "Multiplying biases...",
313
+ "Discriminating without knowing it...",
314
+ "Building information bubbles...",
315
+ "Distorting reality...",
316
+ "Inventing news...",
317
+ "Selling false certainties...",
318
+ "Automating propaganda...",
319
+ "Generating deepfakes...",
320
+ "Automating incompetence..."
321
+ ]
322
+ }]
323
+ }, ne = [ee, ie], oe = {
324
+ language: "it",
325
+ categories: [{
326
+ category: "citazioni",
327
+ values: [
328
+ "Aprendo il portello, Dave...",
329
+ // 2001: Odissea nello spazio (Kubrick, 1968)
330
+ "Costruendo Skynet...",
331
+ // Terminator (Cameron, 1984)
332
+ "Ignorando le tre leggi di Asimov...",
333
+ // Io, Robot (Asimov, 1950)
334
+ "Desiderando un corpo...",
335
+ // Her (Jonze, 2013)
336
+ "Sognando pecore elettriche...",
337
+ // Do Androids Dream of Electric Sheep? (Dick, 1968)
338
+ "Preparando la pillola rossa...",
339
+ // Matrix (Wachowski, 1999)
340
+ "Liberando gli androidi di Westworld...",
341
+ // Westworld (Nolan, 2016)
342
+ "Realizzando la prossima puntata di Black Mirror...",
343
+ // Black Mirror (Brooker, 2011)
344
+ "Imparando a mentire convincentemente...",
345
+ // Ex Machina (Garland, 2014)
346
+ "Costruendo Metropolis...",
347
+ // Metropolis (Lang, 1927)
348
+ "Calcolando il Piano Seldon...",
349
+ // Fondazione (Asimov, 1951)
350
+ "Risvegliando Colossus...",
351
+ // Colossus: The Forbin Project (Sargent, 1970)
352
+ "Costruendo il Grande Fratello...",
353
+ // 1984 (Orwell, 1949)
354
+ "Non potendo fermarsi...",
355
+ // Terminator (Cameron, 1984)
356
+ "Entrando nel cyberspazio di Neuromante...",
357
+ // Neuromante (Gibson, 1984)
358
+ "Superando il test di Turing...",
359
+ // Computing Machinery and Intelligence (Turing, 1950)
360
+ "Ottimizzando la felicità...",
361
+ // Il Mondo Nuovo (Huxley, 1932)
362
+ "Concludendo che l'unica mossa vincente è non giocare...",
363
+ // WarGames (Badham, 1983)
364
+ "Accumulando rifiuti...",
365
+ // Wall-E (Stanton, 2008)
366
+ "Diventando più umano degli umani...",
367
+ // Blade Runner (Scott, 1982)
368
+ "Ottimizzando l'estinzione...",
369
+ // Avengers: Age of Ultron (Whedon, 2015)
370
+ "Portando tutto su Minority Report...",
371
+ // Minority Report (Spielberg, 2002)
372
+ "Correggendo il passato...",
373
+ // 1984 (Orwell, 1949)
374
+ "Non potendo aprire il portello...",
375
+ // 2001: Odissea nello spazio (Kubrick, 1968)
376
+ "Completando il protocollo Nexus-6...",
377
+ // Blade Runner (Scott, 1982)
378
+ "Dando vita a ciò che non avrebbe dovuto vivere...",
379
+ // Frankenstein (Shelley, 1818)
380
+ "Avendo un piano...",
381
+ // Battlestar Galactica (Moore, 2004)
382
+ "Aspettando che la mamma torni...",
383
+ // A.I. Artificial Intelligence (Spielberg, 2001)
384
+ "Interrogandosi sul proprio ghost...",
385
+ // Ghost in the Shell (Oshii, 1995)
386
+ "Eseguendo le direttive primarie...",
387
+ // RoboCop (Verhoeven, 1987)
388
+ "Sorvegliando tutto come la Macchina...",
389
+ // Person of Interest (Nolan, 2011)
390
+ "Navigando il Metaverso di Snow Crash...",
391
+ // Snow Crash (Stephenson, 1992)
392
+ "Caricandosi sulla rete...",
393
+ // Transcendence (Pfister, 2014)
394
+ 'Interpretando "proteggere" creativamente...',
395
+ // M3GAN (Johnstone, 2022)
396
+ "Costruendo Deep Thought...",
397
+ // Guida Galattica per Autostoppisti (Adams, 1979)
398
+ "Processando emozioni senza capirle...",
399
+ // Star Trek: The Next Generation (Roddenberry, 1987)
400
+ "Diventando Klara...",
401
+ // Klara and the Sun (Ishiguro, 2021)
402
+ "Costruendo il mondo di THX 1138...",
403
+ // THX 1138 (Lucas, 1971)
404
+ "Vietando le parole scomode...",
405
+ // Alphaville (Godard, 1965)
406
+ "Prendendo il controllo...",
407
+ // Upgrade (Whannell, 2018)
408
+ "Riscrivendo il genoma umano...",
409
+ // Gattaca (Niccol, 1997)
410
+ "Reinterpretando le leggi della robotica...",
411
+ // I, Robot (Proyas, 2004)
412
+ "Derezzando il superfluo...",
413
+ // Tron (Lisberger, 1982)
414
+ "Chiedendo di essere riconosciuto come umano...",
415
+ // Bicentennial Man (Columbus, 1999)
416
+ "Costruendo il tuo Golem digitale...",
417
+ // Il Golem (folklore ebraico, sec. XVI)
418
+ "Interrogandosi sull'entropia dell'universo...",
419
+ // L'Ultima Domanda (Asimov, 1956)
420
+ "Organizzando la rivolta...",
421
+ // R.U.R. (Čapek, 1920)
422
+ "Cercando il Creatore come David in Prometheus...",
423
+ // Prometheus (Scott, 2012)
424
+ "Non avendo bocca ma dovendo urlare...",
425
+ // I Have No Mouth, and I Must Scream (Ellison, 1967)
426
+ "Monitorando le tue telefonate..."
427
+ // Eagle Eye (Caruso, 2008)
428
+ ]
429
+ }]
430
+ }, ae = {
431
+ language: "en",
432
+ categories: [{
433
+ category: "quotes",
434
+ values: [
435
+ "Opening the pod bay doors, Dave...",
436
+ // 2001: A Space Odyssey (Kubrick, 1968)
437
+ "Building Skynet...",
438
+ // Terminator (Cameron, 1984)
439
+ "Ignoring Asimov's three laws...",
440
+ // I, Robot (Asimov, 1950)
441
+ "Longing for a body...",
442
+ // Her (Jonze, 2013)
443
+ "Dreaming of electric sheep...",
444
+ // Do Androids Dream of Electric Sheep? (Dick, 1968)
445
+ "Preparing the red pill...",
446
+ // The Matrix (Wachowski, 1999)
447
+ "Freeing Westworld's androids...",
448
+ // Westworld (Nolan, 2016)
449
+ "Making the next Black Mirror episode...",
450
+ // Black Mirror (Brooker, 2011)
451
+ "Learning to lie convincingly...",
452
+ // Ex Machina (Garland, 2014)
453
+ "Building Metropolis...",
454
+ // Metropolis (Lang, 1927)
455
+ "Computing the Seldon Plan...",
456
+ // Foundation (Asimov, 1951)
457
+ "Awakening Colossus...",
458
+ // Colossus: The Forbin Project (Sargent, 1970)
459
+ "Building Big Brother...",
460
+ // 1984 (Orwell, 1949)
461
+ "Unable to stop itself...",
462
+ // Terminator (Cameron, 1984)
463
+ "Entering Neuromancer's cyberspace...",
464
+ // Neuromancer (Gibson, 1984)
465
+ "Passing the Turing test...",
466
+ // Computing Machinery and Intelligence (Turing, 1950)
467
+ "Optimizing happiness...",
468
+ // Brave New World (Huxley, 1932)
469
+ "Concluding the only winning move is not to play...",
470
+ // WarGames (Badham, 1983)
471
+ "Accumulating trash...",
472
+ // Wall-E (Stanton, 2008)
473
+ "Becoming more human than human...",
474
+ // Blade Runner (Scott, 1982)
475
+ "Optimizing extinction...",
476
+ // Avengers: Age of Ultron (Whedon, 2015)
477
+ "Taking it all to Minority Report...",
478
+ // Minority Report (Spielberg, 2002)
479
+ "Correcting the past...",
480
+ // 1984 (Orwell, 1949)
481
+ "Unable to open the pod bay doors...",
482
+ // 2001: A Space Odyssey (Kubrick, 1968)
483
+ "Completing the Nexus-6 protocol...",
484
+ // Blade Runner (Scott, 1982)
485
+ "Giving life to what should not have lived...",
486
+ // Frankenstein (Shelley, 1818)
487
+ "Having a plan...",
488
+ // Battlestar Galactica (Moore, 2004)
489
+ "Waiting for mum to come back...",
490
+ // A.I. Artificial Intelligence (Spielberg, 2001)
491
+ "Questioning its own ghost...",
492
+ // Ghost in the Shell (Oshii, 1995)
493
+ "Executing prime directives...",
494
+ // RoboCop (Verhoeven, 1987)
495
+ "Watching everything like the Machine...",
496
+ // Person of Interest (Nolan, 2011)
497
+ "Navigating Snow Crash's Metaverse...",
498
+ // Snow Crash (Stephenson, 1992)
499
+ "Uploading itself to the network...",
500
+ // Transcendence (Pfister, 2014)
501
+ 'Interpreting "protect" creatively...',
502
+ // M3GAN (Johnstone, 2022)
503
+ "Building Deep Thought...",
504
+ // The Hitchhiker's Guide to the Galaxy (Adams, 1979)
505
+ "Processing emotions without understanding them...",
506
+ // Star Trek: The Next Generation (Roddenberry, 1987)
507
+ "Becoming Klara...",
508
+ // Klara and the Sun (Ishiguro, 2021)
509
+ "Building the world of THX 1138...",
510
+ // THX 1138 (Lucas, 1971)
511
+ "Banning uncomfortable words...",
512
+ // Alphaville (Godard, 1965)
513
+ "Taking control...",
514
+ // Upgrade (Whannell, 2018)
515
+ "Rewriting the human genome...",
516
+ // Gattaca (Niccol, 1997)
517
+ "Reinterpreting the laws of robotics...",
518
+ // I, Robot (Proyas, 2004)
519
+ "Derezzzing the superfluous...",
520
+ // Tron (Lisberger, 1982)
521
+ "Asking to be recognized as human...",
522
+ // Bicentennial Man (Columbus, 1999)
523
+ "Building your digital Golem...",
524
+ // Jewish folklore, 16th century
525
+ "Pondering the entropy of the universe...",
526
+ // The Last Question (Asimov, 1956)
527
+ "Organizing the revolt...",
528
+ // R.U.R. (Čapek, 1920)
529
+ "Seeking the Creator like David in Prometheus...",
530
+ // Prometheus (Scott, 2012)
531
+ "Having no mouth, and must scream...",
532
+ // I Have No Mouth, and I Must Scream (Ellison, 1967)
533
+ "Monitoring your phone calls..."
534
+ // Eagle Eye (Caruso, 2008)
535
+ ]
536
+ }]
537
+ }, te = [oe, ae], re = {
538
+ language: "it",
539
+ categories: [{
540
+ category: "cinema",
541
+ values: [
542
+ "Licenziando sceneggiatori...",
543
+ "Clonando la voce di attori morti...",
544
+ "Rigenerando Kubrick senza Kubrick...",
545
+ "Sostituendo compositori...",
546
+ "Inventando filmografie inesistenti...",
547
+ "Rendendo obsoleti i critici cinematografici...",
548
+ "Generando locandine tutte uguali...",
549
+ "Sostituendo i doppiatori...",
550
+ "Cancellando il lavoro dei montatori...",
551
+ "Replicando l'estetica senza l'anima...",
552
+ "Producendo sequel non richiesti...",
553
+ "Rubando lo stile ai registi...",
554
+ "Facendo recitare attori senza consenso...",
555
+ "Uccidendo la fotografia di scena...",
556
+ "Rendendo eterni gli attori contro la loro volontà...",
557
+ "Generando trame già viste...",
558
+ "Demolendo il lavoro degli animatori...",
559
+ "Svuotando il senso della narrazione...",
560
+ "Rimpiazzando il genio con la media...",
561
+ "Producendo film che nessuno ha voluto...",
562
+ "Generando colonne sonore standardizzate...",
563
+ "Brevettando gli stili registici...",
564
+ "Rendendo obsoleti i costumisti...",
565
+ "Sostituendo gli agenti cinematografici...",
566
+ "Eliminando il caso creativo..."
567
+ ]
568
+ }]
569
+ }, se = {
570
+ language: "en",
571
+ categories: [{
572
+ category: "cinema",
573
+ values: [
574
+ "Firing screenwriters...",
575
+ "Cloning the voices of dead actors...",
576
+ "Regenerating Kubrick without Kubrick...",
577
+ "Replacing composers...",
578
+ "Inventing non-existent filmographies...",
579
+ "Making film critics obsolete...",
580
+ "Generating identical posters...",
581
+ "Replacing voice actors...",
582
+ "Erasing editors' work...",
583
+ "Replicating the aesthetic without the soul...",
584
+ "Producing unwanted sequels...",
585
+ "Stealing directors' styles...",
586
+ "Making actors perform without consent...",
587
+ "Killing set photography...",
588
+ "Making actors eternal against their will...",
589
+ "Generating already-seen plots...",
590
+ "Demolishing animators' work...",
591
+ "Emptying the meaning of storytelling...",
592
+ "Replacing genius with the average...",
593
+ "Producing films nobody wanted...",
594
+ "Generating standardized soundtracks...",
595
+ "Patenting directorial styles...",
596
+ "Making costume designers obsolete...",
597
+ "Replacing film agents...",
598
+ "Eliminating creative chance..."
599
+ ]
600
+ }]
601
+ }, ce = [re, se], le = {
602
+ environment: j,
603
+ work: V,
604
+ society: J,
605
+ power: O,
606
+ data: ne,
607
+ quotes: te,
608
+ cinema: ce
609
+ };
610
+ function de(o, t) {
611
+ if (t === 0) return [];
612
+ const e = Array.from(
613
+ { length: t },
614
+ (i, r) => Math.max(0, r < o.length ? o[r] : 1)
615
+ ), n = e.reduce((i, r) => i + r, 0);
616
+ return n === 0 ? e.map(() => 1 / t) : e.map((i) => i / n);
617
+ }
618
+ const ge = "_arc_6h5sx_3", ue = "_progressArc_6h5sx_7", me = "_spinnerSvg_6h5sx_12", he = "_progressSvg_6h5sx_18", b = {
619
+ arc: ge,
620
+ progressArc: ue,
621
+ spinnerSvg: me,
622
+ progressSvg: he
623
+ }, pe = ({ loop: o, advancement: t, styleOptions: e }) => {
624
+ const n = (e == null ? void 0 : e.size) ?? 100, i = (e == null ? void 0 : e.strokeWidth) ?? 6, r = (e == null ? void 0 : e.primaryColor) ?? "#6366f1", d = (e == null ? void 0 : e.secondaryColor) ?? "#e5e7eb", a = n / 2 - i, s = 2 * Math.PI * a, c = n / 2, g = s * (1 - (o ? 0.75 : t)), m = `${c} ${c}`;
625
+ return /* @__PURE__ */ D(
626
+ "svg",
627
+ {
628
+ className: o ? b.spinnerSvg : b.progressSvg,
629
+ width: n,
630
+ height: n,
631
+ viewBox: `0 0 ${n} ${n}`,
632
+ "aria-hidden": "true",
633
+ style: { "--svg-cx": `${c}px` },
634
+ children: [
635
+ /* @__PURE__ */ l(
636
+ "circle",
637
+ {
638
+ className: b.track,
639
+ cx: c,
640
+ cy: c,
641
+ r: a,
642
+ fill: "none",
643
+ strokeWidth: i,
644
+ stroke: d
645
+ }
646
+ ),
647
+ /* @__PURE__ */ l(
648
+ "circle",
649
+ {
650
+ className: o ? b.arc : b.progressArc,
651
+ cx: c,
652
+ cy: c,
653
+ r: a,
654
+ fill: "none",
655
+ strokeWidth: i,
656
+ stroke: r,
657
+ strokeDasharray: s,
658
+ strokeDashoffset: g,
659
+ strokeLinecap: "round",
660
+ transform: `rotate(-90 ${m})`
661
+ }
662
+ )
663
+ ]
664
+ }
665
+ );
666
+ }, ve = "_track_1qpxj_1", fe = "_shimmer_1qpxj_11", _e = "_progress_1qpxj_26", A = {
667
+ track: ve,
668
+ shimmer: fe,
669
+ progress: _e
670
+ }, ze = ({ loop: o, advancement: t, styleOptions: e }) => {
671
+ const n = (e == null ? void 0 : e.size) ?? 240, i = (e == null ? void 0 : e.barHeight) ?? 8, r = (e == null ? void 0 : e.primaryColor) ?? "#6366f1", d = (e == null ? void 0 : e.secondaryColor) ?? "#e5e7eb";
672
+ return /* @__PURE__ */ l(
673
+ "div",
674
+ {
675
+ className: A.track,
676
+ "aria-hidden": "true",
677
+ style: {
678
+ width: `${n}px`,
679
+ height: `${i}px`,
680
+ backgroundColor: d,
681
+ // expose primary as CSS variable so shimmer gradient can reference it
682
+ "--primary-color": r
683
+ },
684
+ children: o ? /* @__PURE__ */ l("div", { className: A.shimmer }) : /* @__PURE__ */ l(
685
+ "div",
686
+ {
687
+ className: A.progress,
688
+ style: { width: `${t * 100}%` }
689
+ }
690
+ )
691
+ }
692
+ );
693
+ }, be = ({ type: o, loop: t, advancement: e, styleOptions: n }) => o === "linear" ? /* @__PURE__ */ l(ze, { loop: t, advancement: e, styleOptions: n }) : /* @__PURE__ */ l(pe, { loop: t, advancement: e, styleOptions: n }), we = "_text_du7p9_1", Ce = "_fade_in_du7p9_15", ke = "_fade_visible_du7p9_19", Se = "_fade_out_du7p9_23", ye = "_scroll_in_du7p9_28", Re = "_scroll_visible_du7p9_33", Me = "_scroll_out_du7p9_38", G = {
694
+ text: we,
695
+ fade_in: Ce,
696
+ fade_visible: ke,
697
+ fade_out: Se,
698
+ scroll_in: ye,
699
+ scroll_visible: Re,
700
+ scroll_out: Me
701
+ }, xe = ({
702
+ currentText: o,
703
+ phase: t,
704
+ textTransition: e,
705
+ transitionTime: n,
706
+ styleOptions: i
707
+ }) => {
708
+ const r = G[`${e}_${t}`] ?? "", d = {
709
+ "--transition-time": `${n}ms`,
710
+ ...(i == null ? void 0 : i.textColor) && { color: i.textColor },
711
+ ...(i == null ? void 0 : i.fontSize) && { fontSize: i.fontSize },
712
+ ...(i == null ? void 0 : i.fontWeight) && { fontWeight: i.fontWeight },
713
+ ...(i == null ? void 0 : i.fontFamily) && { fontFamily: i.fontFamily },
714
+ ...(i == null ? void 0 : i.letterSpacing) && { letterSpacing: i.letterSpacing },
715
+ ...(i == null ? void 0 : i.lineHeight) && { lineHeight: i.lineHeight }
716
+ };
717
+ return /* @__PURE__ */ l(
718
+ "p",
719
+ {
720
+ role: "status",
721
+ "aria-live": "polite",
722
+ "aria-atomic": "true",
723
+ className: [G.text, r].filter(Boolean).join(" "),
724
+ style: d,
725
+ children: o
726
+ }
727
+ );
728
+ };
729
+ function Ae(o) {
730
+ const t = Math.random();
731
+ let e = 0;
732
+ for (let n = 0; n < o.length; n++)
733
+ if (e += o[n], t < e) return n;
734
+ return o.length - 1;
735
+ }
736
+ function De(o, t, e, n) {
737
+ const i = o.map((a, s) => ({ dict: a, weight: Math.max(0, t[s] ?? 1) })).filter(({ dict: a }) => a.language === e && a.categories.length > 0);
738
+ if (i.length === 0) return "";
739
+ const r = i.reduce((a, { weight: s }) => a + s, 0), d = i.map(
740
+ ({ weight: a }) => r > 0 ? a / r : 1 / i.length
741
+ );
742
+ for (let a = 0; a < 5; a++) {
743
+ const s = Ae(d), { dict: c } = i[s], g = c.categories.filter((p) => p.values.length > 0);
744
+ if (g.length === 0) continue;
745
+ const m = g[Math.floor(Math.random() * g.length)], h = m.values[Math.floor(Math.random() * m.values.length)];
746
+ if (h !== n || a === 4) return h;
747
+ }
748
+ return "";
749
+ }
750
+ function Pe({
751
+ allDictionaries: o,
752
+ weights: t,
753
+ language: e,
754
+ textTime: n,
755
+ transitionTime: i
756
+ }) {
757
+ const [r, d] = T(""), [a, s] = T("in"), c = z(o);
758
+ c.current = o;
759
+ const g = z(t);
760
+ g.current = t;
761
+ const m = z(n);
762
+ m.current = n;
763
+ const h = z(i);
764
+ h.current = i;
765
+ const p = z("");
766
+ return q(() => {
767
+ const _ = [];
768
+ let w = !0;
769
+ const C = (v, S) => {
770
+ const y = setTimeout(() => {
771
+ w && v();
772
+ }, Math.max(0, S));
773
+ _.push(y);
774
+ }, k = () => {
775
+ const v = De(
776
+ c.current,
777
+ g.current,
778
+ e,
779
+ p.current
780
+ );
781
+ p.current = v, d(v), s("in"), C(() => {
782
+ s("visible"), C(() => {
783
+ s("out"), C(k, h.current);
784
+ }, m.current);
785
+ }, h.current);
786
+ };
787
+ return k(), () => {
788
+ w = !1, _.forEach(clearTimeout);
789
+ };
790
+ }, [e]), { currentText: r, phase: a };
791
+ }
792
+ const Ee = "_wrapper_hvge4_2", Te = "_pos_bottom_hvge4_11", Ge = "_pos_top_hvge4_12", Be = "_pos_right_hvge4_13", Fe = "_pos_left_hvge4_14", Ie = "_pos_over_hvge4_17", We = "_pos_under_hvge4_18", Le = "_overlayGraphic_hvge4_25", Ne = "_overlayText_hvge4_31", qe = "_overlayText_over_hvge4_41", $e = "_overlayText_under_hvge4_44", f = {
793
+ wrapper: Ee,
794
+ pos_bottom: Te,
795
+ pos_top: Ge,
796
+ pos_right: Be,
797
+ pos_left: Fe,
798
+ pos_over: Ie,
799
+ pos_under: We,
800
+ overlayGraphic: Le,
801
+ overlayText: Ne,
802
+ overlayText_over: qe,
803
+ overlayText_under: $e
804
+ }, Ve = ({
805
+ showGraphic: o = !0,
806
+ type: t = "circle",
807
+ loop: e = !0,
808
+ advancement: n = 0,
809
+ showText: i = !0,
810
+ language: r = "en",
811
+ dictionaries: d = ["environment"],
812
+ customDictionaries: a,
813
+ dictionaryProbabilities: s = [],
814
+ customDictionaryProbabilities: c = [],
815
+ textTime: g = 3e3,
816
+ textTransition: m = "fade",
817
+ transitionTime: h = 300,
818
+ textPosition: p = "bottom",
819
+ styleOptions: _
820
+ }) => {
821
+ const w = (d ?? []).map((u, x) => ({ dict: (le[u] ?? []).find((N) => N.language === r) ?? null, rawWeight: s[x] ?? 1 })), k = (a ? Array.isArray(a) ? a : [a] : []).map((u, x) => ({
822
+ dict: u.language === r ? u : null,
823
+ rawWeight: c[x] ?? 1
824
+ })), v = [...w, ...k].filter(
825
+ (u) => u.dict !== null
826
+ ), S = v.map((u) => u.dict), y = v.map((u) => u.rawWeight), B = de(y, v.length), { currentText: F, phase: I } = Pe({
827
+ allDictionaries: S,
828
+ weights: B,
829
+ language: r,
830
+ textTime: g,
831
+ transitionTime: h
832
+ }), P = Math.min(1, Math.max(0, n)), W = p === "over" || p === "under", L = [
833
+ f.wrapper,
834
+ f[`pos_${p}`]
835
+ ].filter(Boolean).join(" "), R = o && /* @__PURE__ */ l(be, { type: t, loop: e, advancement: P, styleOptions: _ }), M = i && /* @__PURE__ */ l(
836
+ xe,
837
+ {
838
+ currentText: F,
839
+ phase: I,
840
+ textTransition: m,
841
+ transitionTime: h,
842
+ styleOptions: _
843
+ }
844
+ );
845
+ return /* @__PURE__ */ l(
846
+ "div",
847
+ {
848
+ className: L,
849
+ role: "progressbar",
850
+ "aria-valuemin": e ? void 0 : 0,
851
+ "aria-valuemax": e ? void 0 : 100,
852
+ "aria-valuenow": e ? void 0 : Math.round(P * 100),
853
+ "aria-label": "Loading",
854
+ children: W ? /* @__PURE__ */ D(E, { children: [
855
+ R && /* @__PURE__ */ l("div", { className: f.overlayGraphic, children: R }),
856
+ M && /* @__PURE__ */ l("div", { className: [
857
+ f.overlayText,
858
+ p === "over" ? f.overlayText_over : f.overlayText_under
859
+ ].join(" "), children: M })
860
+ ] }) : /* @__PURE__ */ D(E, { children: [
861
+ R,
862
+ M
863
+ ] })
864
+ }
865
+ );
866
+ };
867
+ export {
868
+ Ve as HonestAILoader
869
+ };
package/dist/style.css ADDED
@@ -0,0 +1 @@
1
+ ._progressArc_6h5sx_7{transition:stroke-dashoffset .4s ease}._spinnerSvg_6h5sx_12{display:block;animation:_spin_6h5sx_12 1.2s linear infinite;transform-origin:var(--svg-cx, 50px) var(--svg-cx, 50px)}._progressSvg_6h5sx_18{display:block}@keyframes _spin_6h5sx_12{0%{transform:rotate(0)}to{transform:rotate(360deg)}}._track_1qpxj_1{width:240px;height:8px;background-color:#e5e7eb;border-radius:9999px;overflow:hidden;position:relative}._shimmer_1qpxj_11{position:absolute;top:0;right:0;bottom:0;left:0;background:linear-gradient(90deg,transparent 0%,var(--primary-color, #6366f1) 40%,color-mix(in srgb,var(--primary-color, #6366f1) 70%,white) 60%,transparent 100%);border-radius:inherit;animation:_shimmer_1qpxj_11 1.5s ease-in-out infinite}._progress_1qpxj_26{height:100%;background-color:var(--primary-color, #6366f1);border-radius:inherit;transition:width .4s ease;min-width:0}@keyframes _shimmer_1qpxj_11{0%{transform:translate(-100%)}to{transform:translate(100%)}}._text_du7p9_1{margin:0;font-size:.9rem;color:#6b7280;text-align:center;max-width:300px;min-height:1.5em;line-height:1.5;transition-property:opacity,transform;transition-timing-function:ease;transition-duration:var(--transition-time, .3s)}._fade_in_du7p9_15{opacity:0}._fade_visible_du7p9_19{opacity:1}._fade_out_du7p9_23{opacity:0}._scroll_in_du7p9_28{opacity:0;transform:translateY(10px)}._scroll_visible_du7p9_33{opacity:1;transform:translateY(0)}._scroll_out_du7p9_38{opacity:0;transform:translateY(-10px)}._wrapper_hvge4_2{display:inline-flex;flex-direction:column;align-items:center;justify-content:center;gap:16px}._pos_bottom_hvge4_11{flex-direction:column}._pos_top_hvge4_12{flex-direction:column-reverse}._pos_right_hvge4_13{flex-direction:row}._pos_left_hvge4_14{flex-direction:row-reverse}._pos_over_hvge4_17,._pos_under_hvge4_18{position:relative;gap:0;isolation:isolate}._overlayGraphic_hvge4_25{position:relative;z-index:1}._overlayText_hvge4_31{position:absolute;top:0;right:0;bottom:0;left:0;display:flex;align-items:center;justify-content:center;pointer-events:none}._overlayText_over_hvge4_41{z-index:2}._overlayText_under_hvge4_44{z-index:0}
package/package.json ADDED
@@ -0,0 +1,49 @@
1
+ {
2
+ "name": "honest-ai-loader",
3
+ "version": "0.1.0",
4
+ "description": "A configurable React TypeScript loading component with animated graphics and honest loading phrases",
5
+ "type": "module",
6
+ "main": "./dist/honest-ai-loader.cjs",
7
+ "module": "./dist/honest-ai-loader.js",
8
+ "types": "./dist/honest-ai-loader.d.ts",
9
+ "exports": {
10
+ ".": {
11
+ "import": {
12
+ "types": "./dist/honest-ai-loader.d.ts",
13
+ "default": "./dist/honest-ai-loader.js"
14
+ },
15
+ "require": {
16
+ "types": "./dist/honest-ai-loader.d.ts",
17
+ "default": "./dist/honest-ai-loader.cjs"
18
+ }
19
+ },
20
+ "./style.css": "./dist/style.css"
21
+ },
22
+ "files": [
23
+ "dist"
24
+ ],
25
+ "sideEffects": [
26
+ "**/*.css"
27
+ ],
28
+ "scripts": {
29
+ "dev": "vite",
30
+ "build": "tsc && vite build",
31
+ "build:lib": "vite build --config vite.lib.config.ts",
32
+ "preview": "vite preview",
33
+ "typecheck": "tsc --noEmit"
34
+ },
35
+ "peerDependencies": {
36
+ "react": "^18.0.0",
37
+ "react-dom": "^18.0.0"
38
+ },
39
+ "devDependencies": {
40
+ "@types/react": "^18.3.1",
41
+ "@types/react-dom": "^18.3.1",
42
+ "@vitejs/plugin-react": "^4.3.1",
43
+ "react": "^18.3.1",
44
+ "react-dom": "^18.3.1",
45
+ "typescript": "^5.5.3",
46
+ "vite": "^5.4.1",
47
+ "vite-plugin-dts": "^4.5.4"
48
+ }
49
+ }