ramonai-widget
v0.1.34
Published
RamonAI embeddable shopping assistant widget (browser bundle)
Readme
RamonAI Widget
A responsive shopping assistant widget built with React and Vite. It renders a floating launcher and a chat panel that you can drop into any storefront.
Usage / embedding
Single tag (CDN or self-hosted)
Add one script tag anywhere in your page. Works in all projects (vanilla HTML, React, Vue, Next.js, etc.). type="module" is fine, but not required.
<script
type="module"
id="ramonai-widget"
src="https://cdn.jsdelivr.net/npm/ramonai-widget@latest/dist/ramonai-widget.js"
data-shop-name="Your Shop"
<!-- data-accent="#242424" -->
<!-- data-target="#ramonai-host" -->
></script>Supported attributes map to the public API:
data-shop-name: display name shown in the UI.data-accent(aliasdata-accent-color): hex/color string for the accent.data-target: optional CSS selector for a host element to mount into. If omitted, the widget creates a fixed host element and mounts into<body>.
Note: data-autoinit is not required. The widget auto-initializes when it detects the id="ramonai-widget" script or any meaningful config attributes.
Options
| name | type | default | description |
| --- | --- | --- | --- |
| shopName | string | "فروشگاه شما" | Display name shown in the widget greeting/labels. |
| accent | string | #242424 | Accent color used by the UI. |
| target | HTMLElement | undefined | Optional host element to mount the widget into. If omitted, a default fixed host is appended to <body>. |
Notes:
- The script auto-initializes from the tag and reads the attributes listed above.
data-accent-coloris accepted as an alias fordata-accent. - The library build inlines
process.envat build time, so no client polyfills are necessary.
