diff --git a/.editorconfig b/.editorconfig index 823cdad3f..cacefaf9b 100644 --- a/.editorconfig +++ b/.editorconfig @@ -5,12 +5,12 @@ root = True [*] end_of_line = lf insert_final_newline = true +tab_width = 8 # For all code, config and documentation -[*.{js,py,jinja2,j2,html,xml,css,sass,scss,json,yml,md,rst}] +[*.{js,py,jinja2,j2,html,xml,css,sass,scss,json,yml,yaml,md,rst}] charset = utf-8 indent_style = space -tab_width = 8 max_line_length = 88 # Python code diff --git a/.prettierrc.json b/.prettierrc.json index c423a7056..544138be4 100644 --- a/.prettierrc.json +++ b/.prettierrc.json @@ -1,6 +1,3 @@ { - "endOfLine": "lf", - "singleQuote": true, - "trailingComma": "es5", - "printWidth": 88 + "singleQuote": true } diff --git a/funnel/assets/js/account_form.js b/funnel/assets/js/account_form.js index 3eae8eb82..01f6101e1 100644 --- a/funnel/assets/js/account_form.js +++ b/funnel/assets/js/account_form.js @@ -53,7 +53,7 @@ window.Hasgeek.Accountform = ({ .text(remoteData.error_description); } else { const errorTxt = $('
').text( - remoteData.error_description + remoteData.error_description, ); $(errorTxt).insertBefore($(fieldWrapper).find('.mui-form__helptext')); } diff --git a/funnel/assets/js/app.js b/funnel/assets/js/app.js index 1249d8cca..2f26946c2 100644 --- a/funnel/assets/js/app.js +++ b/funnel/assets/js/app.js @@ -21,16 +21,16 @@ const pace = require('pace-js'); $(() => { /* eslint-disable no-console */ console.log( - 'Hello, curious geek. Our source is at https://github.com/hasgeek. Why not contribute a patch?' + 'Hello, curious geek. Our source is at https://github.com/hasgeek. Why not contribute a patch?', ); loadLangTranslations(); window.Hasgeek.Config.errorMsg = { serverError: window.gettext( - 'An internal server error occurred. Our support team has been notified and will investigate' + 'An internal server error occurred. Our support team has been notified and will investigate', ), networkError: window.gettext( - 'Unable to connect. Check connection and refresh the page' + 'Unable to connect. Check connection and refresh the page', ), rateLimitError: window.gettext('This is unusually high activity. Try again later'), error: window.gettext('An error occured when submitting the form'), @@ -58,7 +58,7 @@ $(() => { polyfill.setAttribute('type', 'text/javascript'); polyfill.setAttribute( 'src', - 'https://cdnjs.cloudflare.com/ajax/libs/url-search-params/1.1.0/url-search-params.js' + 'https://cdnjs.cloudflare.com/ajax/libs/url-search-params/1.1.0/url-search-params.js', ); document.head.appendChild(polyfill); } diff --git a/funnel/assets/js/autosave_form.js b/funnel/assets/js/autosave_form.js index e5ff93f14..90ecc51f3 100644 --- a/funnel/assets/js/autosave_form.js +++ b/funnel/assets/js/autosave_form.js @@ -54,7 +54,7 @@ window.Hasgeek.autoSave = ({ autosave, formId, msgElemId }) => { $(window).bind('beforeunload', () => { if (haveDirtyFields()) { return window.gettext( - 'You have unsaved changes on this page. Do you want to leave this page?' + 'You have unsaved changes on this page. Do you want to leave this page?', ); } return true; diff --git a/funnel/assets/js/comments.js b/funnel/assets/js/comments.js index 69f58ad99..6ddf4a947 100644 --- a/funnel/assets/js/comments.js +++ b/funnel/assets/js/comments.js @@ -190,7 +190,7 @@ const Comments = { const editorView = codemirrorHelper( textareaId, copyTextAreaContent, - SAVE_EDITOR_CONTENT_TIMEOUT + SAVE_EDITOR_CONTENT_TIMEOUT, ); editorView.focus(); }); @@ -268,7 +268,7 @@ const Comments = { refreshCommentsTimer() { this.refreshTimer = window.setInterval( this.fetchCommentsList, - REFRESH_INTERVAL + REFRESH_INTERVAL, ); }, getInitials: Utils.getInitials, @@ -320,7 +320,7 @@ const Comments = { { rootMargin: '0px', threshold: 0, - } + }, ); observer.observe(commentSection); } @@ -328,14 +328,14 @@ const Comments = { updated() { if (this.initialLoad && window.location.hash) { ScrollHelper.animateScrollTo( - $(window.location.hash).offset().top - this.headerHeight + $(window.location.hash).offset().top - this.headerHeight, ); this.initialLoad = false; } if (this.scrollTo) { if ($(window).width() < MOBILE_BREAKPOINT) { ScrollHelper.animateScrollTo( - $(this.scrollTo).offset().top - this.headerHeight + $(this.scrollTo).offset().top - this.headerHeight, ); } this.scrollTo = ''; diff --git a/funnel/assets/js/contact.js b/funnel/assets/js/contact.js index bec7f7795..ab99cc192 100644 --- a/funnel/assets/js/contact.js +++ b/funnel/assets/js/contact.js @@ -6,7 +6,7 @@ $(() => { fullname, email, phone, - company + company, ) { const vCard = vCardsJS(); vCard.firstName = fullname; @@ -16,8 +16,8 @@ $(() => { element.setAttribute( 'href', `data:text/x-vcard;charset=utf-8,${encodeURIComponent( - vCard.getFormattedString() - )}` + vCard.getFormattedString(), + )}`, ); element.setAttribute('download', `${vCard.firstName}.vcf`); }; diff --git a/funnel/assets/js/event.js b/funnel/assets/js/event.js index d92f06762..b3a7d3055 100644 --- a/funnel/assets/js/event.js +++ b/funnel/assets/js/event.js @@ -57,7 +57,7 @@ class Queue { then it is removed from checkin queue */ this.updateQueue = function updateQueue( participantsHashMap, - ticketParticipantList + ticketParticipantList, ) { const queue = this; const ticketParticipantIds = queue.readAll(); @@ -73,11 +73,11 @@ class Queue { const index = Utils.findLoopIndex( ticketParticipants, 'puuid_b58', - ticketParticipantId + ticketParticipantId, ); ticketParticipantList.set( `ticket_participants.${index}.submitting`, - true + true, ); } } else if (participantsHashMap[ticketParticipantId].checked_in) { @@ -87,7 +87,7 @@ class Queue { const index = Utils.findLoopIndex( ticketParticipants, 'puuid_b58', - ticketParticipantId + ticketParticipantId, ); ticketParticipantList.set(`ticket_participants.${index}.submitting`, true); } @@ -165,7 +165,7 @@ const ParticipantTable = { list.set('ticket_participants', data.ticket_participants).then(() => { const ticketParticipants = Utils.tohashMap( data.ticket_participants, - 'puuid_b58' + 'puuid_b58', ); list.get('checkinQ').updateQueue(ticketParticipants, list); list.get('cancelcheckinQ').updateQueue(ticketParticipants, list); diff --git a/funnel/assets/js/form.js b/funnel/assets/js/form.js index b4d896ccd..bbfd6837b 100644 --- a/funnel/assets/js/form.js +++ b/funnel/assets/js/form.js @@ -49,7 +49,7 @@ window.Hasgeek.initWidgets = async function init(fieldName, config) { window.Hasgeek.preventDoubleSubmit = function stopDoubleSubmit( formId, isXHR, - alertBoxHtml + alertBoxHtml, ) { if (isXHR) { document.body.addEventListener('htmx:beforeSend', () => { @@ -79,7 +79,7 @@ window.Hasgeek.recaptcha = function handleRecaptcha( formId, formWrapperId, ajax, - alertBoxHtml + alertBoxHtml, ) { if (ajax) { window.onInvisibleRecaptchaSubmit = function handleAjaxFormSubmit() { diff --git a/funnel/assets/js/notification_list.js b/funnel/assets/js/notification_list.js index 4b6eb277e..2fdb937a1 100644 --- a/funnel/assets/js/notification_list.js +++ b/funnel/assets/js/notification_list.js @@ -88,7 +88,7 @@ const Notification = { this.notifications[$(notification).attr('data-index')]; const url = this.markReadUrl.replace( 'eventid_b58', - notificationItem.notification.eventid_b58 + notificationItem.notification.eventid_b58, ); const response = await fetch(url, { method: 'POST', @@ -140,7 +140,7 @@ const Notification = { { rootMargin: '0px', threshold: 0, - } + }, ); notificationObserver.observe(elem); const notificationItem = app.notifications[$(elem).attr('data-index')]; diff --git a/funnel/assets/js/notification_settings.js b/funnel/assets/js/notification_settings.js index 5f6ac0347..9e2196191 100644 --- a/funnel/assets/js/notification_settings.js +++ b/funnel/assets/js/notification_settings.js @@ -45,15 +45,15 @@ $(() => { if (currentState && transport) { $(`input[data-transport="preference-${transport}"]`).attr( 'disabled', - false + false, ); $(`label[data-transport="preference-${transport}"]`).removeClass( - 'switch-label--disabled' + 'switch-label--disabled', ); } else if (transport) { $(`input[data-transport="preference-${transport}"]`).attr('disabled', true); $(`label[data-transport="preference-${transport}"]`).addClass( - 'switch-label--disabled' + 'switch-label--disabled', ); } }) diff --git a/funnel/assets/js/project_header.js b/funnel/assets/js/project_header.js index e352f3470..d33de1177 100644 --- a/funnel/assets/js/project_header.js +++ b/funnel/assets/js/project_header.js @@ -13,7 +13,7 @@ $(() => { tickets = '', toggleId = '', sort = '', - rsvpModalHash = 'register-modal' + rsvpModalHash = 'register-modal', ) => { if (saveProjectConfig) { SaveProject(saveProjectConfig); @@ -40,7 +40,7 @@ $(() => { openModal: true, }, '', - `#${rsvpModalHash}` + `#${rsvpModalHash}`, ); }); diff --git a/funnel/assets/js/scan_badge.js b/funnel/assets/js/scan_badge.js index 13c0706ac..f8a7ad892 100644 --- a/funnel/assets/js/scan_badge.js +++ b/funnel/assets/js/scan_badge.js @@ -113,7 +113,7 @@ const badgeScan = { 0, 0, canvasElement.width, - canvasElement.height + canvasElement.height, ); const qrcode = jsQR(imageData.data, imageData.width, imageData.height); this.verifyQRDecode(qrcode); @@ -165,8 +165,8 @@ const badgeScan = { this.set( 'error', window.gettext( - 'Unable to access video stream. Please make sure you have camera enabled or try a different browser' - ) + 'Unable to access video stream. Please make sure you have camera enabled or try a different browser', + ), ); } }, diff --git a/funnel/assets/js/scan_contact.js b/funnel/assets/js/scan_contact.js index c782589ff..9ea0dcfa2 100644 --- a/funnel/assets/js/scan_contact.js +++ b/funnel/assets/js/scan_contact.js @@ -37,8 +37,8 @@ const badgeScan = { event.node.setAttribute( 'href', `data:text/x-vcard;charset=utf-8,${encodeURIComponent( - vCard.getFormattedString() - )}` + vCard.getFormattedString(), + )}`, ); event.node.setAttribute('download', `${vCard.firstName}.vcf`); }, @@ -51,7 +51,7 @@ const badgeScan = { const puk = qrcode.substring(0, 8); const key = qrcode.substring(8); const formValues = `puk=${encodeURIComponent(puk)}&key=${encodeURIComponent( - key + key, )}`; function handleError(error) { @@ -88,7 +88,7 @@ const badgeScan = { .some( (contact) => contact.fullname === responseData.contact.fullname && - contact.email === responseData.contact.email + contact.email === responseData.contact.email, ) ) { badgeScanComponent.push('contacts', responseData.contact); @@ -129,7 +129,7 @@ const badgeScan = { 0, 0, canvasElement.width, - canvasElement.height + canvasElement.height, ); const qrcode = jsQR(imageData.data, imageData.width, imageData.height); this.verifyQRDecode(qrcode); @@ -162,8 +162,8 @@ const badgeScan = { this.set( 'error', window.gettext( - 'Unable to access video stream. Please make sure you have camera enabled or try a different browser' - ) + 'Unable to access video stream. Please make sure you have camera enabled or try a different browser', + ), ); } }, diff --git a/funnel/assets/js/schedule_view.js b/funnel/assets/js/schedule_view.js index 538b82d94..c440d59f0 100644 --- a/funnel/assets/js/schedule_view.js +++ b/funnel/assets/js/schedule_view.js @@ -71,7 +71,7 @@ const Schedule = { hasActiveRoom(session) { return Object.prototype.hasOwnProperty.call( session.rooms[this.activeTab], - 'talk' + 'talk', ); }, removeImg(descriptionHtml) { @@ -109,7 +109,7 @@ const Schedule = { openModal: true, }, '', - currentPage + currentPage, ); Spa.updateMetaTags(pageDetails); } @@ -193,7 +193,7 @@ const Schedule = { this.showSessionModal(activeSession); // Scroll page to session ScrollHelper.animateScrollTo( - $(`#${activeSession.url_name_uuid_b58}`).offset().top - this.headerHeight + $(`#${activeSession.url_name_uuid_b58}`).offset().top - this.headerHeight, ); } else if ( window.location.pathname === this.pathName && @@ -213,12 +213,12 @@ const Schedule = { } else if ($('.schedule__date--upcoming').length) { // Scroll to the upcoming schedule ScrollHelper.animateScrollTo( - $('.schedule__date--upcoming').first().offset().top - this.headerHeight + $('.schedule__date--upcoming').first().offset().top - this.headerHeight, ); } else { // Scroll to the last schedule ScrollHelper.animateScrollTo( - $('.schedule__date').last().offset().top - this.headerHeight + $('.schedule__date').last().offset().top - this.headerHeight, ); } window.history.replaceState( @@ -229,7 +229,7 @@ const Schedule = { refresh: false, }, '', - this.pageDetails.url + this.pageDetails.url, ); // On exiting the page, save page scroll position in session storage @@ -268,12 +268,12 @@ const Schedule = { session.endTime = this.Utils.getTime(session.end_at); session.eventDay = this.Utils.getEventDay( session.start_at, - this.config.eventDayhashes + this.config.eventDayhashes, ); session.duration = this.Utils.getDuration( session.end_at, session.start_at, - this.config.slotInterval + this.config.slotInterval, ); if (this.config.schedule[session.eventDay]) { this.config.schedule[session.eventDay].sessions[session.startTime].showLabel = @@ -302,7 +302,7 @@ const Schedule = { }; sessionSlots = new Date(sessionSlots); sessionSlots = sessionSlots.setMinutes( - sessionSlots.getMinutes() + this.config.slotInterval + sessionSlots.getMinutes() + this.config.slotInterval, ); } slots[day.endTime].showLabel = true; diff --git a/funnel/assets/js/search.js b/funnel/assets/js/search.js index 7ff852667..dae465b49 100644 --- a/funnel/assets/js/search.js +++ b/funnel/assets/js/search.js @@ -29,7 +29,7 @@ const Search = { scrollLeft: document.querySelector(`.${this.config.activetabClassName}`) .offsetLeft, }, - 'slow' + 'slow', ); } Utils.truncate(); diff --git a/funnel/assets/js/submission.js b/funnel/assets/js/submission.js index 7b8dcee30..8ade0f9a1 100644 --- a/funnel/assets/js/submission.js +++ b/funnel/assets/js/submission.js @@ -68,7 +68,7 @@ export const LabelsWidget = { const label = $(this).parent().parent().prev('.mui-form__label'); label.addClass('checked'); const labelTxt = `${Widget.getLabelTxt(label.text())}: ${Widget.getLabelTxt( - $(this).parent().find('label').text() + $(this).parent().find('label').text(), )}`; const attr = Widget.getLabelTxt(label.text()); Widget.updateLabels(labelTxt, attr, this.checked); @@ -110,7 +110,7 @@ export const LabelsWidget = { $(`.label[data-labeltxt='${attr}']`).remove(); } const labelSpan = $( - '' + '', ) .attr('data-labeltxt', attr) .text(label); diff --git a/funnel/assets/js/submission_form.js b/funnel/assets/js/submission_form.js index c24996a41..ebee56843 100644 --- a/funnel/assets/js/submission_form.js +++ b/funnel/assets/js/submission_form.js @@ -10,7 +10,7 @@ $(() => { sortUrl, formId, markdownPreviewElem, - markdownPreviewApi + markdownPreviewApi, ) { function updateCollaboratorsList(responseData, updateModal = true) { if (updateModal) $.modal.close(); @@ -136,7 +136,7 @@ $(() => { }) .blur((event) => { return $(event.currentTarget).val( - removeLineBreaks($(event.currentTarget).val()) + removeLineBreaks($(event.currentTarget).val()), ); }); diff --git a/funnel/assets/js/submissions.js b/funnel/assets/js/submissions.js index 269426645..a763efdc5 100644 --- a/funnel/assets/js/submissions.js +++ b/funnel/assets/js/submissions.js @@ -30,7 +30,7 @@ $(() => { if (openSubmission) { Widgets.openSubmissionToggle( openSubmission.toggleId, - openSubmission.cfpStatusElem + openSubmission.cfpStatusElem, ); } }; diff --git a/funnel/assets/js/update.js b/funnel/assets/js/update.js index 5e0ec16f7..bbab856c4 100644 --- a/funnel/assets/js/update.js +++ b/funnel/assets/js/update.js @@ -69,7 +69,7 @@ const Updates = { return this.now && this.update.published_at ? this.timeago.format( this.update.published_at, - window.Hasgeek.Config.locale + window.Hasgeek.Config.locale, ) : ''; }, @@ -106,7 +106,7 @@ const Updates = { if (window.location.hash) { ScrollHelper.animateScrollTo( document.getElementById(window.location.hash).getBoundingClientRect().top - - this.headerHeight + this.headerHeight, ); } Utils.truncate(); diff --git a/funnel/assets/js/utils/autocomplete_widget.js b/funnel/assets/js/utils/autocomplete_widget.js index 00793d902..f21b15166 100644 --- a/funnel/assets/js/utils/autocomplete_widget.js +++ b/funnel/assets/js/utils/autocomplete_widget.js @@ -106,7 +106,7 @@ const EnableAutocompleteWidgets = { if (data.status === 'ok') { for (let i = 0; i < data.result.length; i += 1) { $(options.selector).append( - `` + ``, ); rdata.push(data.result[i].geonameid); } diff --git a/funnel/assets/js/utils/codemirror_stylesheet.js b/funnel/assets/js/utils/codemirror_stylesheet.js index 88a88e4e0..c2f2de7b0 100644 --- a/funnel/assets/js/utils/codemirror_stylesheet.js +++ b/funnel/assets/js/utils/codemirror_stylesheet.js @@ -11,7 +11,7 @@ import { function codemirrorStylesheetHelper( textareaId, updateFnCallback = '', - callbackInterval = 1000 + callbackInterval = 1000, ) { let textareaWaitTimer; diff --git a/funnel/assets/js/utils/embedvideo.js b/funnel/assets/js/utils/embedvideo.js index b02b0d743..e2402cd39 100644 --- a/funnel/assets/js/utils/embedvideo.js +++ b/funnel/assets/js/utils/embedvideo.js @@ -8,7 +8,7 @@ const Video = { */ getVideoTypeAndId(url) { const regexMatch = url.match( - /(http:|https:|)\/\/(player.|www.)?(y2u\.be|vimeo\.com|youtu(be\.com|\.be|be\.googleapis\.com))\/(video\/|embed\/|live\/|watch\?v=|v\/)?([A-Za-z0-9._%-]*)(&\S+)?/ + /(http:|https:|)\/\/(player.|www.)?(y2u\.be|vimeo\.com|youtu(be\.com|\.be|be\.googleapis\.com))\/(video\/|embed\/|live\/|watch\?v=|v\/)?([A-Za-z0-9._%-]*)(&\S+)?/, ); let type = ''; if (regexMatch && regexMatch.length > 5) { diff --git a/funnel/assets/js/utils/form_widgets.js b/funnel/assets/js/utils/form_widgets.js index cf2a54466..62052e8e8 100644 --- a/funnel/assets/js/utils/form_widgets.js +++ b/funnel/assets/js/utils/form_widgets.js @@ -140,17 +140,17 @@ export async function activateFormWidgets() { $('#username').attr('autocomplete', inputMode); $('#username').blur(); $('#username').focus(); - } + }, ); if ( $( - 'textarea.markdown:not([style*="display: none"], .activating, .activated, .no-codemirror)' + 'textarea.markdown:not([style*="display: none"], .activating, .activated, .no-codemirror)', ).length ) { const { default: codemirrorHelper } = await import('./codemirror'); $( - 'textarea.markdown:not([style*="display: none"]:not(.activating):not(.activated)' + 'textarea.markdown:not([style*="display: none"]:not(.activating):not(.activated)', ).each(function enableCodemirror() { const markdownId = $(this).attr('id'); $(`#${markdownId}`).addClass('activating'); @@ -160,14 +160,14 @@ export async function activateFormWidgets() { if ( $( - 'textarea.stylesheet:not([style*="display: none"]:not(.activating):not(.activated)' + 'textarea.stylesheet:not([style*="display: none"]:not(.activating):not(.activated)', ).length ) { const { default: codemirrorStylesheetHelper } = await import( './codemirror_stylesheet' ); $( - 'textarea.stylesheet:not([style*="display: none"]:not(.activating):not(.activated)' + 'textarea.stylesheet:not([style*="display: none"]:not(.activating):not(.activated)', ).each(function enableCodemirrorForStylesheet() { const textareaId = $(this).attr('id'); $(`#${textareaId}`).addClass('activating'); diff --git a/funnel/assets/js/utils/formhelper.js b/funnel/assets/js/utils/formhelper.js index c13845c97..35dea6546 100644 --- a/funnel/assets/js/utils/formhelper.js +++ b/funnel/assets/js/utils/formhelper.js @@ -14,8 +14,8 @@ const Form = { ) { window.location.assign( `${window.Hasgeek.Config.accountSudo}?next=${encodeURIComponent( - window.location.href - )}` + window.location.href, + )}`, ); } else if ( response.status === 422 && diff --git a/funnel/assets/js/utils/gettext.js b/funnel/assets/js/utils/gettext.js index 76a51be1c..2e6d883cd 100644 --- a/funnel/assets/js/utils/gettext.js +++ b/funnel/assets/js/utils/gettext.js @@ -114,7 +114,7 @@ class Gettext { if (msgidCatalog.length < 2) { // eslint-disable-next-line no-console console.error( - 'Invalid format for translated messages, at least 2 values expected for plural translations' + 'Invalid format for translated messages, at least 2 values expected for plural translations', ); } else { let msgstr = ''; diff --git a/funnel/assets/js/utils/helper.js b/funnel/assets/js/utils/helper.js index 1af05e0fa..3b665e8b0 100644 --- a/funnel/assets/js/utils/helper.js +++ b/funnel/assets/js/utils/helper.js @@ -46,7 +46,7 @@ const Utils = { }, truncate() { const readMoreTxt = `…${gettext( - 'read more' + 'read more', )}`; $('.js-truncate').each(function truncateLines() { @@ -80,7 +80,7 @@ const Utils = { firstActiveWeek .find( - '.calendar__weekdays__dates__date--showtime.calendar__weekdays__dates__date--latest:first' + '.calendar__weekdays__dates__date--showtime.calendar__weekdays__dates__date--latest:first', ) .addClass('calendar__weekdays__dates__date--display'); @@ -98,7 +98,7 @@ const Utils = { .mouseleave(() => { firstActiveWeek .find( - '.calendar__weekdays__dates__date--showtime.calendar__weekdays__dates__date--latest:first' + '.calendar__weekdays__dates__date--showtime.calendar__weekdays__dates__date--latest:first', ) .addClass('calendar__weekdays__dates__date--display'); }); @@ -108,7 +108,7 @@ const Utils = { .find('.calendar__weekdays__dates--upcoming--first') .first() .find( - '.calendar__weekdays__dates__date--showtime.calendar__weekdays__dates__date--latest' + '.calendar__weekdays__dates__date--showtime.calendar__weekdays__dates__date--latest', ) .first(); const eventDate = nextEventElem.data('event-date'); @@ -198,7 +198,7 @@ const Utils = { useElem.setAttributeNS( 'http://www.w3.org/1999/xlink', 'xlink:href', - `${window.Hasgeek.Config.svgIconUrl}#${icon}` + `${window.Hasgeek.Config.svgIconUrl}#${icon}`, ); svgElem.appendChild(useElem); svgElem.classList.add(`fa5-icon--${iconSize}`); @@ -234,7 +234,7 @@ const Utils = { if (navigator.clipboard) { navigator.clipboard.writeText(stringToCopy).then( () => toastr.success(window.gettext('Link copied')), - () => toastr.success(window.gettext('Could not copy link')) + () => toastr.success(window.gettext('Could not copy link')), ); } else { const selection = window.getSelection(); diff --git a/funnel/assets/js/utils/lazyloadimage.js b/funnel/assets/js/utils/lazyloadimage.js index 398b85736..c92b5ea65 100644 --- a/funnel/assets/js/utils/lazyloadimage.js +++ b/funnel/assets/js/utils/lazyloadimage.js @@ -16,7 +16,7 @@ const LazyloadImg = { polyfill.setAttribute('type', 'text/javascript'); polyfill.setAttribute( 'src', - 'https://cdn.polyfill.io/v2/polyfill.min.js?features=IntersectionObserver' + 'https://cdn.polyfill.io/v2/polyfill.min.js?features=IntersectionObserver', ); polyfill.onload = function loadintersectionObserverComponents() { intersectionObserverComponents(); @@ -46,7 +46,7 @@ const LazyloadImg = { { rootMargin: '0px', threshold: 0, - } + }, ); observer.observe(img); } diff --git a/funnel/assets/js/utils/lazyloadmenu.js b/funnel/assets/js/utils/lazyloadmenu.js index 637dc0075..58b731926 100644 --- a/funnel/assets/js/utils/lazyloadmenu.js +++ b/funnel/assets/js/utils/lazyloadmenu.js @@ -66,7 +66,7 @@ const LazyLoadMenu = { { rootMargin: '0px', threshold: 0, - } + }, ); observer.observe(lazyLoader); } @@ -108,14 +108,14 @@ const LazyLoadMenu = { '.js-menu-btn', '.js-account-menu-wrapper', '.js-account-menu', - window.Hasgeek.Config.accountMenu + window.Hasgeek.Config.accountMenu, ); if (window.Hasgeek.Config.commentSidebarElem) { LazyLoadMenu.headerMenuDropdown( '.js-comments-btn', '.js-comments-wrapper', '.js-comment-sidebar', - window.Hasgeek.Config.unreadCommentUrl + window.Hasgeek.Config.unreadCommentUrl, ); } }, diff --git a/funnel/assets/js/utils/markmap.js b/funnel/assets/js/utils/markmap.js index 137f9ab72..81a6f657c 100644 --- a/funnel/assets/js/utils/markmap.js +++ b/funnel/assets/js/utils/markmap.js @@ -28,7 +28,7 @@ const MarkmapEmbed = { }, { root: $('.main-content')[0], - } + }, ); parentElement @@ -38,7 +38,7 @@ const MarkmapEmbed = { $(markdownDiv).addClass('activating'); $(markdownDiv).find('.embed-loading').addClass('loading'); const { root } = transformer.transform( - $(markdownDiv).find('.embed-content').text() + $(markdownDiv).find('.embed-content').text(), ); $(markdownDiv).find('.embed-container').append(''); const current = $(markdownDiv).find('svg')[0]; @@ -50,7 +50,7 @@ const MarkmapEmbed = { fitRatio: 0.85, initialExpandLevel: 1, }, - root + root, ); markmapEmbed.markmaps.push(markmap); $(current).data('markmap', markmap); diff --git a/funnel/assets/js/utils/mermaid.js b/funnel/assets/js/utils/mermaid.js index 99ed18b71..c76de9811 100644 --- a/funnel/assets/js/utils/mermaid.js +++ b/funnel/assets/js/utils/mermaid.js @@ -5,7 +5,7 @@ async function addMermaidEmbed(container) { let idCount = $('.md-embed-mermaid.activating, .md-embed-mermaid.activated').length; const idMarker = 'mermaid_elem_'; const instances = parentElement.find( - '.md-embed-mermaid:not(.activating):not(.activated)' + '.md-embed-mermaid:not(.activating):not(.activated)', ); instances.each(function embedMermaid() { const root = $(this); diff --git a/funnel/assets/js/utils/modalhelper.js b/funnel/assets/js/utils/modalhelper.js index 1e232f562..0516d6bf9 100644 --- a/funnel/assets/js/utils/modalhelper.js +++ b/funnel/assets/js/utils/modalhelper.js @@ -9,7 +9,7 @@ const Modal = { window.history.replaceState( '', '', - window.location.pathname + window.location.search + window.location.pathname + window.location.search, ); } }); @@ -21,7 +21,7 @@ const Modal = { $.modal.close(); } }, - false + false, ); const hashId = window.location.hash.split('#')[1]; @@ -88,7 +88,7 @@ const Modal = { $('body').append(''); $('.markdown-modal').html($(this)[0].outerHTML); $('.markdown-modal').modal(); - } + }, ); $('body').on('click', '.markdown table a', (event) => { diff --git a/funnel/assets/js/utils/ractive_util.js b/funnel/assets/js/utils/ractive_util.js index 960da4388..8823ed1a0 100644 --- a/funnel/assets/js/utils/ractive_util.js +++ b/funnel/assets/js/utils/ractive_util.js @@ -12,7 +12,7 @@ export const useravatar = Ractive.extend({ getInitials: Utils.getInitials, imgurl() { return `${this.get('user').logo_url}?size=${encodeURIComponent( - USER_AVATAR_IMG_SIZE[this.get('size')] + USER_AVATAR_IMG_SIZE[this.get('size')], )}`; }, getAvatarColour(name) { diff --git a/funnel/assets/js/utils/read_status.js b/funnel/assets/js/utils/read_status.js index 71fe7e1e3..4bc54e7f5 100644 --- a/funnel/assets/js/utils/read_status.js +++ b/funnel/assets/js/utils/read_status.js @@ -7,7 +7,7 @@ const ReadStatus = { $('.header__nav-links--updates').addClass('header__nav-links--updates--unread'); } else { $('.header__nav-links--updates').removeClass( - 'header__nav-links--updates--unread' + 'header__nav-links--updates--unread', ); } }, @@ -30,7 +30,7 @@ const ReadStatus = { if (notificationID && Base58regex.test(notificationID)) { const url = window.Hasgeek.Config.markNotificationReadUrl.replace( 'eventid_b58', - notificationID + notificationID, ); const response = await fetch(url, { method: 'POST', @@ -115,7 +115,7 @@ const ReadStatus = { { rootMargin: '0px', threshold: 0, - } + }, ); observer.observe(lazyLoader); } @@ -158,7 +158,7 @@ const ReadStatus = { ReadStatus.updateNotificationStatus(); window.setInterval( ReadStatus.updateNotificationStatus, - NOTIFICATION_REFRESH_INTERVAL + NOTIFICATION_REFRESH_INTERVAL, ); } }, diff --git a/funnel/assets/js/utils/scrollhelper.js b/funnel/assets/js/utils/scrollhelper.js index 068ef821e..da0125447 100644 --- a/funnel/assets/js/utils/scrollhelper.js +++ b/funnel/assets/js/utils/scrollhelper.js @@ -6,7 +6,7 @@ const ScrollHelper = { { scrollTop: offsetY, }, - 'slow' + 'slow', ); }, smoothScroll() { @@ -30,7 +30,7 @@ const ScrollHelper = { { scrollLeft: document.querySelector('.tabs__item--active').offsetLeft, }, - 'slow' + 'slow', ); $('#jquery-scroll-tabs .js-scroll-prev').on('click', (event) => { event.preventDefault(); diff --git a/funnel/assets/js/utils/scrollmenu.js b/funnel/assets/js/utils/scrollmenu.js index cd728b351..e0d011ee5 100644 --- a/funnel/assets/js/utils/scrollmenu.js +++ b/funnel/assets/js/utils/scrollmenu.js @@ -33,7 +33,7 @@ const ScrollActiveMenu = { if (entry.isIntersecting) { const activeNavItem = this.navItems.find( (navItem) => - navItem.getAttribute('href') === `#${entry.target.getAttribute('id')}` + navItem.getAttribute('href') === `#${entry.target.getAttribute('id')}`, ); this.setActiveNavItem(activeNavItem); } @@ -48,7 +48,7 @@ const ScrollActiveMenu = { { scrollLeft: activeNavItem.offsetLeft, }, - 'slow' + 'slow', ); }, }; diff --git a/funnel/assets/js/utils/spahelper.js b/funnel/assets/js/utils/spahelper.js index 0cfec5fb5..e0893be3f 100644 --- a/funnel/assets/js/utils/spahelper.js +++ b/funnel/assets/js/utils/spahelper.js @@ -19,7 +19,7 @@ const Spa = { refresh: true, }, '', - window.location.href + window.location.href, ); $(window).on('popstate', () => { @@ -41,7 +41,7 @@ const Spa = { refresh: true, }, '', - pageDetails.url + pageDetails.url, ); pageDetails.pageTitle = pageDetails.title ? `${pageDetails.title} – ${Spa.pageTitle}` diff --git a/funnel/assets/js/utils/tabs.js b/funnel/assets/js/utils/tabs.js index 1a3259cc5..01694b217 100644 --- a/funnel/assets/js/utils/tabs.js +++ b/funnel/assets/js/utils/tabs.js @@ -17,7 +17,7 @@ const Tabs = { { root: tablist, threshold: 1, - } + }, ); }); }, @@ -26,10 +26,10 @@ const Tabs = { // Wrap the tabs bar with a container, to allow introduction of // tabs navigation arrow icons. const $leftIcons = $('').html( - Object.values(icons.left) + Object.values(icons.left), ); const $rightIcons = $('').html( - Object.values(icons.right) + Object.values(icons.right), ); $(tablist) .wrap('') @@ -169,10 +169,10 @@ const Tabs = { visibilityObserver.observe(tab); const $panel = $(`#${$(tab).attr('aria-controls')}`); $panel.mouseenter( - $tablistContainer.addClass.bind($tablistContainer, 'has-panel-hover') + $tablistContainer.addClass.bind($tablistContainer, 'has-panel-hover'), ); $panel.mouseleave( - $tablistContainer.removeClass.bind($tablistContainer, 'has-panel-hover') + $tablistContainer.removeClass.bind($tablistContainer, 'has-panel-hover'), ); } }); @@ -187,7 +187,7 @@ const Tabs = { async init(container) { const $parentElement = $(container || 'body'); const $tablists = $parentElement.find( - '[role=tablist]:not(.activating, .activated)' + '[role=tablist]:not(.activating, .activated)', ); $tablists.addClass('activating'); this.process($parentElement, $tablists); diff --git a/funnel/assets/js/utils/ticket_widget.js b/funnel/assets/js/utils/ticket_widget.js index 5a45fff5f..1ce1a4dc2 100644 --- a/funnel/assets/js/utils/ticket_widget.js +++ b/funnel/assets/js/utils/ticket_widget.js @@ -48,7 +48,7 @@ const Ticketing = { if (response.readyState === 4) { errorMsg = window.gettext( - 'The server is experiencing difficulties. Try again in a few minutes' + 'The server is experiencing difficulties. Try again in a few minutes', ); $(widgetElem).html(errorMsg); } else if (response.readyState === 0) { @@ -57,7 +57,7 @@ const Ticketing = { errorMsg = window.gettext('This device has no internet connection'); } else { errorMsg = window.gettext( - 'Unable to connect. If this device is behind a firewall or using any script blocking extension (like Privacy Badger), please ensure your browser can load boxoffice.hasgeek.com, api.razorpay.com and checkout.razorpay.com' + 'Unable to connect. If this device is behind a firewall or using any script blocking extension (like Privacy Badger), please ensure your browser can load boxoffice.hasgeek.com, api.razorpay.com and checkout.razorpay.com', ); } @@ -82,7 +82,7 @@ const Ticketing = { user_phone: userPhone, }); }, - false + false, ); $(document).on('boxofficeTicketingEvents', (event, userAction, label, value) => { Analytics.sendToGA('ticketing', userAction, label, value); @@ -111,7 +111,7 @@ const Ticketing = { } $('.js-ticket-price').text(price); } - } + }, ); }, @@ -142,7 +142,7 @@ const Ticketing = { openModal: true, }, '', - this.urlHash + this.urlHash, ); $('.header').addClass('header--lowzindex'); $('.tickets-wrapper__modal').addClass('tickets-wrapper__modal--show'); diff --git a/funnel/assets/js/utils/update_parsley_config.js b/funnel/assets/js/utils/update_parsley_config.js index 8fdb4dd17..74eb5def6 100644 --- a/funnel/assets/js/utils/update_parsley_config.js +++ b/funnel/assets/js/utils/update_parsley_config.js @@ -42,7 +42,7 @@ function updateParsleyConfig() { integer: 'This value should be a valid integer', digits: 'This value should be digits', alphanum: 'This value should be alphanumeric', - } + }, ); } diff --git a/funnel/assets/js/utils/vegaembed.js b/funnel/assets/js/utils/vegaembed.js index c409a708a..7cf00e2c2 100644 --- a/funnel/assets/js/utils/vegaembed.js +++ b/funnel/assets/js/utils/vegaembed.js @@ -22,7 +22,7 @@ async function addVegaSupport(container) { const embedded = await embed( root.find('.embed-container')[0], JSON.parse(root.find('.embed-content').text()), - options + options, ); embedded.view.runAfter(() => { root.addClass('activated').removeClass('activating'); diff --git a/funnel/assets/js/utils/vue_util.js b/funnel/assets/js/utils/vue_util.js index ebcfda572..0c29dd825 100644 --- a/funnel/assets/js/utils/vue_util.js +++ b/funnel/assets/js/utils/vue_util.js @@ -76,22 +76,22 @@ export const shareDropdown = Vue.component('sharedropdown', { computed: { twitterUrl() { return `https://twitter.com/share?url=${encodeURIComponent( - this.url + this.url, )}&text=${encodeURIComponent(this.title)}+(via+@hasgeek)`; }, facebookUrl() { return `https://www.facebook.com/sharer.php?u=${encodeURIComponent( - this.url + this.url, )}&t=${encodeURIComponent(this.title)}`; }, emailUrl() { return `mailto:?subject=${encodeURIComponent( - this.title + this.title, )}&body=${encodeURIComponent(this.url)}`; }, linkedinUrl() { return `https://www.linkedin.com/shareArticle?mini=true&url=${encodeURIComponent( - this.url + this.url, )}&title=${encodeURIComponent(this.title)}`; }, }, diff --git a/funnel/assets/service-worker-template.js b/funnel/assets/service-worker-template.js index 33e54e9eb..498a88f38 100644 --- a/funnel/assets/service-worker-template.js +++ b/funnel/assets/service-worker-template.js @@ -16,7 +16,7 @@ registerRoute( new NetworkFirst({ cacheName: 'offline', }), - 'GET' + 'GET', ); registerRoute( @@ -24,14 +24,14 @@ registerRoute( new NetworkFirst({ cacheName: 'homepage', }), - 'GET' + 'GET', ); registerRoute(new RegExp('/(.*)'), new NetworkOnly(), 'GET'); self.addEventListener('install', (event) => { event.waitUntil( - caches.open('offline').then((cache) => cache.addAll(['/api/1/template/offline'])) + caches.open('offline').then((cache) => cache.addAll(['/api/1/template/offline'])), ); }); diff --git a/funnel/static/js/libs/mui.js b/funnel/static/js/libs/mui.js index 84def4732..679a38b68 100644 --- a/funnel/static/js/libs/mui.js +++ b/funnel/static/js/libs/mui.js @@ -21,7 +21,7 @@ t, e, i, - n + n, ); } return i[s].exports; @@ -286,7 +286,7 @@ function o(s) { i && i.apply(this, arguments), r(t, e, o, n); }, - n + n, ); }); }, @@ -1015,7 +1015,7 @@ for ( var t = document, e = t.querySelectorAll( - '.mui-textfield > input, .mui-textfield > textarea' + '.mui-textfield > input, .mui-textfield > textarea', ), i = e.length; i--; @@ -1059,5 +1059,5 @@ ], }, {}, - [1] + [1], ); diff --git a/funnel/static/js/libs/spectrum.js b/funnel/static/js/libs/spectrum.js index f38870b79..434014378 100644 --- a/funnel/static/js/libs/spectrum.js +++ b/funnel/static/js/libs/spectrum.js @@ -129,14 +129,14 @@ c + '">' + ';" />', ); } else { var cls = 'sp-clear-display'; html.push( '' + '">', ); } } @@ -366,7 +366,7 @@ move(); }, dragStart, - dragStop + dragStop, ); draggable( @@ -398,7 +398,7 @@ move(); }, dragStart, - dragStop + dragStop, ); if (!!initialColor) { @@ -440,7 +440,7 @@ '.sp-thumb-el:nth-child(1)', paletteEvent, { ignore: true }, - palletElementClick + palletElementClick, ); } @@ -496,7 +496,7 @@ return paletteTemplate( palette, currentColor, - 'sp-palette-row sp-palette-row-' + i + 'sp-palette-row sp-palette-row-' + i, ); }); @@ -505,8 +505,8 @@ paletteTemplate( getUniqueSelectionPalette(), currentColor, - 'sp-palette-row sp-palette-row-selection' - ) + 'sp-palette-row sp-palette-row-selection', + ), ); } @@ -518,7 +518,7 @@ var initial = colorOnShow; var current = get(); initialColorContainer.html( - paletteTemplate([initial, current], current, 'sp-palette-row-initial') + paletteTemplate([initial, current], current, 'sp-palette-row-initial'), ); } } @@ -668,7 +668,7 @@ v: currentValue, a: Math.round(currentAlpha * 100) / 100, }, - { format: opts.format || currentPreferredFormat } + { format: opts.format || currentPreferredFormat }, ); } @@ -736,7 +736,7 @@ if (IE) { alphaSliderInner.css( 'filter', - tinycolor(realAlpha).toFilter({ gradientType: 1 }, realHex) + tinycolor(realAlpha).toFilter({ gradientType: 1 }, realHex), ); } else { alphaSliderInner.css('background', '-webkit-' + gradient); @@ -780,11 +780,11 @@ var dragY = dragHeight - v * dragHeight; dragX = Math.max( -dragHelperHeight, - Math.min(dragWidth - dragHelperHeight, dragX - dragHelperHeight) + Math.min(dragWidth - dragHelperHeight, dragX - dragHelperHeight), ); dragY = Math.max( -dragHelperHeight, - Math.min(dragHeight - dragHelperHeight, dragY - dragHelperHeight) + Math.min(dragHeight - dragHelperHeight, dragY - dragHelperHeight), ); dragHelper.css({ top: dragY, @@ -922,14 +922,14 @@ offset.left, offset.left + dpWidth > viewWidth && viewWidth > dpWidth ? Math.abs(offset.left + dpWidth - viewWidth) - : 0 + : 0, ); offset.top -= Math.min( offset.top, offset.top + dpHeight > viewHeight && viewHeight > dpHeight ? Math.abs(dpHeight + inputHeight - extraY) - : extraY + : extraY, ); return offset; diff --git a/funnel/static/js/schedules.js b/funnel/static/js/schedules.js index 9eefcb862..c53f8f24d 100644 --- a/funnel/static/js/schedules.js +++ b/funnel/static/js/schedules.js @@ -106,10 +106,10 @@ $(function () { var room = { uuid_b58: roomUuidB58, seq: $( - 'input[name="room-seq"][data-room="' + roomUuidB58 + '"]' + 'input[name="room-seq"][data-room="' + roomUuidB58 + '"]', ).val(), color: $( - 'input[name="color"][data-room="' + roomUuidB58 + '"]' + 'input[name="color"][data-room="' + roomUuidB58 + '"]', ).val(), }; json[venue]['rooms'].push(room); @@ -124,15 +124,15 @@ $(function () { data: JSON.stringify(json), success: function (result) { window.toastr.success( - gettext('The room sequence and colours have been updated') + gettext('The room sequence and colours have been updated'), ); }, complete: function (xhr, type) { if (type == 'error' || type == 'timeout') { window.toastr.error( gettext( - 'The server could not be reached. Check connection and try again' - ) + 'The server could not be reached. Check connection and try again', + ), ); } }, @@ -231,8 +231,8 @@ $(function () { if (type == 'error' || type == 'timeout') { window.toastr.error( gettext( - 'The server could not be reached. Check connection and try again' - ) + 'The server could not be reached. Check connection and try again', + ), ); } popup.submitting = false; @@ -263,7 +263,7 @@ $(function () { .text( $.fullCalendar.formatDate(events.current.start, 'd MMMM, yyyy H:mm') + ' - ' + - $.fullCalendar.formatDate(events.current.end, 'H:mm') + $.fullCalendar.formatDate(events.current.end, 'H:mm'), ); } popup.body().html(result.form); @@ -273,7 +273,9 @@ $(function () { if (type == 'error' || type == 'timeout') { popup.close(); window.toastr.error( - gettext('The server could not be reached. Check connection and try again') + gettext( + 'The server could not be reached. Check connection and try again', + ), ); } }, @@ -386,7 +388,7 @@ $(function () { calendar.temp[filter] = args; var return_data = calendar.container.fullCalendar( 'clientEvents', - calendar.filters[filter] + calendar.filters[filter], ); delete calendar.temp[filter]; return return_data; @@ -447,7 +449,7 @@ $(function () { event.start = date; event.end = new Date(date.getTime()); event.end.setMinutes( - event.end.getMinutes() + calendar.options.config.defaultEventMinutes + event.end.getMinutes() + calendar.options.config.defaultEventMinutes, ); event.unscheduled = source; calendar.add(event); @@ -463,7 +465,7 @@ $(function () { element.append(''); var custom = element.find('.fc-event-custom'); custom.append( - '×' + '×', ); custom.find('.fc-event-delete').click(function (e) { if (confirm(gettext('Remove %s from the schedule?', event.obj_data.title))) { @@ -484,8 +486,8 @@ $(function () { if (type == 'error' || type == 'timeout') { window.toastr.error( gettext( - 'The server could not be reached. Check connection and try again' - ) + 'The server could not be reached. Check connection and try again', + ), ); } }, @@ -522,7 +524,7 @@ $(function () { .append( ' ' + '', ); var button = calendar.container.find('.save-schedule'); button.enable = function (label) { @@ -556,7 +558,7 @@ $(function () { }, function () { $(this).removeClass('fc-state-hover'); - } + }, ); calendar.container .find('.fc-header-left') @@ -569,10 +571,10 @@ $(function () { gettext('30 mins') + ' ' + '', ); $( - '.js-fc-zoom[data-slotinterval=' + calendar.options.config.slotMinutes + ']' + '.js-fc-zoom[data-slotinterval=' + calendar.options.config.slotMinutes + ']', ).addClass('tabs__item--active'); $('.js-fc-zoom').on('click', function () { var zoom = $(this).data('slotinterval'); @@ -593,7 +595,7 @@ $(function () { .prepend( '' + '', ); var autosaver = calendar.container.find('.autosave'); autosaver.prop('checked', events.autosave); @@ -715,14 +717,14 @@ $(function () { window.toastr.error( gettext( 'The server could not be reached. There are %d unsaved sessions. Check connection and try again', - e.length - ) + e.length, + ), ); } else { window.toastr.error( gettext( - 'The server could not be reached. There is 1 unsaved session. Check connection and try again' - ) + 'The server could not be reached. There is 1 unsaved session. Check connection and try again', + ), ); } } @@ -755,10 +757,10 @@ $(function () { modal_url + '">' + title + - '' + '', ); unscheduled_events.add( - unscheduled_events.container.find('.js-unscheduled').first() + unscheduled_events.container.find('.js-unscheduled').first(), ); }, }; diff --git a/tests/cypress/e2e/06_manageVenue.cy.js b/tests/cypress/e2e/06_manageVenue.cy.js index 5f86e3205..a68538a56 100644 --- a/tests/cypress/e2e/06_manageVenue.cy.js +++ b/tests/cypress/e2e/06_manageVenue.cy.js @@ -30,7 +30,7 @@ describe('Manage project venue', () => { cy.get('button[data-cy="form-submit-btn"]').click(); cy.location('pathname').should( 'include', - `/testcypressproject/${project.url}/venues` + `/testcypressproject/${project.url}/venues`, ); }); @@ -51,7 +51,7 @@ describe('Manage project venue', () => { cy.get('button[data-cy="form-submit-btn"]').click(); cy.location('pathname').should( 'include', - `/testcypressproject/${project.url}/venues` + `/testcypressproject/${project.url}/venues`, ); cy.get(`.card[data-cy-venue="${venue.venue_title}"]`) .find('li') diff --git a/tests/cypress/e2e/07_addCFP.cy.js b/tests/cypress/e2e/07_addCFP.cy.js index 365c8e92e..88bae5df7 100644 --- a/tests/cypress/e2e/07_addCFP.cy.js +++ b/tests/cypress/e2e/07_addCFP.cy.js @@ -39,7 +39,7 @@ describe('Add CFP and labels to project', () => { cy.get('.emojionearea-button').click(); cy.get('.emojionearea-picker').should('be.visible'); cy.get( - '.emojionearea-category[name="smileys_people"] i[title="Innocent"]' + '.emojionearea-category[name="smileys_people"] i[title="Innocent"]', ).click(); cy.get('.emojionearea-picker').should('be.hidden'); diff --git a/tests/cypress/e2e/08_addSubmission.cy.js b/tests/cypress/e2e/08_addSubmission.cy.js index 16a8ad500..5b3eeb1f2 100644 --- a/tests/cypress/e2e/08_addSubmission.cy.js +++ b/tests/cypress/e2e/08_addSubmission.cy.js @@ -52,7 +52,7 @@ describe('Add a new submission', () => { force: true, }); cy.get('.select2-results__option--highlighted', { timeout: 20000 }).should( - 'be.visible' + 'be.visible', ); cy.get('.select2-results__option').contains(usher.username).click(); cy.get('.select2-results__options', { timeout: 10000 }).should('not.exist'); diff --git a/tests/cypress/e2e/23_addSponsor.cy.js b/tests/cypress/e2e/23_addSponsor.cy.js index 3ed08c242..9ee214955 100644 --- a/tests/cypress/e2e/23_addSponsor.cy.js +++ b/tests/cypress/e2e/23_addSponsor.cy.js @@ -25,7 +25,7 @@ describe('Add sponsor to project', () => { force: true, }); cy.get('.select2-results__option--highlighted', { timeout: 20000 }).should( - 'be.visible' + 'be.visible', ); cy.get('.select2-results__option').contains(sponsor.name).click(); cy.get('.select2-results__options', { timeout: 10000 }).should('not.exist'); diff --git a/tests/cypress/support.js b/tests/cypress/support.js index 00a318183..a100c91e6 100644 --- a/tests/cypress/support.js +++ b/tests/cypress/support.js @@ -35,7 +35,7 @@ Cypress.Commands.add('add_profile_member', (username, field, role, fail = false) force: true, }); cy.get('.select2-results__option--highlighted', { timeout: 20000 }).should( - 'be.visible' + 'be.visible', ); cy.get('.select2-results__option').contains(username).click(); cy.get('.select2-results__options', { timeout: 10000 }).should('not.exist'); @@ -69,7 +69,7 @@ Cypress.Commands.add('add_member', (username, role, fail = false) => { force: true, }); cy.get('.select2-results__option--highlighted', { timeout: 20000 }).should( - 'be.visible' + 'be.visible', ); cy.get('.select2-results__option').contains(username).click(); cy.get('.select2-results__options', { timeout: 10000 }).should('not.exist'); diff --git a/webpack.config.js b/webpack.config.js index 6fd845a1a..b03eff83f 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -47,7 +47,7 @@ module.exports = { notification_list: path.resolve(__dirname, 'funnel/assets/js/notification_list.js'), notification_settings: path.resolve( __dirname, - 'funnel/assets/js/notification_settings.js' + 'funnel/assets/js/notification_settings.js', ), account_saved: path.resolve(__dirname, 'funnel/assets/js/account_saved.js'), autosave_form: path.resolve(__dirname, 'funnel/assets/js/autosave_form.js'), @@ -64,7 +64,7 @@ module.exports = { profile_css: path.resolve(__dirname, 'funnel/assets/sass/pages/profile.scss'), profile_calendar_css: path.resolve( __dirname, - 'funnel/assets/sass/pages/profile_calendar.scss' + 'funnel/assets/sass/pages/profile_calendar.scss', ), project_css: path.resolve(__dirname, 'funnel/assets/sass/pages/project.scss'), submission_css: path.resolve(__dirname, 'funnel/assets/sass/pages/submission.scss'), @@ -77,19 +77,19 @@ module.exports = { contacts_css: path.resolve(__dirname, 'funnel/assets/sass/pages/contacts.scss'), submissions_css: path.resolve( __dirname, - 'funnel/assets/sass/pages/submissions.scss' + 'funnel/assets/sass/pages/submissions.scss', ), membership_css: path.resolve(__dirname, 'funnel/assets/sass/pages/membership.scss'), account_css: path.resolve(__dirname, 'funnel/assets/sass/pages/account.scss'), update_css: path.resolve(__dirname, 'funnel/assets/sass/pages/update.scss'), imgee_modal_css: path.resolve( __dirname, - 'funnel/assets/sass/pages/imgee_modal.scss' + 'funnel/assets/sass/pages/imgee_modal.scss', ), label_form_css: path.resolve(__dirname, 'funnel/assets/sass/pages/label_form.scss'), submission_form_css: path.resolve( __dirname, - 'funnel/assets/sass/pages/submission_form.scss' + 'funnel/assets/sass/pages/submission_form.scss', ), screens_css: path.resolve(__dirname, 'funnel/assets/sass/pages/screens.scss'), event_css: path.resolve(__dirname, 'funnel/assets/sass/pages/event.scss'),