1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00
Commit Graph

85 Commits

Author SHA1 Message Date
Jeremy Stretch
a83b233341 Closes #15339: Consume entire viewport (#15480)
* Closes #15339: Consume entire viewport, except for object detail views

* Use fluid containers for all views
2024-03-20 08:26:04 -04:00
Jeremy Stretch
849a9d32d1 Fixes #15340: Fix flicker on page load with dark mode enabled (#15475) 2024-03-19 14:06:24 -04:00
Jeremy Stretch
239d21870b Closes #14871: Complete work on UI cleanup (#15341)
* Fix left padding of login button in top menu

* Relocate "add" buttons for embedded object tables

* Remove unused data template block & getNetboxData() utility function

* Remove bottom margin from last <p> element in rendered Markdown inside a table cell

* Prevent TomSelect from initializing on <select> elements with a size

* Fix styling of dropdown menu button for circuit commit rate

* Change .color-block to display: inline-block

* Delete unused static asset

* Improve contrast between menu group headings & items

* Remove custom color for attr-table row headings

* Fix border color of copy-to-clipboard button

* Fix toast text color in dark mode

* Fix rack elevation label/image toggles

* Increase border radius for small buttons

* Fix object selector
2024-03-04 15:55:01 -05:00
Jeremy Stretch
1d41a8ace5 Closes #14735: Implement django-htmx (#14873)
* Install django-htmx

* Replace is_htmx() function with request.htmx

* Remove is_embedded() HTMX utility

* Include django-htmx debug error handler
2024-01-22 12:09:15 -05:00
Jeremy Stretch
073c2dc8ca Closes #12128: Refresh the web UI to employ the Tabler CSS framework (#14833)
* Remove dark mode styling

* Condense & rename light mode stylesheet

* Upgrade to Bootstrap 5.3.2

* Swap out Bootstrap for Tabler; remove custom styling

* Update base page layout for Tabler

* Update login page

* Bump node to v18

* Update button styles

* Update object list view

* Tweak navbar size

* Clean up dashboard widgets

* Ditch separate stylesheet for print media

* Remove simplebar

* Remove obsolete sidebar styling

* Clean up object view template

* Clean up object edit template

* Standardize primary button sizing

* Clean up object list styling

* Add buttons for add & import to navigation menu

* Fix global search bar

* Fix slim-select form widget styling

* Fix toast styling

* Set base fonts

* Clean up paginator styling

* Clean up navigation menu group headings

* Clean up footer links

* Clean up card styles

* Move SVG styles to a designated directory

* Restructure SCSS files

* Remove obsolete/redundant dependencies

* Fix icon spacing

* Update background color classes

* Tweak banner & footer styling and spacing

* Fix badge background colors in table content

* Bump @types/bootstrap to 5.2.10

* Clean up form layouts

* Fix object selector button style

* Fix icon padding inside small buttons

* Fix icon & badge spacing inside buttons and tabs

* Hide paginator for empty pages

* Fix hover color for list items (Tabler bug #1694)

* Fix width of checkbox column in empty tables

* Clean up bulk edit template

* Fix border color of reslug button

* Package & serve Google fonts locally

* Fix tab styling

* Reduce vetical space at top of dashboard

* Remove obsolete content-wrapper template block

* Fix icon spacing in dropdown menu items

* Fix color label sizing

* Separate bulk delete form & object list into tabs

* Fix styling of filter group headings

* Fix styling for object changelog & journal views

* Standardize ordering & styling of action buttons

* Fix designation of active menu item

* Automatically expand menu section containing the active link

* Clean up nav menu styling

* Remove button colors; hide buttons except on hover/active

* Highlight menu group containing the active item

* Update & standardize alert styling

* Refactor base templates to ensure consistent display of header content

* Tweak styling for links inside badges

* Clean up top menu

* Fix JSON/YAML toggles for config context data

* Fix object template header

* Constrain tabs to container-xl; tweak header margins

* Fix object identifier styling

* Fix positioning of card header buttons

* Remove padding from HTMX tables inside cards

* Ensure consistent use of row headings in attribute tables

* Remove padding surrounding tables inside cards

* Remove obsolete CSS classes

* Misc cleanup of old styling

* Refactor 'controls' template block; ditch old classes

* Fix login button sizing

* Limit object edit form width

* Append asterisk to required form field labels

* Remove obsolete styling

* Remove obsolete styling

* Fix position of progress bar outside label

* Fix alignment of delete button in report/script lists

* Fix <pre> styling

* Clean up page headers

* Replace SVG icons with Material Design icons

* Restore dark mode togle functionality

* Fix top navbar background color under dark mode

* Rebuild static assets
2024-01-17 16:25:42 -05:00
Jeremy Stretch
ab0442bd5c Fix typo 2023-07-31 08:24:03 -04:00
Arthur Hanson
7c17d2e932 Closes #13102: Establish initial translation support in templates
---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
2023-07-28 16:30:25 -04:00
Abhimanyu Saharan
e71a98499f Adds BANNER_MAINTENANCE config (#12555)
* adds BANNER_MAINTENANCE config #12554

* changes as per review

* lint fix

* Fix admin form field widget

---------

Co-authored-by: jeremystretch <jstretch@netboxlabs.com>
2023-05-12 09:54:59 -04:00
jeremystretch
1146aaff89 Closes #11453: Display a warning banner when DEBUG is enabled 2023-04-10 09:12:04 -04:00
Robin Schneider
07df622b59 NetBox should always be referred to as NetBox [DATALAD RUNCMD]
=== Do not change lines below ===
{
 "chain": [],
 "cmd": "git ls-files -z . | xargs --null -I '()' find './()' -type f -not -name 'style-guide.md' -print0 | xargs --null sed --in-place --regexp-extended 's/\\bNetbox\\b/NetBox/g;'",
 "exit": 0,
 "extra_inputs": [],
 "inputs": [],
 "outputs": [],
 "pwd": "."
}
^^^ Do not change lines above ^^^
2023-01-05 16:06:00 -05:00
jeremystretch
5a77791f9d Merge branch 'develop' into feature 2022-12-08 09:31:22 -05:00
Jeremy Stretch
d2d60c0607 Fixes #11087: Fix background color of bottom banner content 2022-12-06 15:40:59 -05:00
jeremystretch
2f96fdd135 Merge branch 'develop' into feature 2022-11-16 11:42:32 -05:00
Arthur Hanson
4ebcdd2b8f 8072 move js code from template to static file (#10824) 2022-11-03 09:29:45 -04:00
Jeremy Stretch
9628dead07 Closes #10560: New global search (#10676)
* Initial work on new search backend

* Clean up search backends

* Return only the most relevant result per object

* Clear any pre-existing cached entries on cache()

* #6003: Implement global search functionality for custom field values

* Tweak field weights & document guidance

* Extend search() to accept a lookup type

* Move get_registry() out of SearchBackend

* Enforce object permissions when returning search results

* Add indexers for remaining models

* Avoid calling remove() on non-cacheable objects

* Use new search backend by default

* Extend search backend to filter by object type

* Clean up search view form

* Enable specifying lookup logic

* Add indexes for value field

* Remove object type selector from search bar

* Introduce SearchTable and enable HTMX for results

* Enable pagination

* Remove legacy search backend

* Cleanup

* Use a UUID for CachedValue primary key

* Refactoring search methods

* Define max search results limit

* Extend reindex command to support specifying particular models

* Add clear() and size to SearchBackend

* Optimize bulk caching performance

* Highlight matched portion of field value

* Performance improvements for reindexing

* Started on search tests

* Cleanup & docs

* Documentation updates

* Clean up SearchIndex

* Flatten search registry to register by app_label.model_name

* Clean up search backend classes

* Clean up RestrictedGenericForeignKey and RestrictedPrefetch

* Resolve migrations conflict
2022-10-21 13:16:16 -04:00
6a3ccda12e Add padding to the bottom of the sidebar 2022-08-30 15:57:04 +02:00
Arthur
cdea30253b #101700 change csrf token access 2022-08-29 14:57:56 -07:00
jeremystretch
15005209d1 Merge branch 'develop' into feature 2022-03-18 13:34:31 -04:00
PieterL75
0da04232f3 Fixes #8813 Retain search value after submitting (#8907)
* Fixes #8813 Retain search value after submitting

* remove autofocus from searchbar

Co-authored-by: Pieter Lambrecht <pieter.lambrecht@sentia.com>
2022-03-18 13:23:39 -04:00
jeremystretch
cd29293dd6 Merge v3.1.9 2022-03-07 10:55:30 -05:00
Jeremy Stretch
85e9438ff7 Merge pull request #8734 from emersonfelipesp/add_pluginfooter_block
Closes #8733: Add {% block pluginfooter %} to 'base/layout.html' template
2022-03-04 16:07:54 -05:00
Emerson Pereira
28de330b50 Replace 'pluginfooter' block with 'footer' and 'footer_links' blocks
- 'footer' blocks represents the <footer> html tag
- 'footer_links' are the anchor tags inside nav
2022-02-26 01:13:11 -03:00
jeremystretch
fab4d95156 Merge branch 'develop' into feature 2022-02-25 14:06:45 -05:00
thatmattlove
c88db77814 Fixes #8633: Recheck sidenav state on window resize
* Recheck sidenav state on window resize
* Remove `data-sidenav-pinned` attribute when hiding sidenav
* Remove `data-sidenav-hidden` attribute when showing sidenav
2022-02-25 11:23:14 -07:00
Emerson Pereira
c489501441 Add {% block pluginfooter %} to 'base/layout.html' template
Makes it easy to insert footer information into Netbox footer.
2022-02-24 00:38:11 -03:00
jeremystretch
1e55d064ab Document the base layout template 2022-02-08 11:45:23 -05:00
jeremystretch
2524290099 Introduce modals template block 2022-01-05 09:21:48 -05:00
jeremystretch
0a22b3990f #7450: Clean up footer and navbar styles 2022-01-04 20:42:44 -05:00
jeremystretch
b0350e9e96 Remove navbar background color 2021-12-29 08:56:59 -05:00
jeremystretch
d650d10cb2 #7449: Apply distinctive styling to top navbar 2021-12-22 15:32:35 -05:00
jeremystretch
f369b5f588 Reorganize & clean up templatetag templates 2021-12-22 15:05:24 -05:00
jeremystretch
ceb941df81 Closes #8135: Append version when fetching static assets 2021-12-21 13:00:52 -05:00
Jeremy Stretch
4a3bc8d365 Merge pull request #8111 from bonktree/opaque-icon
templates: add an opaque icon for mobile home screens
2021-12-20 13:58:25 -05:00
jeremystretch
14fc37a8b8 Closes #7661: Remove forced styling of custom banners 2021-12-19 15:33:48 -05:00
Arseny Maslennikov
7b23856cc8 templates: add an opaque icon for mobile home screens
The netbox_touch-icon-180.png icon was produced by rendering
netbox_icon.svg into a 160x160 square, centered in a 180x180 PNG filled
by the background colour of #212529.

In other words, it is a screenshot of the following HTML element:
```html
  <div style="width: 180px;height: 180px;background-color: #212529;">
  <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 320 320" style="padding: 10px;">
    <g fill="#9cc8f8" stroke="#9cc8f8">
      <circle cx="37" cy="284" r="23"></circle>
      <circle cx="101" cy="37" r="23"></circle>
      <circle cx="101" cy="220" r="23"></circle>
      <circle cx="284" cy="220" r="23"></circle>
      <rect x="93" y="37" width="16" height="180"></rect>
      <rect x="101" y="212" width="180" height="16"></rect>
      <rect x="93" y="212" width="16" height="90" transform="rotate(45 101 220)"></rect>
    </g>
    <g fill="#1685fc" stroke="#1685fc">
      <circle cx="284" cy="37" r="23"></circle>
      <circle cx="37" cy="101" r="23"></circle>
      <circle cx="220" cy="101" r="23"></circle>
      <circle cx="220" cy="284" r="23"></circle>
      <rect x="37" y="93" width="180" height="16"></rect>
      <rect x="212" y="101" width="16" height="180"></rect>
      <rect x="212" y="93" width="16" height="90" transform="rotate(225 220 101)"></rect>
    </g>
  </svg>
  </div>
```
2021-12-19 01:32:15 +03:00
jeremystretch
d2391b9c63 Move GRAPHQL_ENABLED to dynamic configuration 2021-11-08 15:31:09 -05:00
jeremystretch
2c2e37e9f0 Merge branch 'develop' into feature 2021-11-03 10:29:02 -04:00
thatmattlove
a090955918 Fixes #7599: Improve color mode handling 2021-10-27 11:34:21 -07:00
jeremystretch
94804fecd8 Add MAINTENANCE_MODE, MAPS_URL 2021-10-26 10:57:33 -04:00
jeremystretch
82243732a1 Initial work on #5883 2021-10-25 16:10:50 -04:00
thatmattlove
14b065cf5f Fixes #7373: Improve handling of mismatched server, client, and browser color-mode preferences 2021-09-29 17:44:28 -07:00
thatmattlove
4b14b31853 Use url_name instead of request.path for view-based styles 2021-09-01 15:22:38 -07:00
jeremystretch
f63dcb1f08 #7091: Simplify access to BASE_PATH variable 2021-09-01 09:34:33 -04:00
thatmattlove
679bbd3e76 Fixes #7091: Ensure API requests from the UI are aware of BASE_PATH 2021-08-31 15:13:53 -07:00
jeremystretch
4f36885c5e Fixes #7096: Home links should honor BASE_PATH configuration 2021-08-31 09:44:59 -04:00
jeremystretch
556efcc1d7 Fixes #7045: Fix navigation menu rendering under Chrome 2021-08-30 09:56:05 -04:00
jeremystretch
87dad41c37 Tweak logo size on mobile 2021-08-20 15:21:26 -04:00
Matt
517c0e2fe6 Fixes #6996: Make search bar full width on small screens 2021-08-20 08:54:00 -07:00
Matt
9e1d2da449 Fixes #7001: Focus the main content container when the page loads 2021-08-19 14:13:54 -07:00
Matt
09d745d987 Fixes #6976: Improve handling of printing layouts/styling 2021-08-18 16:17:50 -07:00