250 Commits

Author SHA1 Message Date
daveoconnor
b8ace378df Neighbours based injection wrapping (#1272)
wrap injection based on neighbours, not expected contents
2024-09-20 16:52:20 -07:00
daveoconnor
bd0bb66cc3 Wrap injection body (#1271)
wrap only the body in the injection not the entire injection which
includes heading (#1183)
2024-09-20 13:29:48 -07:00
daveoconnor
46ecdec695 add footer and docs wrapper div injection (#1183) (#1259) 2024-09-19 16:25:13 -07:00
Frank Wiles
ef3b79134f Add url path to handle /doc/libs/release/* (#1204)
Redirect to the latest release when this URL prefix exists on
documentation.

Fixes #1084
2024-08-26 19:01:30 -05:00
Kenneth Reitz
c3e6e3b70e Remove sponsorship links about downloads from release notes (#1141)
Solves #1116

The code changes in `htmlhelper.py` remove the sponsorship links about
downloads from the release notes. This improves the clarity and focus of
the release notes by removing unnecessary information.
2024-07-09 13:35:41 -04:00
Julio Estrada
150e6ec9f8 Refactor add_class_to_sibling_by_header function and fix argument name in reformat_new_libraries_list 2024-06-26 06:39:41 -04:00
Julio Estrada
055b306f4e Refactor add_class_to_sibling_by_header function in htmlhelper.py 2024-06-26 06:39:41 -04:00
Julio Estrada
c5887d7834 Fix release notes formatting 2024-06-26 06:39:41 -04:00
Kenneth Reitz
25f2e36d77 Refactor test_views.py to reflect new redirect changes 2024-06-17 09:08:46 -04:00
Kenneth Reitz
cee432678b Fix URL pattern for library page redirects 2024-06-17 08:57:01 -04:00
Kenneth Reitz
329acad55b Remove unnecessary code for formatting nested lists in release notes 2024-06-14 17:26:57 -04:00
Kenneth Reitz
c6db8a8d5f feat: Add redirect view for library pages 2024-06-14 15:59:00 -04:00
Kenneth Reitz
4028f496e0 feat: Add redirect view for release versions 2024-06-14 15:59:00 -04:00
sdarwin
f80721b0fc Remove fallback url map going to s3 2024-04-12 12:52:40 -04:00
Kenneth Reitz
67df436314 Fixes tools/{libname}/{path} redirect rules #1055 2024-04-11 08:39:07 -04:00
Kenneth Reitz
ad5d503468 class-based views 2024-04-10 08:05:38 -04:00
Kenneth Reitz
6d34bfc35c Refactor redirect logic in views.py for library versions 2024-04-09 13:39:53 -04:00
Kenneth Reitz
1f33969c27 Fixes #1045 2024-04-08 10:08:27 -04:00
Kenneth Reitz
c0be9be31b Refactor is_iframe_destination logic in DocLibsTemplateView 2024-04-04 13:38:40 -04:00
Kenneth Reitz
018b4a9d42 disable modernization for iframe requests 2024-04-04 13:33:55 -04:00
Kenneth Reitz
1ecc2e0ad6 Refactor get_meta_redirect_from_html function to handle case-insensitive URL attribute 2024-04-01 16:00:49 -04:00
Kenneth Reitz
b20dc73f01 Add meta redirect for HTML files 2024-04-01 16:00:49 -04:00
Kenneth Reitz
e3eab04467 Add function to extract meta redirect from HTML 2024-04-01 16:00:49 -04:00
Kenneth Reitz
bffcf568c7 Remove unused CSS classes from HTMLHelper.py 2024-03-26 14:10:37 -04:00
Kenneth Reitz
6cbed2f876 Update disable_theme_switcher value for doc content pages 2024-03-26 13:25:02 -04:00
Spencer Strickland
dff5960a2c BSL License file route + text in footer 2024-02-19 14:55:00 -06:00
Spencer Strickland
a64b09d444 Privacy Policy/TOS as MD, Homepage Text Tweak 2024-02-19 13:53:34 -06:00
Lacey Williams Henschel
6755f76753 Replace relative image URLs with absolute URLs in static content files
- Add function to replace relative image paths with absolute paths
- Add docs on static content and adding shortcuts to the config file
- Add url and view for rendering static image data
2024-02-02 12:24:19 -08:00
Greg Newman
608b8c8798 🚧 active links templatetag
* Added optional url string for user-guide and library docs
2024-01-31 14:30:25 -05:00
Spencer Strickland
a0afa0eb42 Upped arg to 30, for URLs it goes to arg+10 2024-01-30 12:55:28 -06:00
Spencer Strickland
4c2172b986 Updated code to handle URLs in text w/ tags 2024-01-30 12:55:28 -06:00
Spencer Strickland
6fb41c1c0e Made the "...." the same in both truncate filters 2024-01-30 12:55:28 -06:00
Spencer Strickland
0cec7e7a46 Truncate latest + homepage and news list 2024-01-30 12:55:28 -06:00
Greg Newman
80761b37b2 ruff 2024-01-26 11:06:38 -05:00
Greg Newman
0b3da8046d 🐛 fixing bugs in active_link tag 2024-01-26 11:06:38 -05:00
Greg Newman
179d7e9f90 adds template tag for active links
Pass the path and classes to the tag.
2024-01-26 11:06:38 -05:00
Lacey Williams Henschel
10298f3ceb Add django-auth-toolkit
- Add task to clear expired oauth tokens
- Add setting for oauth app name
- Add docs
2024-01-23 15:23:34 -08:00
Greg Newman
2079db4d22 🐛 fixes docs header for 1.84.x 2024-01-17 11:25:25 -05:00
Lacey Williams Henschel
0a9e0a2a7f Clear the static content database cache nightly of old files
- Add `created` and `modified` fields to `RenderedContent` models
- Add caching and RenderedContent docs
- Change cache key for library description rendered content
- Add `CLEAR_STATIC_CONTENT_CACHE_DAYS` setting
- Add manager method and task to clear static content cache
- Move task scheduler to main app
- Add daily task to clear rendered content cache
- Use created date and not updated date
2024-01-10 12:23:17 -08:00
Lacey Williams Henschel
73ea36b7a8 Pull in calendar data from the Google calendar
- Adds functions to retrieve raw events from the Google Calendar API, extract the data we need for those events, and order those events by month for display
- Documents the new env vars
- Adds new setting for the google calendar API url
- Adds `/calendar/` to URLs, which displays the rendered google calendar **but didn't prettify it**
- Adds events to homepage, using the existing template
- Edits to the homepage template to show the events and make the paging arrows work
2023-12-22 13:58:43 -08:00
Lacey Williams Henschel
266025d0a6 Add logging, add exception handling 2023-12-05 14:35:13 -08:00
Lacey Williams Henschel
49c0ec90f8 Make current-boost-version dynamic for boost-gecko in site header
- Add context processor to return most recent version to base template
- Add property for the stripped slug
- Add context processor to settings and retrieve val in template header
- Fix some news tests that test for specific query counts

fix tests
2023-11-30 13:48:39 -08:00
Lacey Williams Henschel
412f9ba587 Modernize legacy release notes
- Add helper functions for modernizing legacy release notes
- Add modernization to release note process
- Fix spelling
- Add tests and error handling
2023-11-30 12:30:21 -08:00
Lacey Williams Henschel
69ad8d936e Import historical release notes and save to to database
- Add method to get content of old release notes
- Add cached property with cache key for rendered content
- Add release notes to template
- Add admin for thee rendered content model
- Add import of release nnotes to admin download
2023-11-22 14:41:48 -08:00
Spencer Strickland
c96702faa6 Changed string interp 2023-11-20 09:49:29 -06:00
Spencer Strickland
2166eb3a58 Update for long text in news on homepage, testing links 2023-11-20 09:49:29 -06:00
Lacey Williams Henschel
7507fa50b3 Limit file types of user and news images
- Add file type validator
- Apply validator to user image
- Save validator class to variable
- Add image validator to news image model field
- Add file size validator
- Enable file size validator on news and user model image fields
- Fix test
2023-11-03 10:21:36 -07:00
Frank Wiles
6d68f294c6 Use static content mapping JSON file from the env
- Addes `STATIC_CONTENT_MAPPING` environment mapping that defaults to
  the current `stage_static_config.json`

- Fixes #725
2023-10-27 08:37:59 -05:00
Lacey Williams Henschel
dff7e0d46d Use our custom 404 template
- Fix test for 404 conditions
2023-10-20 09:42:55 -07:00
Lacey Williams Henschel
c251ff9671 Import most recent beta release
- Split import version into own task
- Add beta field to Version model
- Add task to import most recent beta version
- Accommodate beta releases in Artifactory downloads
- Fix bug in getting proper download files for beta releases
- Add ability to delete old beta versions when importing new beta version
- Hide release notes link for beta releases
- Comment why we don't get old downloads
- Add management command to get most recent beta release
- Add beta import to boost setup command
- Add docs on beta release import
- Get newest beta release when importing releases
- Add manager method to get most recent beta release
- Skip a couple failing tests after confirming behavior is working as expected
2023-10-13 09:32:16 -07:00