Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hera/add main layout #1318

Open
wants to merge 323 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 250 commits
Commits
Show all changes
323 commits
Select commit Hold shift + click to select a range
13134bd
remove hacks from content containers
MattBudz Nov 26, 2024
0e95b37
migrate JS from tylium
MattBudz Nov 26, 2024
10afaf5
add missing styles
MattBudz Nov 26, 2024
4a6299c
cleanup tylium remnants
MattBudz Nov 26, 2024
2b05a00
Update design of issue collection
nicolachr Nov 26, 2024
eea51a9
clean up variables
MattBudz Nov 26, 2024
92139ce
redundant variable
MattBudz Nov 26, 2024
ccb74f0
revert debugging
MattBudz Nov 26, 2024
11d85d3
split navbar to it's own branch
MattBudz Nov 26, 2024
bae9b74
Revert "split navbar to it's own branch"
MattBudz Nov 26, 2024
dba71e3
split node tree sidebar to it's own branch
MattBudz Nov 26, 2024
6553c83
Revert "split node tree sidebar to it's own branch"
MattBudz Nov 26, 2024
95f3e3e
Merge branch 'hera/add-main-layout' into hera/add-navbar
MattBudz Nov 26, 2024
51abe12
Merge branch 'hera/add-main-layout' into hera/add-secondary-sidebar
nicolachr Nov 27, 2024
45d39bf
Fix layout from break from deleted variable
nicolachr Nov 27, 2024
436543b
Import sidebar.scss and update variable names
nicolachr Nov 27, 2024
e761427
Allow two lines for issue titles
nicolachr Nov 27, 2024
782751c
[Semantics] update class name
nicolachr Nov 27, 2024
4b13297
Ensure secondary-sidebar is rendered conditionally
nicolachr Nov 27, 2024
f5cd07a
Update import issues section
nicolachr Nov 27, 2024
e627ff5
add missed stylesheet
MattBudz Nov 27, 2024
78a69c6
remove commented css and redundant import
MattBudz Nov 27, 2024
511206d
remove legacy stylesheet
MattBudz Nov 27, 2024
999db13
remove tylium layout
MattBudz Nov 27, 2024
9a3d407
use updated variables names in `attachments.scss`
MattBudz Nov 27, 2024
8b2fa61
re-add missed `sticky-top` class
MattBudz Nov 27, 2024
0bc7bb6
clean up sticky top
MattBudz Nov 27, 2024
4b3daa4
remove old restrict-height modifier
MattBudz Nov 27, 2024
76b03b4
move colors to shared
MattBudz Nov 27, 2024
d16f5a5
remove unnecessary div in `<main>`
MattBudz Nov 27, 2024
bb53d76
improve parity
MattBudz Nov 27, 2024
c4f462c
Merge branch 'hera/add-main-layout' into hera/add-navbar
MattBudz Nov 27, 2024
9f254cf
Merge branch 'hera/add-main-layout' into hera/add-node-tree
MattBudz Nov 27, 2024
8733002
Update attachment box
nicolachr Nov 27, 2024
125936e
Fix identation
nicolachr Nov 27, 2024
548bdf4
Update design for attachments
nicolachr Nov 28, 2024
a37f169
Add JS to enable toggle functionality
nicolachr Nov 28, 2024
84c9f01
Fix indentation
nicolachr Nov 28, 2024
654998e
Minor design attachments
nicolachr Nov 28, 2024
cf11c29
Rotate chevrons when collections are toggled
nicolachr Nov 28, 2024
08029d4
Ensure last collection item doesn't have bottom border
nicolachr Nov 28, 2024
69e6ed2
Update edit and delete icons
nicolachr Nov 28, 2024
474c0bc
Revert new item buttons to inline + btn
nicolachr Nov 28, 2024
77a18f1
Remove unessecary HTML + adjust design
nicolachr Nov 28, 2024
ec032b5
Fix positioning of sidebar toggle button
nicolachr Nov 28, 2024
201c221
Ensure border: none in last item is applied correctly
nicolachr Nov 28, 2024
ca82076
Allow more space for sidebar toggle button
nicolachr Nov 28, 2024
e5b1a99
fix node tree loading/error copy persisting
MattBudz Nov 28, 2024
6de24b7
remove poor class modification
MattBudz Nov 28, 2024
9fb209a
fix sidebar being too tall
MattBudz Nov 28, 2024
453dc5d
ensure all text is pretty wrapped
MattBudz Nov 28, 2024
f55bf64
improve spacing
MattBudz Nov 28, 2024
a052ff5
fix sidebar scrolling when view content is tall
MattBudz Nov 28, 2024
5ac15a7
use $text-link variable for links
MattBudz Nov 28, 2024
e0b94d3
Merge branch 'hera/add-main-layout' into hera/add-node-tree
MattBudz Nov 28, 2024
d6a332f
Merge branch 'hera/add-main-layout' into hera/add-navbar
MattBudz Nov 28, 2024
cd700b4
Update design for search form
nicolachr Nov 28, 2024
16e3462
Update design for instance nav
nicolachr Nov 28, 2024
06e5acb
Merge branch 'hera/add-navbar' of https://github.com/dradis/dradis-ce…
nicolachr Nov 28, 2024
05b8fd5
ensure nav links are white to prevent bad contrast
MattBudz Nov 28, 2024
a7b5d7e
fix notifications menu not loading
MattBudz Nov 28, 2024
78690b7
Merge branch 'hera/add-navbar' of https://github.com/dradis/dradis-ce…
MattBudz Nov 28, 2024
7a6d5c6
Revert "ensure nav links are white to prevent bad contrast"
MattBudz Nov 28, 2024
6ecc1a5
Allow navbar to stretch
nicolachr Nov 29, 2024
2ef4d8a
Adjust styling of dropdown menus
nicolachr Nov 29, 2024
55c89b6
Adjust spacing in project navbar
nicolachr Nov 29, 2024
85be1e6
Allow more space below search form in mobile devices
nicolachr Nov 29, 2024
e6224bf
Make project navbar collapsible & code consistency
nicolachr Nov 29, 2024
c6153dc
Fix project navbar toggle functionality
nicolachr Nov 29, 2024
5602e81
Design adjustments for project navbar
nicolachr Nov 29, 2024
0f57e4f
Navigation styling for smaller devices
nicolachr Nov 29, 2024
dd06954
Change bin to trash
nicolachr Nov 29, 2024
82af995
Change sidebar color to white
nicolachr Nov 29, 2024
7e6f03b
Ensure project title is visible in the Dashboard
nicolachr Nov 29, 2024
6b9edd6
fix project nav not getting active classes
MattBudz Nov 29, 2024
1381b53
typo
MattBudz Nov 29, 2024
e5bcbf1
Merge branch 'hera/add-main-layout' into hera/add-secondary-sidebar
MattBudz Nov 29, 2024
c731a5a
Merge branch 'hera/add-node-tree' into hera/add-secondary-sidebar
nicolachr Nov 29, 2024
c480a42
Merge branch 'hera/add-secondary-sidebar' of https://github.com/dradi…
nicolachr Nov 29, 2024
bb0b98c
Fix merge
nicolachr Nov 29, 2024
d6e459b
eliminate old sticky top
MattBudz Nov 29, 2024
fbe9af9
Remove card name
nicolachr Nov 29, 2024
7078cae
Merge branch 'hera/add-main-layout' into hera/add-node-tree
MattBudz Nov 29, 2024
a86ac8d
Merge branch 'hera/add-node-tree' into hera/add-secondary-sidebar
MattBudz Nov 29, 2024
7d94afa
ensure the secondary sidebar saves its own state
MattBudz Nov 29, 2024
eeb1925
fix navbars creating tall views due to overflow
MattBudz Nov 29, 2024
e512f5c
fix toggle spacing
MattBudz Dec 4, 2024
4d70bc7
Collapse navbars together
nicolachr Dec 5, 2024
7287d76
Minor design adjustments
nicolachr Dec 5, 2024
0435d0c
re-add missing css
MattBudz Dec 5, 2024
2a99a9e
move attachments box scss to the correct file
MattBudz Dec 5, 2024
9d8360f
fix button alignment issues
MattBudz Dec 5, 2024
a7df69d
fix active state not being differentiated
MattBudz Dec 5, 2024
3a6e1c4
update placeholder styles
MattBudz Dec 5, 2024
7186d47
update empty state
MattBudz Dec 5, 2024
c13cf3c
consistency
MattBudz Dec 5, 2024
068278e
Alpha
nicolachr Dec 5, 2024
7933000
Allow more space in instance navbar
nicolachr Dec 5, 2024
d50bd14
Merge branch 'hera/add-main-layout' into hera/add-navbar
nicolachr Dec 5, 2024
5e7ecc1
Use Bootstrap's sticky-top class
nicolachr Dec 5, 2024
f240b99
Consistency: font-sizes
nicolachr Dec 5, 2024
e99ab08
Consistency: fix font-size changes
nicolachr Dec 5, 2024
6c92b7a
consistency
MattBudz Dec 5, 2024
028f100
reduce sidebar width
MattBudz Dec 5, 2024
ad57dc9
Merge branch 'hera/add-node-tree' into hera/add-secondary-sidebar
MattBudz Dec 5, 2024
68e0df5
indentation
MattBudz Dec 5, 2024
f16433f
Ensure nav links readability
nicolachr Dec 6, 2024
0a52f97
Use correct colour for nav-links - reduce icon size
nicolachr Dec 6, 2024
0ca6478
Ensure correct code gets rendered for user menu
nicolachr Dec 6, 2024
24e2964
update toggler size and position to improve UX
MattBudz Dec 6, 2024
fd7d626
Merge branch 'hera/add-node-tree' into hera/add-secondary-sidebar
MattBudz Dec 6, 2024
dd11d40
fix merge + update right toggler to match left
MattBudz Dec 6, 2024
88a4c27
Remove unused HTML from user menu
nicolachr Dec 6, 2024
99a7e85
Add link to Tags
nicolachr Dec 6, 2024
b4cfa37
Consistency: capitalize nav-links/dropdown-items
nicolachr Dec 6, 2024
8e8ef6c
Remove unnecessary HTML from configuration dropdown
nicolachr Dec 6, 2024
be9f025
improve responsiveness of the sidebars
MattBudz Dec 6, 2024
0969d99
fix tab alignment
MattBudz Dec 6, 2024
c3f18ef
update icon color to match brand
MattBudz Dec 6, 2024
3b89048
improve contrast throughout
MattBudz Dec 6, 2024
404eb81
add missing button styles
MattBudz Dec 6, 2024
18ccfd5
remove extra carets
MattBudz Dec 6, 2024
d98b25f
fix button text colors
MattBudz Dec 6, 2024
15fe66a
add missing dropdown styles
MattBudz Dec 6, 2024
5c09bd9
fix dropdowns and links in headers being bold
MattBudz Dec 6, 2024
b6c61f6
Make buttons less prominent
nicolachr Dec 6, 2024
83e3ed0
add missing console styles
MattBudz Dec 6, 2024
20b4ee2
fix `<code>` contrast
MattBudz Dec 6, 2024
bf5e626
Merge branch 'hera/add-main-layout' into hera/add-node-tree
MattBudz Dec 6, 2024
5467a38
Improve contrast of edit/copy buttons
nicolachr Dec 6, 2024
3b7b2d9
Merge branch 'hera/add-node-tree' into hera/add-secondary-sidebar
MattBudz Dec 6, 2024
a1a3770
Merge branch 'hera/add-secondary-sidebar' of https://github.com/dradi…
MattBudz Dec 6, 2024
74c0b81
fix sidebar action conflicts with merge
MattBudz Dec 6, 2024
1d4aa12
remove unneed classes
MattBudz Dec 6, 2024
09cdaaf
decrease btn prominence + increase hover contrast
MattBudz Dec 6, 2024
90205ac
Ensure smooth collapsing/expanding of sidebar content
nicolachr Dec 9, 2024
28c86b8
Ensure equal spacing between components
nicolachr Dec 9, 2024
da16d4f
Remove app version from node tree
nicolachr Dec 9, 2024
a29445d
Merge branch 'hera/add-node-tree' into hera/add-secondary-sidebar
nicolachr Dec 9, 2024
aea167a
fix state menu font size
MattBudz Dec 9, 2024
d3a1bb4
fix disabled button state being overridden
MattBudz Dec 9, 2024
b4ace7e
Ensure borders are rendered correctly in qa issue collection
nicolachr Dec 9, 2024
f580617
remove old class
MattBudz Dec 9, 2024
9767135
add footer
MattBudz Dec 9, 2024
7b6f3e4
Merge branch 'hera/add-main-layout' into hera/add-navbar
MattBudz Dec 9, 2024
8db92e0
Merge branch 'hera/add-main-layout' into hera/add-node-tree
MattBudz Dec 9, 2024
6a9d266
remove old css
MattBudz Dec 9, 2024
45d654f
Merge branch 'hera/add-node-tree' into hera/add-secondary-sidebar
MattBudz Dec 9, 2024
62ec5b1
remove unneeded divider
MattBudz Dec 9, 2024
540254f
fix notification dot location
MattBudz Dec 9, 2024
ad2a79f
fix sidebar togglers not showing up in safari
MattBudz Dec 9, 2024
bfc49dd
prevent horizontal scrolling
MattBudz Dec 9, 2024
416913d
fix sidebar responsiveness
MattBudz Dec 9, 2024
7fb1b60
consistency
MattBudz Dec 9, 2024
003ea01
fix widths
MattBudz Dec 9, 2024
196ee3a
remove unneeded scrolling
MattBudz Dec 9, 2024
1ced6c8
re-add accidentally removed class
MattBudz Dec 9, 2024
3ca191f
Merge branch 'hera/add-main-layout' into hera/add-node-tree
MattBudz Dec 9, 2024
64462d9
Merge branch 'hera/add-node-tree' into hera/add-secondary-sidebar
MattBudz Dec 9, 2024
3a0804e
Ensure project name is displayed in breadcrumb
nicolachr Dec 10, 2024
1ab295b
Ensure responsive behavior of nav-tabs
nicolachr Dec 10, 2024
7c4946d
Merge branch 'hera/add-main-layout' into hera/add-navbar
nicolachr Dec 10, 2024
05bb730
Ensure we're not using acid green as $light variable
nicolachr Dec 10, 2024
56833fb
Ensure the correct vertical space is reserved for the navbar
nicolachr Dec 10, 2024
747a816
Adjust border color for instance navbar dropdowns
nicolachr Dec 10, 2024
8871ae3
move QA widget to sidebar
MattBudz Dec 10, 2024
eacbc85
Ensure dropdown CSS doesn't break navbar dropdowns
nicolachr Dec 10, 2024
5b6107b
Merge branch 'hera/add-main-layout' into hera/add-navbar
nicolachr Dec 10, 2024
c504f3d
Ensure footer is rendered inside content-grid
nicolachr Dec 10, 2024
f8e9dbf
Merge branch 'hera/add-main-layout' into hera/add-navbar
nicolachr Dec 10, 2024
645febd
Merge branch 'hera/add-main-layout' into hera/add-node-tree
nicolachr Dec 10, 2024
a90019d
Merge branch 'hera/add-node-tree' into hera/add-secondary-sidebar
nicolachr Dec 10, 2024
0160680
Ensure consistent behavior in chevrons
nicolachr Dec 10, 2024
b36c32e
Remove drop-shadow from dropdown-menus in mobile
nicolachr Dec 10, 2024
72d62ba
Fix gravatar's padding
nicolachr Dec 10, 2024
e2529a8
Reduce padding for mobile devices
nicolachr Dec 10, 2024
535e669
Consistency: add border to instance-nav
nicolachr Dec 10, 2024
13985bb
Fix hover contrast and padding in complementary nav icons
nicolachr Dec 10, 2024
4380f59
Update notification colors to match navbar
nicolachr Dec 10, 2024
f764cb4
Ensure notifications expand in mobile
nicolachr Dec 10, 2024
a9a652b
move shared navbar partials to `shared/`
MattBudz Dec 10, 2024
a79194f
consistency
MattBudz Dec 10, 2024
4c4f557
fix dropdown menu position
MattBudz Dec 10, 2024
0e3837b
make search full width in mobile
MattBudz Dec 10, 2024
3276861
fix broken user name cases
MattBudz Dec 10, 2024
cd8fbd8
update mobile menu styles
MattBudz Dec 10, 2024
ce90157
add tools menu and improve pro partity
MattBudz Dec 10, 2024
c733025
remove extra spacing in mobile nav
MattBudz Dec 10, 2024
ba9718d
remove redundant prefix
MattBudz Dec 10, 2024
784bc40
parity improvement
MattBudz Dec 10, 2024
31ffe1a
move navbar and instance-nav styles to `shared/`
MattBudz Dec 10, 2024
9e7fc22
move help partial to `shared/`
MattBudz Dec 10, 2024
f3f7927
remove blank lines
MattBudz Dec 10, 2024
4e65b20
fix another double border
MattBudz Dec 10, 2024
60552cb
removed unneeded classes
MattBudz Dec 10, 2024
a3b8dc7
Update app/views/shared/navigation/_complementary_nav.html.erb
nicolachr Dec 11, 2024
6a8632f
Update app/views/shared/navigation/_complementary_nav.html.erb
nicolachr Dec 11, 2024
154942c
Consistency: add top border to footer
nicolachr Dec 11, 2024
2a2619d
Merge branch 'hera/add-main-layout' into hera/add-navbar
nicolachr Dec 11, 2024
5713c3b
Merge branch 'hera/add-main-layout' into hera/add-node-tree
nicolachr Dec 11, 2024
337098d
Merge branch 'hera/add-node-tree' into hera/add-secondary-sidebar
nicolachr Dec 11, 2024
4dc6d23
Consistency: use term Integrations and not Tools
nicolachr Dec 11, 2024
519b736
removed old file
MattBudz Dec 11, 2024
42fe70c
improve mintcreek compatibility
MattBudz Dec 11, 2024
f1fee84
remove redundant declaration
MattBudz Dec 11, 2024
c6145d8
more mintcreek compatibility tweaks
MattBudz Dec 11, 2024
a65a98a
consistent padding
MattBudz Dec 11, 2024
8e39843
fix padding for nav-links
MattBudz Dec 11, 2024
3a60bc7
consistent use of borders
MattBudz Dec 11, 2024
006a4bf
improve nav-link responsiveness
MattBudz Dec 11, 2024
0c2d4ec
prevent abrupt end to mobile menu
MattBudz Dec 11, 2024
7bf70c5
Merge pull request #1320 from dradis/hera/add-navbar
MattBudz Dec 11, 2024
64a8b17
Merge pull request #1322 from dradis/hera/add-secondary-sidebar
MattBudz Dec 11, 2024
8c73d8c
Merge branch 'hera/add-main-layout' into hera/add-node-tree
MattBudz Dec 11, 2024
6a1061c
Merge pull request #1321 from dradis/hera/add-node-tree
MattBudz Dec 11, 2024
dacf6ce
Merge branch 'develop' into hera/add-main-layout
MattBudz Dec 11, 2024
0008507
Fix positioning of elements in notification
nicolachr Dec 11, 2024
4354285
Include js to link notifications to view in mobile
nicolachr Dec 11, 2024
4743516
Rename complementary_nav to utility_nav
nicolachr Dec 11, 2024
1c88abe
Display search form on the very top in small viewports
nicolachr Dec 11, 2024
c141e73
Remove unused id
nicolachr Dec 11, 2024
21fb385
Remove unused ids
nicolachr Dec 11, 2024
bb066db
add missing breadcrumbs
MattBudz Dec 11, 2024
51ab464
adjust breadcrumb padding to match container
MattBudz Dec 11, 2024
f74e369
split utility menus
MattBudz Dec 11, 2024
3483831
move trash to utility nav for consistency
MattBudz Dec 11, 2024
cb4fccc
space saving
MattBudz Dec 11, 2024
c7bab0a
fix search in mobile not showing up
MattBudz Dec 11, 2024
a142cdf
remove double require
MattBudz Dec 11, 2024
796f869
fix footers not at bottom of short views
MattBudz Dec 11, 2024
2d12a82
prevent notification dropdown in mobile nav
MattBudz Dec 11, 2024
0a72c77
remove caret from notifications
MattBudz Dec 11, 2024
16cacb7
add CHANGELOG entry
MattBudz Dec 11, 2024
ea8fb38
use modern syntax
MattBudz Dec 11, 2024
9618161
consistent font size
MattBudz Dec 11, 2024
bd1066e
typo
MattBudz Dec 11, 2024
72c0942
remove extra div breaking the search view
MattBudz Dec 11, 2024
8f97077
fix search js scoping
MattBudz Dec 11, 2024
2eac45a
Fix: /upload layout
nicolachr Dec 12, 2024
329ee4b
Fix: header height preventing sidebars from collapsing
nicolachr Dec 12, 2024
b86c224
Fix: depricated apple-mobile-web [...] warning
nicolachr Dec 12, 2024
8888b8b
Fix: accessibility /notifications
nicolachr Dec 12, 2024
6f6ad9d
Fix: accessibility /navigation
nicolachr Dec 12, 2024
d66e450
update changelog entry
MattBudz Dec 12, 2024
4e8f687
remove unused ID
MattBudz Dec 12, 2024
7f11c93
consistency
MattBudz Dec 12, 2024
5baa227
fix typo
MattBudz Dec 12, 2024
fec439c
fix gap between sidebars and navbar
MattBudz Dec 12, 2024
7a0c6b8
Fix: reduce height of recent activity widget
nicolachr Dec 12, 2024
acda5ad
Merge branch 'develop' into hera/add-main-layout
MattBudz Dec 12, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .rubocop_todo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,7 @@ Style/EmptyLineBetweenDefs:
- 'app/controllers/methodologies_controller.rb'
- 'app/controllers/nodes_controller.rb'
- 'app/controllers/sessions_controller.rb'
- 'app/helpers/tylium_helper.rb'
- 'app/helpers/hera_helper.rb'
- 'app/models/concerns/node_properties.rb'
- 'app/models/configuration.rb'
- 'app/models/methodology.rb'
Expand Down Expand Up @@ -517,7 +517,7 @@ Style/EmptyLinesAroundClassBody:
Style/EmptyLinesAroundMethodBody:
Exclude:
- 'app/controllers/projects_controller.rb'
- 'app/helpers/tylium_helper.rb'
- 'app/helpers/hera_helper.rb'
- 'app/models/concerns/file_backed_model.rb'
- 'app/models/concerns/has_fields.rb'
- 'app/models/methodology.rb'
Expand All @@ -531,7 +531,7 @@ Style/EmptyLinesAroundModuleBody:
- 'app/controllers/concerns/activity_tracking.rb'
- 'app/controllers/concerns/authentication.rb'
- 'app/helpers/revisions_helper.rb'
- 'app/helpers/tylium_helper.rb'
- 'app/helpers/hera_helper.rb'
- 'app/models/concerns/file_backed_model.rb'
- 'app/models/concerns/has_fields.rb'
- 'app/models/concerns/revision_tracking.rb'
Expand Down Expand Up @@ -628,7 +628,7 @@ Style/IfUnlessModifier:
Exclude:
- 'Gemfile'
- 'app/controllers/attachments_controller.rb'
- 'app/helpers/tylium_helper.rb'
- 'app/helpers/hera_helper.rb'
- 'app/models/category.rb'
- 'app/models/concerns/file_backed_model.rb'
- 'app/models/methodology.rb'
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
[v#.#.#] ([month] [YYYY])
- Hera: A new layout with incremental improvements. In this iteration we redesigned the navigation and increased workspace real estate.
MattBudz marked this conversation as resolved.
Show resolved Hide resolved
- Tags: Add custom ordering
- Welcome Kit:
- Add HTML report template
Expand Down
4 changes: 2 additions & 2 deletions app/assets/config/manifest.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
//= link application.css
//= link setup/setup.css
//= link tylium.css
//= link hera.css

//= link legacy.application.js
//= link tylium.js
//= link hera.js

//= link_tree ../../javascript .js
//= link_tree ../../../vendor/javascript .js
Expand Down
Binary file added app/assets/fonts/proximanova-light.woff2
Binary file not shown.
Binary file added app/assets/fonts/proximanova-regular.woff2
Binary file not shown.
50 changes: 23 additions & 27 deletions app/assets/javascripts/tylium.js → app/assets/javascripts/hera.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
//= require jquery-ui.min
//= require rails-ujs
//= require turbolinks
// require activestorage
//= require jquery.form
//= require jquery.textchange.min
//= require jquery.textile
Expand Down Expand Up @@ -38,34 +37,31 @@
//= require shared/datatable/tag
//= require shared/datatable/validate

//= require tylium/plugins/jquery.breadcrumbs
//= require tylium/plugins/jquery.treemodal
//= require tylium/plugins/jquery.treenav
//= require hera/vendor/jquery.breadcrumbs
//= require hera/vendor/jquery.treemodal
//= require hera/vendor/jquery.treenav

//= require tylium/behaviors
//= require hera/behaviors
//= require shared/behaviors

//= require tylium/engines
//= require tylium/keyboard_shortcuts
//= require hera/engines

//= require tylium/modules/configurations
//= require tylium/modules/export
//= require tylium/modules/fileupload
//= require tylium/modules/issues
//= require tylium/modules/liquid_async
//= require tylium/modules/nodes
//= require tylium/modules/search
//= require tylium/modules/sidebar
//= require tylium/modules/activities/poller
// require tylium/modules/tour
//= require tylium/modules/uploads
//= require hera/modules/activities_poller
//= require hera/modules/configurations
//= require hera/modules/export
//= require hera/modules/fileupload
//= require hera/modules/issues
//= require hera/modules/liquid_async
//= require hera/modules/nodes
//= require hera/modules/search
//= require hera/modules/sidebar
//= require hera/modules/try_pro
//= require hera/modules/uploads

//= require tylium/pages/activities
//= require tylium/pages/boards
//= require tylium/pages/issues
//= require tylium/pages/nodes/new_form
//= require tylium/pages/projects/boards_summary
//= require tylium/pages/projects/issues_chart
//= require tylium/pages/projects/summary
//= require tylium/pages/qa
//= require tylium/pages/upload
//= require hera/pages/activities
//= require hera/pages/boards
//= require hera/pages/issues
//= require hera/pages/nodes/new_form
//= require hera/pages/projects
//= require hera/pages/qa
//= require hera/pages/upload
60 changes: 60 additions & 0 deletions app/assets/javascripts/hera/behaviors.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
document.addEventListener('turbolinks:load', function () {
// Activate jQuery.breadCrumbs
$('.breadcrumb').breadcrumbs({
tree: $('.main-sidebar .tree-navigation'),
});

// Activate jQuery.treeNav
$('.tree-navigation').treeNav();

// Activate jQuery.treeModal
$('.modal-node-selection-form').treeModal();

// Focus first input on modal window display.
$('.modal').on('shown.bs.modal', function () {
$(this).find('input:text:visible:first').focus();
});

// If project id is changed in project path
if (!/^\/projects\/1(\/|$)/.test(window.location.pathname)) {
$('[data-behavior~=project-teaser]').removeClass('d-none');
}

if ($('#activities-poller').length) {
if (!ActivitiesPoller.initialized) {
ActivitiesPoller.init($('#activities-poller'));
ActivitiesPoller.poll();
}
}

// Disable form buttons after submitting them.
$('form').submit(function (ev) {
if (
!$('input[type=submit]', this).is('[data-behavior~=skip-auto-disable]')
) {
$('input[type=submit]', this)
.attr('disabled', 'disabled')
.val('Processing...');
}
});

// Toggle sidebar menu
$('[data-behavior~=sidebar]').each(function () {
new Sidebar($(this));
});

// Disable turbolinks for on-page anchor links (prevents page from jumping to top and allows smooth-scrolling)
if ($('a[href^="#"]').length) {
$('a[href^="#"]').each(function () {
if (!$(this).data('turbolinks')) {
$(this).attr('data-turbolinks', 'false');
}
});
}

// Smooth Scrolling - scroll to element on page load if hash present in current browser url
if (window.location.hash) {
const target = window.location.hash;
$(target)[0].scrollIntoView({ behavior: 'smooth' });
}
});
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Dradis::Plugins::with_feature(:addon).sort_by(&:plugin_description).each do |plu
begin
plugin_path = ActiveSupport::Inflector.underscore(ActiveSupport::Inflector.deconstantize(plugin.name))
%>
<%= require_asset "#{plugin_path}/manifests/tylium.js" %>
<%= require_asset "#{plugin_path}/manifests/hera.js" %>
<% sleep 1 %>
<%
rescue Sprockets::FileNotFound;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ class @ActivitiesPoller
$board.find('.board-tile-details-name').html(boardName)
else if @_currentlyViewingBoard(boardId)
document.title = boardName
$('#view-content h3').html(boardName)
$('[data-behavior~=view-content] h3').html(boardName)
$('ol.breadcrumb li:nth-child(2)').html(boardName)

if @controller == 'nodes' && @_currentlyViewingBoard(boardId)
Expand Down
4 changes: 4 additions & 0 deletions app/assets/javascripts/hera/modules/issues.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
//= require hera/modules/issues/evidence
//= require hera/modules/issues/importer
//= require hera/modules/issues/merge
//= require hera/modules/issues/tag-input
51 changes: 51 additions & 0 deletions app/assets/javascripts/hera/modules/search.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
document.addEventListener('turbolinks:load', function () {
$('[data-behavior~=form-search]').hover(function () {
$(this).find('[data-behavior~=search-query]').focus();
});

$('[data-behavior~=search-button]').on('click', function (e) {
e.preventDefault();
submitSearch($(this).parents('form'));
});

$('[data-behavior~=search-query]').on('keypress', function (e) {
if (e.which === 13) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we make the magic number a variable like we did with mobileBreakpoint in sidebar.js

submitSearch($(this).parents('form'));
}
});

if ($('body.search.index').length) {
const highlighter = new SearchWordHighlight();
const query = $('.form-search #q').val();
$('#tbl-search .search-matches').each(function () {
highlighter.highlight($(this), query);
});
}
});

function submitSearch($form) {
if ($form.find('[data-behavior~=search-query]').val() !== '') {
$form.submit();
$form.find('[data-behavior~=search-query]').val('Searching...');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe this is breaking the search functionality

return false;
} else {
$form
.find('[data-behavior~=search-query]')
.effect('shake', { direction: 'left', times: 2, distance: 5 }, 'fast')
.focus();
}
}

class SearchWordHighlight {
highlight(element, term) {
let src_str = element.html();
term = term.replace(/(\s+)/, '(<[^>]+>)*$1(<[^>]+>)*');
const pattern = new RegExp('(' + term + ')', 'gi');
src_str = src_str.replace(pattern, '<mark>$1</mark>');
src_str = src_str.replace(
/(<mark>[^<>]*)((<[^>]+>)+)([^<>]*<\/mark>)/,
'$1</mark>$2<mark>$4'
);
element.html(src_str);
}
}
85 changes: 85 additions & 0 deletions app/assets/javascripts/hera/modules/sidebar.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
(function ($, window) {
class Sidebar {
constructor($sidebar) {
this.$sidebar = $sidebar;
this.storageKey = $sidebar.data('storage-key');
this.$toggleLink = $sidebar.find($('[data-behavior~=sidebar-toggle]'));
this.mobileBreakpoint = 992;

this.init();
}

init() {
this.toggle(this.isSidebarOpen());

const that = this;

this.$toggleLink.on('click', function () {
that.toggle(!that.isSidebarOpen());
});

$(window).on('resize', function () {
if ($(window).width() < that.mobileBreakpoint) {
that.close();
}
that.setViewContentMaxWidth();
});
}

changeState(key, state) {
localStorage.setItem(key, state);
Turbolinks.clearCache();
}

close() {
this.$sidebar
.removeClass('sidebar-expanded')
.addClass('sidebar-collapsed')
.attr('data-behavior', 'sidebar');

this.setViewContentMaxWidth();
this.changeState(this.storageKey, false);
}

isSidebarOpen() {
if (JSON.parse(localStorage.getItem(this.storageKey)) === null) {
return true;
} else {
return JSON.parse(localStorage.getItem(this.storageKey));
}
}

open() {
this.$sidebar
.removeClass('sidebar-collapsed')
.addClass('sidebar-expanded')
.attr('data-behavior', 'sidebar sidebar-expanded');

this.setViewContentMaxWidth();
this.changeState(this.storageKey, true);
}

setViewContentMaxWidth() {
const collapsedSidebarsWidth = 10;
const viewportWidth = $(window).width() - collapsedSidebarsWidth;
let sidebarsWidth = 0;

$('[data-behavior~=sidebar]').each(function () {
sidebarsWidth += $(this).width();
});

const limit =
$(window).width() < this.mobileBreakpoint
? viewportWidth
: viewportWidth - sidebarsWidth;

$('[data-behavior~=view-content]').css('max-width', limit);
}

toggle(openSidebar) {
openSidebar ? this.open() : this.close();
}
}

window.Sidebar = Sidebar;
})(jQuery, window);
Loading
Loading