This is an Otzaria plugin project. Otzaria is a Jewish texts library application, and this plugin extends its functionality using web technologies.
- Otzaria Plugin SDK: JavaScript/TypeScript SDK for interacting with the host application
- Material Design 3: UI component library for consistent design
- Web Technologies: HTML, CSS, JavaScript/TypeScript
- Manifest-Driven: All plugin metadata, permissions, and capabilities are declared in
manifest.json - WebView-Based: Plugins run in a sandboxed WebView environment
- Event-Driven: Communication with the host uses an event-based API (
Otzaria.call()andOtzaria.on())
- Keep source code in the
src/directory - Entry point is specified in the manifest (
entrypointfield) - Use TypeScript definitions from
otzaria_plugin.d.tsfor type safety
Always declare required permissions in the manifest:
search.fulltext.read- Search library contentreader.open- Open books in the readerui.feedback- Show UI messagesplugin.storage.read/write- Store plugin datacalendar.read- Access calendar datapublished_data.write- Publish data to the app
- Type Safety: Use TypeScript and the provided type definitions
- Error Handling: Always check
response.successwhen callingOtzaria.call() - Responsive Design: Support both RTL and LTR layouts
- Theme Integration: Listen to
theme.changedevents and adapt UI accordingly - Minimal Permissions: Only request permissions actually needed
- Network Restrictions: Declare network access requirements in manifest
- Test in Otzaria debug mode with hot reload enabled
- Verify all permissions are properly declared
- Test with both light and dark themes
- Test RTL layout (Hebrew interface)
Otzaria.on('plugin.boot', (bootData) => {
// Initialize with boot data
console.log('Plugin ID:', bootData.plugin.id);
console.log('App version:', bootData.app.version);
console.log('Theme:', bootData.theme.mode);
});
Otzaria.on('plugin.ready', () => {
// Plugin is fully ready
});const response = await Otzaria.call('library.findBooks', {
query: 'search term'
});
if (response.success) {
console.log('Results:', response.data);
} else {
console.error('Error:', response.error);
}Otzaria.on('theme.changed', (theme) => {
document.body.style.backgroundColor = theme.colorScheme.surface;
document.body.style.color = theme.colorScheme.onSurface;
});Use Material Design 3 components for consistent UI:
- Import from CDN or npm package
- Apply theme colors from
bootData.theme.colorScheme - Follow Material Design guidelines for Hebrew/RTL layouts
- Use browser DevTools (available in debug mode)
- Check manifest validation errors in the error screen
- Monitor console for API call responses
- Use
ui.showMessagefor user-facing feedback
- Otzaria Plugin SDK documentation in the SDK folder
- Material Design 3: https://m3.material.io/
- TypeScript definitions:
otzaria_plugin.d.ts
חודש משפיע רק פעם אחת בודדה: לא ניתן לעצור את השפעתו.
כל תנאי חייב להכתב בקובץ ׳הלכות.md׳, אין תנאי שנמצא ברדמי ולא בקוד, אין תנאי שנמצא בקוד ולא ב׳הלכות.md׳!
יש לבצע הפרדה מבנית (מבחינה לוגית) בין הגדרת זמני טומאה לזמני פרישה: זמני טומאה רק המשתמש מזין, זמני פרישה רק התוכנה מחשבת.
יש לבצע הפרדה בין חישוב ימי הפרישה: ווסת שאינו קבוע, ווסת קבוע.
משמעות ווסת קבוע, היינו שאירוע הטומאה חזר על עצמו בדיוק במשך 3 פעמים. ווסת זה ממשיך עד לעצירתו, גם כשאין יותר ראייה. עצירה הינה אי-ראייה במשך 3 פעמים, בתנאי שזמן ה"אירוע" לא כלל את היום הרלוונטי.
ווסת שאינו קבוע הוא האירוע הרגיל, וכל פעם מחושב שנפרד ומבוטל לפעם הבאה, אלא שאם הפעם הבאה.,...