# Generated by Django 4.2.8 on 2024-01-09 15:07

from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):
    dependencies = [
        ("books", "0045_alter_snapshot_objective_groups"),
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ("notes", "0004_auto_20210322_1514"),
    ]

    operations = [
        migrations.CreateModel(
            name="Highlight",
            fields=[
                (
                    "id",
                    models.AutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("content_index", models.IntegerField()),
                ("content_uuid", models.UUIDField()),
                ("paragraph_index", models.IntegerField()),
                ("start_position", models.IntegerField()),
                ("selection_length", models.IntegerField()),
                ("text", models.TextField()),
                ("color", models.CharField(max_length=50)),
                (
                    "content_block",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="highlights",
                        to="books.contentblock",
                    ),
                ),
                (
                    "user",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        to=settings.AUTH_USER_MODEL,
                    ),
                ),
            ],
        ),
    ]
