refactor: rename 'recit' to 'narrative' for English code naming
- Rename store: recit.js → narrative.js (useRecitStore → useNarrativeStore) - Rename templates: recit.php/json.php → narrative.php/json.php - Rename blueprint: recit.yml → narrative.yml - Update all imports and references in Vue/JS files - Update PHP template references and data attributes - Update CLAUDE.md documentation - Create comprehensive README.md with English-French dictionary The dictionary section maps English code terms to French content terms for easier navigation between codebase and CMS content. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
ea0994ed45
commit
af788ad1e0
12 changed files with 267 additions and 66 deletions
20
src/App.vue
20
src/App.vue
|
|
@ -6,14 +6,14 @@ import PagePopup from './components/PagePopup.vue';
|
|||
import PreviewLoader from './components/PreviewLoader.vue';
|
||||
import { onMounted, ref, watch, computed, provide } from 'vue';
|
||||
import { useStylesheetStore } from './stores/stylesheet';
|
||||
import { useRecitStore } from './stores/recit';
|
||||
import { useNarrativeStore } from './stores/narrative';
|
||||
import Coloris from '@melloware/coloris';
|
||||
|
||||
const stylesheetStore = useStylesheetStore();
|
||||
const recitStore = useRecitStore();
|
||||
const narrativeStore = useNarrativeStore();
|
||||
|
||||
// Get recit URL from body data attribute (set by print.php template)
|
||||
const recitUrl = document.body.dataset.recitUrl || null;
|
||||
// Get narrative URL from body data attribute (set by print.php template)
|
||||
const narrativeUrl = document.body.dataset.narrativeUrl || null;
|
||||
const previewFrame1 = ref(null);
|
||||
const previewFrame2 = ref(null);
|
||||
const elementPopup = ref(null);
|
||||
|
|
@ -488,11 +488,11 @@ watch(
|
|||
}
|
||||
);
|
||||
|
||||
// Re-render when recit data changes
|
||||
// Re-render when narrative data changes
|
||||
watch(
|
||||
() => recitStore.data,
|
||||
() => narrativeStore.data,
|
||||
() => {
|
||||
if (recitStore.data) {
|
||||
if (narrativeStore.data) {
|
||||
renderPreview();
|
||||
}
|
||||
}
|
||||
|
|
@ -558,9 +558,9 @@ const printPreview = async () => {
|
|||
};
|
||||
|
||||
onMounted(async () => {
|
||||
// Load recit data if URL is provided (print mode)
|
||||
if (recitUrl) {
|
||||
await recitStore.loadRecit(recitUrl);
|
||||
// Load narrative data if URL is provided (print mode)
|
||||
if (narrativeUrl) {
|
||||
await narrativeStore.loadNarrative(narrativeUrl);
|
||||
}
|
||||
|
||||
// Render preview after data is loaded
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue