* Fix typo in alt text
* Convert unsemantic div into nav
* Remove commented CSS
* Refactor connect config menu to be more usable
* Remove unused prop
* Return focus to button when config menu collapses
* Fix aria-label
* Add aria-expanded and fix aria-label text
Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
* Add transparent background-color to config menu button
Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
* Try to fix preview bug
* Now an error is thrown client side if HTTP status isn't 200
* Now the JSON response is thrown instead of the response when preview fails.
* Linter test
Co-authored-by: Nick Taylor <nick@dev.to>
Co-authored-by: Fernando Valverde <fdov88@gmail.com>
Co-authored-by: Nick Taylor <nick@iamdeveloper.com>
Co-authored-by: ludwiczakpawel <ludwiczakpawel@gmail.com>
Co-authored-by: Nick Taylor <nick@dev.to>
Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
* Added svg image picker to navigation link form
* Added svg image picker to navigation link form
* removed unnecessary attribute at _form.html.erb
* Added targets into SvgIconUploadController
* Fixed accept file type in .erb and stimulus controller
* Fixed UI form elements
The phrasing of this may reflect the code, but is a little confusing. A
user might not understand what a "joining request" is, so we should
probably just keep things simple for the time being.
* feat: add an error column to the data update script
* feat: save the error to the error field
* feat: save the error when the script fails
* feat: show the script error on the data update script page
* chore: pass the error to mark_as_failed instead of having its own function
* refactor: use presence
* test: ensure that we test an error case of a data update script
* chore: rename errorneous to failing
* test: update some specs, working on the others
* chore: update tests now that there are two files
* chore: change error from a string to a text to allow for more char
* feat: order the data update scripts by the latest script that ran
* feat: when the script has succeeded reset error to nil
* feat: create a model function that will allow the script to be force run
* chore: oops remove the functions form the worker to the model so it can be re-used
* feat: create an endpoint that will call the model method force run when we hit the api by clicking the button
* feat: ensure that the we add an ajax call that calls the controller endpoint
* chore: remove newline
* refactor: change to a more Restful route
* refactor: use Stimulus
* fix: move the code from the model back into the worker so that we can reuse it in the controller
* feat:call the worker in the force_run action and create a show route
* feat: very first draft of using a polling mechanism on the show method after we kickoff the sidekiq job (still need to error handle)
* chore: some syntax changes and unused variables
* fix: call the method correctly with the paramters
* feat: do some error handling
* feat: error handing on the frontend
* chore: use e instead of err
* refactor: just pass the id instead of the whole script
* chore: remove the button
* fix: allow the id to be passed
* feat: handle errors better
* feat: limit the filename column width
* refactor: use a common function to set the banner error
* test: add a test fro rerun button
* test: v1 of the data update script request
* test: write some specs for the js controller
* Update app/controllers/admin/data_update_scripts_controller.rb
Co-authored-by: Michael Kohl <me@citizen428.net>
* tests: update the data worker spec
* chore: clean up the js controller and its tests
* chore: remove whitespaces
* chore: swap the functions based on the controller
* chore: updates to the UI
* chore: remove the standard error catch
* chore: update the alert and error messages
* chore: remove test for error handling for sidekiq run
Co-authored-by: Michael Kohl <me@citizen428.net>
* Improve keyboard a11y of header menu dropdown
This commit also includes some cleanup of unnecessary functions that seemed to degrade performance.
Closes https://github.com/forem/forem/issues/1154
* Add temporary focus style on navigation-button
* Put menu items in a list
* Adjust menu button based on VoiceOver testing
* Refactor menu logic to be reusable/work on touch
* Preserve admin link visibility
* Focus on first item on menu open
* Clean up some HTML and CSS
* Apply suggestions from code review
Co-authored-by: ludwiczakpawel <ludwiczakpawel@gmail.com>
* Ensure menu hides on click outside
* Rename toggle function and adjust formatting
* Update nav button focus style
* Clean up padding on header avatar focus style
* Make button show focus state for keyboard only
Using .focus-visible:focus targets keyboard focus and eliminates a flash of the blue border on click before focus is moved to the child item (which also has no focus style on mouse click)
* Update app/views/layouts/_top_bar.html.erb
Co-authored-by: ludwiczakpawel <ludwiczakpawel@gmail.com>
* Add some defensive programming
* Removed initializeTouchDevice from base.js.erb
* navigation-butt ID is now member-menu-button
* Moved all the logic from initializeTouchDevice.js into a pack file/utilities.
* committing re-ordered schema after setup
* add tests for initializeTouchDevice
* remove some unneeded html setup
* make sure menu doesn't close if user tabs back from sign out
* Revert "committing re-ordered schema after setup"
This reverts commit a41a1c861cca3b97d8a7b8a99268b8afaae9f028.
* optimized code
* small tweaks, only show outline when focused
Co-authored-by: ludwiczakpawel <ludwiczakpawel@gmail.com>
Co-authored-by: rhymes <rhymes@hey.com>
Co-authored-by: Nick Taylor <nick@dev.to>
Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
* Fixing link focus
1. Removing display content from link
2. Removing extra margin at the top of link
3. Adding before link
* Extending crayon-fields and removing margin-top
* Frontend Ready for Connect Report Abuse
* add feedback api
* js defination fix
* Added Hooks to the Component
* add json response in feedback
* Block popup added
* fix render issue
* Made changes in internal view
* change error message
* Added few design changes =
* add test cases
* Update app/javascript/chat/actions/requestActions.js
Co-authored-by: Nick Taylor <nick@iamdeveloper.com>
* add PR suggestions
* add backend test cases
* report abuse form close
* Update app/javascript/chat/actions/requestActions.js
Co-authored-by: Nick Taylor <nick@iamdeveloper.com>
* Update app/javascript/chat/ReportAbuse/index.jsx
Co-authored-by: Nick Taylor <nick@iamdeveloper.com>
* add test cases
* Update app/javascript/chat/ReportAbuse/index.jsx
Co-authored-by: Nick Taylor <nick@iamdeveloper.com>
* Update app/javascript/chat/ReportAbuse/index.jsx
Co-authored-by: Marcy Sutton <holla@marcysutton.com>
* Update app/javascript/chat/ReportAbuse/index.jsx
Co-authored-by: Marcy Sutton <holla@marcysutton.com>
* group the fieldset
* fix report abuse api
* fix test case
* fix request test case
* fix typo
* cleaned up markup in report abuse component.
* Fixed spacing between abuse options.
* Fixed wording in report abuse confirmation.
* Removed unnecessary data-testid and aria-label attributes.
* Added some top margin to the report abuse form.
* Update app/javascript/chat/message.jsx
Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
* Added a legend to the the fieldset.
* Update app/javascript/chat/actions/requestActions.js
Co-authored-by: Michael Kohl <citizen428@dev.to>
Co-authored-by: Sarthak <7lovesharma7@gmail.com>
Co-authored-by: Narender Singh <narender2031@gmail.com>
Co-authored-by: Marcy Sutton <holla@marcysutton.com>
Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
Co-authored-by: Michael Kohl <citizen428@dev.to>
* Display message from the back end when leaving a channel
Co-authored-by: jacobherrington <jacobherringtondeveloper@gmail.com>
Co-authored-by: Alberto Pérez de Rada Fiol <apdrf.94@gmail.com>
Co-authored-by: Michael Kohl <citizen428@dev.to>
* allow keyboard access to dropdown stories
* add accessibility notes to dropdown stories
* manage focus in html example
* Update reference to aria attributes in notes
Co-authored-by: Vaidehi Joshi <vaidehi.sj@gmail.com>
* add focus style to link for keyboard users
Co-authored-by: Vaidehi Joshi <vaidehi.sj@gmail.com>
* Start hooking things up
* further generalize adminModal, hook up relevant code
* Complete implementation
* remove comments
* Address QA suggestions
* Address QA suggestions
* Use object parameter for adminModal
* starting the admin cypress tests
* Code review suggestions
* remove incomplete test
* rename data attributes to make more sense
* complete the work
* use destructuring
* edit warning modal text
* Replace follows#update with follows#bulk_update
* Allow follows#bulk_update to receive multiple follows and remove follows#update
* Add FollowPolicy#bulk_update? and remove update?
* Combine save button into one in following_tag.html
* Rename follows_update_spec to follows_bulk_update_spec and update
* Update buildTagsHTML to conform to the view
* Allow scrolls down dashboard test to update multiple tag values
* Includes follower and followable in follows#bulk_update
* Mark and pass changed field.
* fix typo in html
* Update follows in transaction
* Extract js script to another file and update view
* Rename disableUnchangedButton.js to dashboardTagsDisableUnchangedButtons.js
* Removes collective_noun and collective_noun_disabled from app
* Config Generalization: replaces community_qualified_name with community_name
- Generalizes SiteConfig after the removal of collective_noun field
- Updates copy where necessary to be readable with community_name
- Makes the community_name SiteConfig description more explicit
- Adds flexibility for Admins by removing appended "community"
* Adds a data_update script to remove collective_noun and collective_noun_disabled
* Removes appended community from stories_controller.rb
* Removes unnecessary quotation marks around SiteConfig.community_name.to_s
* Makes SiteConfig community_name description more explicit
* Removes topic from #email_from and replaces arg with _
* Removes argument from #email_from (facepalm)
* Reverts changes to application_mailer and notify_mailer_spec
* Removes default "Community" topic from application_mailer and makes topic optional
* Refactors #prepopulate_new_form to resolve Code Climate failures
* Refactors #email_from even further by use of a ternary operator per review suggestion
* Simplifies the data_update script used to remove collective_noun per review request
* Adds a data_update script to append community to community_name
* Updates data_update script to correctly append Community to community_name
* Removes RemoveCollectiveNounFromConfig and updates other script
* Removes superfluous false from data_update script
* Updates data_update script to be more idiomatic
* First working version to integrate native bridge image upload
* ImageUploader base64 experiment
* Adds message handling
* Adds support for cover image
* Revert pre-commit hook changes
* Revert pre-commit hook changes
* Better native image upload logic + mock Runtime class in tests
* Dont render hidden fields unless necessary
* Better test coverage & inline comments for better context/documentation
* Added an a11y test for when native iOS image upload is available.
* Added more test
Co-authored-by: Nick Taylor <nick@dev.to>
* feat: v1 of the profile form
* feat: fix inputs and create a handleChange event
* feat: update the submit values to represent values from the form
* feat: ensure that errors and success is handled on send
* refactor: remove unused code
* feat: replace the old profile form with a new one
* fix: use the renames file
* refactor: safety net for groups
* chore: fix code climate issue
* tests: amend + add tests
* test: fix broken spec
* feat: update the setup for the test
* tests: refactored them to move the fake response into the before all
* feat: clunky way to quickly cater for color field since it was a quick and easy implementation
* feat: add a field.description to the color field
* refactor: pull some duplicate code into a new function
* chore: cater for a textarea field
* overflow issue
* refactor: use FormField instead of manual divs
* Update spec/requests/users_onboarding_spec.rb
Co-authored-by: Vaidehi Joshi <vaidehi.sj@gmail.com>
* Update spec/requests/users_onboarding_spec.rb
Co-authored-by: Vaidehi Joshi <vaidehi.sj@gmail.com>
* refactor: move out of method and into a constant
* refactor: user_onboarding_update to be more readable
* refactor: use current.save instead of declaring a new variable
* refactor: remove explicit check for bookean
* refactor: use request from '@utilities/http' instead :)
* refactor: no need for if with destructured groups
* refactor: move color field to its own component
* chore: remove colorfield now thats its a component
* fix: forgot about field
* feat: a text area component
* chore: remove textField function in favor of component
* refactor: checkbox refactor
* refactor: add a switch statement
* chore: move into a more organized folder
* fix: move the handler to props and off from field
* fix: add a conditional so we dont hit an error undefined method `success?' for nil:NilClass
* refactor: change from component to function
* feat: add a key attribute
* refactor: add role for readers
* refactor: remove unnecessary guard clauses
* refactor: use function instead of an arrow
* chore: document components
* test
* padding
* fixes
* test: fix the tests by using more general matchers
Co-authored-by: Paweł Ludwiczak <ludwiczakpawel@gmail.com>
Co-authored-by: Vaidehi Joshi <vaidehi.sj@gmail.com>