A lightweight, customizable floating button component that can be easily integrated into any website. The button appears on the side of your page and can be configured to link to any URL.
- 🎯 Easy to integrate
- 🎨 Modern design with Tailwind CSS
- 📱 Fully responsive
- ⚙️ Customizable position, text, and target URL
- 🔄 Dynamic updates supported
- 🪶 Lightweight with minimal dependencies
Install the package using npm:
npm install activity-finder-button
Add the following script tag to your HTML page:
<script src="https://cdn.jsdelivr.net/npm/activity-finder-button@latest/dist/activityFinder.js"></script>
<!-- Initialize the Activity Finder -->
<script>
document.addEventListener("DOMContentLoaded", function () {
const activityFinder = new ActivityFinder({
orgId: "1",
buttonText: "Aktivitäten finden",
position: "right"
});
});
</script>
Initialize the button with your desired configuration:
const activityFinder = new ActivityFinder({
orgId: "1"
buttonText: "Find Activities",
position: "right",
});
Option | Type | Default | Description |
---|---|---|---|
orgId |
string | '1' | Organization ID for the activity finder |
buttonText |
string | 'Activity Finder' | Text displayed on the button |
position |
'right'| 'left' | 'right' | Button position on the screen |
view |
'desktop'| 'mobile' | 'tablet' | 'desktop' | Controls the width of the activity finder panel |
language |
'en'| 'de' | auto-detected | Language for the activity finder interface |
// ... existing documentation ...
The button uses Tailwind CSS for styling, which is automatically injected into your page. It features:
- Modern, clean design
- Hover effects
- Shadow effects
- Smooth transitions
- Responsive sizing
<!DOCTYPE html>
<html>
<head>
<title>Activity Finder Example</title>
</head>
<body>
<script src="https://cdn.jsdelivr.net/npm/activity-finder-button@1.0.0/dist/activityFinder.js"></script>
<script>
document.addEventListener("DOMContentLoaded", function () {
const activityFinder = new ActivityFinder({
orgId: "1",
});
});
</script>
</body>
</html>
- Chrome (latest)
- Firefox (latest)
- Safari (latest)
- Edge (latest)
- Opera (latest)
MIT © Shreeyash Haritashya, Hyll
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
For support, please open an issue in the issue tracker.