add element rich text

This commit is contained in:
Yisroel Baum 2026-05-27 20:02:31 +03:00
parent 827abde41b
commit 457dbbb7de
Signed by: yisroelbaum
GPG key ID: 0FA60884F75520A9
12 changed files with 63 additions and 5 deletions

View file

@ -13,6 +13,7 @@ return new class extends Migration
$table->foreignId('set_id')->constrained('sets');
$table->string('title');
$table->text('description')->default('');
$table->text('rich_text')->default('');
$table->foreignId('parent_element_id')
->nullable()
->constrained('elements');

View file

@ -18,6 +18,9 @@ class ElementSeeder extends Seeder
set: $baderechSet,
title: $baderechSet->getName(),
description: $baderechSet->getDescription(),
richText: '<p>Begin with a clear map for avodah growth.</p>'
. '<p><strong>Move steadily</strong> from awareness '
. 'to practice.</p>',
parentElement: null,
));
$elementRepository->create(new CreateElementDto(
@ -25,12 +28,16 @@ class ElementSeeder extends Seeder
title: 'Avodah Foundations',
description: 'Core foundations for building a steady '
. 'avodah practice.',
richText: '<p>Avodah foundations begin with honest awareness '
. 'and small repeatable steps.</p>',
parentElement: $rootElement,
));
$elementRepository->create(new CreateElementDto(
set: $baderechSet,
title: 'Daily Practice',
description: 'Practical steps for consistent daily growth.',
richText: '<p>Daily practice turns inspiration into a '
. 'dependable rhythm.</p>',
parentElement: $rootElement,
));
}