-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Addons: allow to set a "Default" or a explicit position for flyout (#…
…11891) - Add a new `flyout_position` field to the `AddonsConfig` model - Show the field in the form - Return the field in the APIv3 to be consumed by the frontend ---- * Related readthedocs/addons#434
- Loading branch information
Showing
6 changed files
with
65 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 35 additions & 0 deletions
35
readthedocs/projects/migrations/0143_addons_flyout_position.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# Generated by Django 4.2.17 on 2025-01-08 11:15 | ||
|
||
from django.db import migrations, models | ||
from django_safemigrate import Safe | ||
|
||
|
||
class Migration(migrations.Migration): | ||
safe = Safe.before_deploy | ||
|
||
dependencies = [ | ||
('projects', '0142_update_dj_simple_history'), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterField( | ||
model_name='addonsconfig', | ||
name='flyout_enabled', | ||
field=models.BooleanField(default=True, verbose_name='Enabled'), | ||
), | ||
migrations.AddField( | ||
model_name='addonsconfig', | ||
name='flyout_position', | ||
field=models.CharField(blank=True, choices=[(None, 'Default (from theme or Read the Docs)'), ('bottom-left', 'Bottom left'), ('bottom-right', 'Bottom right'), ('top-left', 'Top left'), ('top-right', 'Top right')], default=None, max_length=64, null=True, verbose_name='Position'), | ||
), | ||
migrations.AlterField( | ||
model_name='historicaladdonsconfig', | ||
name='flyout_enabled', | ||
field=models.BooleanField(default=True, verbose_name='Enabled'), | ||
), | ||
migrations.AddField( | ||
model_name='historicaladdonsconfig', | ||
name='flyout_position', | ||
field=models.CharField(blank=True, choices=[(None, 'Default (from theme or Read the Docs)'), ('bottom-left', 'Bottom left'), ('bottom-right', 'Bottom right'), ('top-left', 'Top left'), ('top-right', 'Top right')], default=None, max_length=64, null=True, verbose_name='Position'), | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters