from django.db import models
from django.utils.translation import gettext_lazy as _


class AbstractSEOFields(models.Model):
    seo_title = models.CharField(
        _("SEO Meta title"),
        max_length=255,
        help_text=_(
            "SEO Meta titles should be less than 60 characters, if left empty the product title will be used"
        ),
        blank=True,
        null=True,
    )
    seo_description = models.CharField(
        _("SEO Meta description"),
        max_length=1024,
        help_text=_(
            "SEO Meta descriptions should be less than 300 characters, if left empty the product description will be used"
        ),
        blank=True,
        null=True,
    )
    seo_keywords = models.CharField(
        _("SEO Meta keywords"),
        max_length=1024,
        help_text=_(
            "Meta Keywords don't make any improvements in SEO, use Meta description instead."
        ),
        blank=True,
        null=True,
    )

    class Meta:
        abstract = True
