{"version":3,"sources":["webpack:///./droplab/plugins/input_setter.js","webpack:///./pager.js","webpack:///./activities.js","webpack:///./projects_list.js","webpack:///./notifications_form.js","webpack:///./notifications_dropdown.js","webpack:///./pages/users/activity_calendar.js","webpack:///./pages/users/user_tabs.js","webpack:///./shortcuts_navigation.js","webpack:///./groups/new_group_child.js","webpack:///./pages/groups/show/group_tabs.js","webpack:///./pages/groups/show/index.js"],"names":["InputSetter","init","hook","this","destroyed","config","eventWrapper","addEvents","setInputs","bind","list","addEventListener","removeEvents","removeEventListener","e","_this","selectedItem","detail","selected","Array","isArray","forEach","setInput","input","trigger","newValue","getAttribute","valueAttribute","inputAttribute","hasAttribute","setAttribute","tagName","value","textContent","destroy","__webpack_exports__","limit","arguments","length","undefined","preload","disable","prepareData","jquery__WEBPACK_IMPORTED_MODULE_0___default","a","noop","callback","url","data","Object","_lib_utils_url_utility__WEBPACK_IMPORTED_MODULE_3__","offset","parseInt","_lib_utils_common_utils__WEBPACK_IMPORTED_MODULE_1__","loading","first","getOld","initLoadMore","show","_lib_utils_axios_utils__WEBPACK_IMPORTED_MODULE_2__","get","params","then","_ref","append","count","html","isScrollable","hide","catch","$w","window","document","height","scrollTop","_this2","off","endlessScroll","bottomPixels","fireDelay","fireOnce","ceaseFire","is","Activities","_classCallCheck","_pager__WEBPACK_IMPORTED_MODULE_2__","updateTooltips","on","preventDefault","toggleFilter","currentTarget","reloadActivities","_lib_utils_datetime_utility__WEBPACK_IMPORTED_MODULE_3__","sender","$sender","filter","attr","split","removeClass","js_cookie__WEBPACK_IMPORTED_MODULE_1___default","set","closest","toggleClass","ProjectsList","form","querySelector","holder","_filterable_list__WEBPACK_IMPORTED_MODULE_0__","initSearch","NotificationsForm","toggleCheckbox","initEventListeners","$checkbox","$parent","saveEvent","addClass","find","parents","showCheckboxLoadingSpinner","serialize","enable","saved","setTimeout","_flash__WEBPACK_IMPORTED_MODULE_3__","_locale__WEBPACK_IMPORTED_MODULE_1__","notificationsDropdown","notificationLevel","val","submit","replaceWith","_flash__WEBPACK_IMPORTED_MODULE_1__","d3","select","d3_selection","scaleLinear","d3_scale","scaleThreshold","initColorKey","range","domain","ActivityCalendar","container","timestamps","calendarActivitiesPath","utcOffset","firstDayOfWeek","clickDay","currentSelectedDate","daySpace","daySize","daySizeWithSpace","monthNames","months","timestampsTmp","group","today","systemUtcOffsetSeconds","date","Date","localUtcOffsetMinutes","getTimezoneOffset","systemUtcOffsetMinutes","setMinutes","getMinutes","getSystemDate","setHours","oneYearAgo","setFullYear","getFullYear","days","datetime_utility","i","setDate","getDate","day","getDay","dateformat_default","push","colorKey","color","initColor","svg","renderSvg","renderDays","renderMonths","renderDayTitles","renderKey","jquery_default","tooltip","extraWidthPadding","getMonth","width","getExtraWidthPadding","selectAll","enter","underscore_default","each","stamp","month","x","lastMonth","last","dayYPos","Math","min","dateObject","dateDayName","dateText","contribText","text","y","_this3","keyValues","keyColors","colorRange","join","LOADING_HTML","axios_utils","responseType","_ref2","flash","locale","user_tabs_UserTabs","UserTabs","defaultAction","action","parentEl","user_tabs_classCallCheck","loaded","$parentEl","windowLocation","location","navLink","actions","keys","bindEvents","activateTab","event","tabShown","changeProjectsPage","empty","endpoint","target","loadTab","getCurrentAction","$target","source","setTab","setCurrentAction","tab","loadActivities","indexOf","toggleLoading","tabSelector","activity","$calendarWrap","calendarPath","utcFormatted","_ref3","CALENDAR_TEMPLATE","activity_calendar","activities","status","newState","replace","search","hash","history","replaceState","title","ShortcutsNavigation","_possibleConstructorReturn","__proto__","getPrototypeOf","call","mousetrap__WEBPACK_IMPORTED_MODULE_0___default","_shortcuts_dashboard_navigation__WEBPACK_IMPORTED_MODULE_1__","enabledHelp","_shortcuts__WEBPACK_IMPORTED_MODULE_2__","assign","input_setter","NewGroupChild","buttonWrapper","newGroupChildButton","dropdownToggle","dropdownList","newGroupPath","dataset","projectPath","subgroupPath","initDroplab","droplab","drop_lab","getDroplabConfig","onClickNewGroupChildButton","url_utility","GroupTabs","_ref$defaultAction","group_tabs_classCallCheck","user_tabs","constants","loadableActions","enableSearchBar","includes","cleanFilterState","elId","getEndpoint","groups","_$parentEl$data","endpointsDefault","endpointsShared","containerEl","getElementById","dataEl","opts","filterEndpoint","pagePath","dropdownSel","filterInputField","groups_filterable_list","values","newGroupChildWrapper","paths","pathname","subpath","common_utils","group_tabs","shortcuts_navigation","notifications_form","notifications_dropdown","projects_list","new_group_child"],"mappings":"qIAEA,IAAMA,GACJC,KADkB,SACbC,GACHC,KAAKD,KAAOA,EACZC,KAAKC,WAAY,EACjBD,KAAKE,OAASH,EAAKG,OAAOL,cAAgBG,KAAKD,KAAKG,OAAOL,gBAE3DG,KAAKG,gBAELH,KAAKI,aAGPA,UAXkB,WAYhBJ,KAAKG,aAAaE,UAAYL,KAAKK,UAAUC,KAAKN,MAClDA,KAAKD,KAAKQ,KAAKA,KAAKC,iBAAiB,WAAYR,KAAKG,aAAaE,YAGrEI,aAhBkB,WAiBhBT,KAAKD,KAAKQ,KAAKA,KAAKG,oBAAoB,WAAYV,KAAKG,aAAaE,YAGxEA,UApBkB,SAoBRM,GAAG,IAAAC,EAAAZ,KACX,IAAIA,KAAKC,UAAT,CAEA,IAAMY,EAAeF,EAAEG,OAAOC,SAEzBC,MAAMC,QAAQjB,KAAKE,UAASF,KAAKE,QAAUF,KAAKE,SAErDF,KAAKE,OAAOgB,QAAQ,SAAAhB,GAAA,OAAUU,EAAKO,SAASjB,EAAQW,OAGtDM,SA9BkB,SA8BTjB,EAAQW,GACf,IAAMO,EAAQlB,EAAOkB,OAASpB,KAAKD,KAAKsB,QAClCC,EAAWT,EAAaU,aAAarB,EAAOsB,gBAC5CC,EAAiBvB,EAAOuB,eAE9B,OAAIL,EAAMM,aAAaD,GAAwBL,EAAMO,aAAaF,EAAgBH,GAC5D,UAAlBF,EAAMQ,QAA4BR,EAAMS,MAAQP,EAC7CF,EAAMU,YAAcR,GAG7BS,QAxCkB,WAyChB/B,KAAKC,WAAY,EAEjBD,KAAKS,iBAITuB,EAAA,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AAW9O,KAAK+S,YAAYjF,GAElC,GAAKwF,EAAL,CARsB,IAYd1B,EAAY0B,EAAZ1B,QACF2B,GACJlN,OACAT,SACAW,SACAiN,eAAgB1E,GAAY8C,EAAQ9C,SACpC2E,SAAU,KACVC,YAAa,iCACbC,iBAAkB,SAClB7F,UAGF,IAAK9N,KAAKiO,OAAOH,GACQ,IAAI8F,EAAA,EAAoBL,GAChC9M,yDAQjB,GAHe3D,OAAO+Q,OAAO7T,KAAKiO,QACRrI,OAAO,SAAAjF,GAAA,OAAW,IAANA,IAEtBwB,OAAhB,CAIA,IAAMiO,EAAWtN,OAAAsP,EAAA,EAAAtP,EAAc,QAASsB,OAAOgK,SAASkC,QAExDlM,OAAOoM,QAAQC,cAEX7N,IAAKwN,GAEP/L,SAASqM,MACTN,aCzHN/L,SAAS7D,iBAAiB,mBAAoB,WAC5C,IAAMsT,EAAuBzP,SAASiC,cAAc,4BAC9CoM,GAAmBD,EAAA,EAAmBA,EAAA,GACtCsB,EAAQ3P,OAAOgK,SAAS4F,SAASlO,MAAM,KACvCmO,EAAUF,EAAMA,EAAM5R,OAAS,GAC/B2L,EAAS4E,EAAgBE,SAASqB,GAAWA,EAAUnR,OAAAoR,EAAA,EAAApR,CAAY,GAEzE,IAAIqR,GAAYpG,SAAU,kBAAmBD,WAC7C,IAAIsG,EAAA,EACJ,IAAIC,EAAA,EACJvR,OAAAwR,EAAA,EAAAxR,GACA,IAAIyR,EAAA,EAEAT,GACF,IAAIU,EAAcV","file":"pages.groups.show.584e7033.chunk.js","sourcesContent":["/* eslint-disable */\n\nconst InputSetter = {\n init(hook) {\n this.hook = hook;\n this.destroyed = false;\n this.config = hook.config.InputSetter || (this.hook.config.InputSetter = {});\n\n this.eventWrapper = {};\n\n this.addEvents();\n },\n\n addEvents() {\n this.eventWrapper.setInputs = this.setInputs.bind(this);\n this.hook.list.list.addEventListener('click.dl', this.eventWrapper.setInputs);\n },\n\n removeEvents() {\n this.hook.list.list.removeEventListener('click.dl', this.eventWrapper.setInputs);\n },\n\n setInputs(e) {\n if (this.destroyed) return;\n\n const selectedItem = e.detail.selected;\n\n if (!Array.isArray(this.config)) this.config = [this.config];\n\n this.config.forEach(config => this.setInput(config, selectedItem));\n },\n\n setInput(config, selectedItem) {\n const input = config.input || this.hook.trigger;\n const newValue = selectedItem.getAttribute(config.valueAttribute);\n const inputAttribute = config.inputAttribute;\n\n if (input.hasAttribute(inputAttribute)) return input.setAttribute(inputAttribute, newValue);\n if (input.tagName === 'INPUT') return input.value = newValue;\n return input.textContent = newValue;\n },\n\n destroy() {\n this.destroyed = true;\n\n this.removeEvents();\n },\n};\n\nexport default InputSetter;\n","import $ from 'jquery';\nimport { getParameterByName } from '~/lib/utils/common_utils';\nimport axios from './lib/utils/axios_utils';\nimport { removeParams } from './lib/utils/url_utility';\n\nconst ENDLESS_SCROLL_BOTTOM_PX = 400;\nconst ENDLESS_SCROLL_FIRE_DELAY_MS = 1000;\n\nexport default {\n init(limit = 0, preload = false, disable = false, prepareData = $.noop, callback = $.noop) {\n this.url = $('.content_list').data('href') || removeParams(['limit', 'offset']);\n this.limit = limit;\n this.offset = parseInt(getParameterByName('offset'), 10) || this.limit;\n this.disable = disable;\n this.prepareData = prepareData;\n this.callback = callback;\n this.loading = $('.loading').first();\n if (preload) {\n this.offset = 0;\n this.getOld();\n }\n this.initLoadMore();\n },\n\n getOld() {\n this.loading.show();\n axios.get(this.url, {\n params: {\n limit: this.limit,\n offset: this.offset,\n },\n }).then(({ data }) => {\n this.append(data.count, this.prepareData(data.html));\n this.callback();\n\n // keep loading until we've filled the viewport height\n if (!this.disable && !this.isScrollable()) {\n this.getOld();\n } else {\n this.loading.hide();\n }\n }).catch(() => this.loading.hide());\n },\n\n append(count, html) {\n $('.content_list').append(html);\n if (count > 0) {\n this.offset += count;\n } else {\n this.disable = true;\n }\n },\n\n isScrollable() {\n const $w = $(window);\n return $(document).height() > $w.height() + $w.scrollTop() + ENDLESS_SCROLL_BOTTOM_PX;\n },\n\n initLoadMore() {\n $(document).off('scroll');\n $(document).endlessScroll({\n bottomPixels: ENDLESS_SCROLL_BOTTOM_PX,\n fireDelay: ENDLESS_SCROLL_FIRE_DELAY_MS,\n fireOnce: true,\n ceaseFire: () => this.disable === true,\n callback: () => {\n if (!this.loading.is(':visible')) {\n this.loading.show();\n this.getOld();\n }\n },\n });\n },\n};\n","/* eslint-disable class-methods-use-this */\n\nimport $ from 'jquery';\nimport Cookies from 'js-cookie';\nimport Pager from './pager';\nimport { localTimeAgo } from './lib/utils/datetime_utility';\n\nexport default class Activities {\n constructor() {\n Pager.init(20, true, false, data => data, this.updateTooltips);\n\n $('.event-filter-link').on('click', (e) => {\n e.preventDefault();\n this.toggleFilter(e.currentTarget);\n this.reloadActivities();\n });\n }\n\n updateTooltips() {\n localTimeAgo($('.js-timeago', '.content_list'));\n }\n\n reloadActivities() {\n $('.content_list').html('');\n Pager.init(20, true, false, data => data, this.updateTooltips);\n }\n\n toggleFilter(sender) {\n const $sender = $(sender);\n const filter = $sender.attr('id').split('_')[0];\n\n $('.event-filter .active').removeClass('active');\n Cookies.set('event_filter', filter);\n\n $sender.closest('li').toggleClass('active');\n }\n}\n","import FilterableList from './filterable_list';\n\n/**\n * Makes search request for projects when user types a value in the search input.\n * Updates the html content of the page with the received one.\n */\nexport default class ProjectsList {\n constructor() {\n const form = document.querySelector('form#project-filter-form');\n const filter = document.querySelector('.js-projects-list-filter');\n const holder = document.querySelector('.js-projects-list-holder');\n\n if (form && filter && holder) {\n const list = new FilterableList(form, filter, holder);\n list.initSearch();\n }\n }\n}\n","import $ from 'jquery';\nimport { __ } from './locale';\nimport axios from './lib/utils/axios_utils';\nimport flash from './flash';\n\nexport default class NotificationsForm {\n constructor() {\n this.toggleCheckbox = this.toggleCheckbox.bind(this);\n this.initEventListeners();\n }\n\n initEventListeners() {\n $(document).on('change', '.js-custom-notification-event', this.toggleCheckbox);\n }\n\n toggleCheckbox(e) {\n const $checkbox = $(e.currentTarget);\n const $parent = $checkbox.closest('.form-check');\n\n this.saveEvent($checkbox, $parent);\n }\n\n // eslint-disable-next-line class-methods-use-this\n showCheckboxLoadingSpinner($parent) {\n $parent.addClass('is-loading')\n .find('.custom-notification-event-loading')\n .removeClass('fa-check')\n .addClass('fa-spin fa-spinner')\n .removeClass('is-done');\n }\n\n saveEvent($checkbox, $parent) {\n const form = $parent.parents('form:first');\n\n this.showCheckboxLoadingSpinner($parent);\n\n axios[form.attr('method')](form.attr('action'), form.serialize())\n .then(({ data }) => {\n $checkbox.enable();\n if (data.saved) {\n $parent.find('.custom-notification-event-loading').toggleClass('fa-spin fa-spinner fa-check is-done');\n setTimeout(() => {\n $parent.removeClass('is-loading')\n .find('.custom-notification-event-loading')\n .toggleClass('fa-spin fa-spinner fa-check is-done');\n }, 2000);\n }\n })\n .catch(() => flash(__('There was an error saving your notification settings.')));\n }\n}\n","import $ from 'jquery';\nimport Flash from './flash';\n\nexport default function notificationsDropdown() {\n $(document).on('click', '.update-notification', function updateNotificationCallback(e) {\n e.preventDefault();\n if ($(this).is('.is-active') && $(this).data('notificationLevel') === 'custom') {\n return;\n }\n\n const notificationLevel = $(this).data('notificationLevel');\n const form = $(this).parents('.notification-form:first');\n\n form.find('.js-notification-loading').toggleClass('fa-bell fa-spin fa-spinner');\n form.find('#notification_setting_level').val(notificationLevel);\n form.submit();\n });\n\n $(document).on('ajax:success', '.notification-form', (e, data) => {\n if (data.saved) {\n $(e.currentTarget).closest('.js-notification-dropdown').replaceWith(data.html);\n } else {\n Flash('Failed to save new settings', 'alert');\n }\n });\n}\n","import $ from 'jquery';\nimport _ from 'underscore';\nimport { scaleLinear, scaleThreshold } from 'd3-scale';\nimport { select } from 'd3-selection';\nimport dateFormat from 'dateformat';\nimport { getDayName, getDayDifference } from '~/lib/utils/datetime_utility';\nimport axios from '~/lib/utils/axios_utils';\nimport flash from '~/flash';\nimport { __ } from '~/locale';\n\nconst d3 = { select, scaleLinear, scaleThreshold };\n\nconst LOADING_HTML = `\n
\n \n
\n`;\n\nfunction getSystemDate(systemUtcOffsetSeconds) {\n const date = new Date();\n const localUtcOffsetMinutes = 0 - date.getTimezoneOffset();\n const systemUtcOffsetMinutes = systemUtcOffsetSeconds / 60;\n date.setMinutes(date.getMinutes() - localUtcOffsetMinutes + systemUtcOffsetMinutes);\n return date;\n}\n\nfunction formatTooltipText({ date, count }) {\n const dateObject = new Date(date);\n const dateDayName = getDayName(dateObject);\n const dateText = dateFormat(dateObject, 'mmm d, yyyy');\n\n let contribText = '没有贡献';\n if (count > 0) {\n contribText = `${count} 次贡献`;\n }\n return `${contribText}
${dateDayName} ${dateText}`;\n}\n\nconst initColorKey = () =>\n d3\n .scaleLinear()\n .range(['#acd5f2', '#254e77'])\n .domain([0, 3]);\n\nexport default class ActivityCalendar {\n constructor(container, timestamps, calendarActivitiesPath, utcOffset = 0, firstDayOfWeek = 0) {\n this.calendarActivitiesPath = calendarActivitiesPath;\n this.clickDay = this.clickDay.bind(this);\n this.currentSelectedDate = '';\n this.daySpace = 1;\n this.daySize = 15;\n this.daySizeWithSpace = this.daySize + this.daySpace * 2;\n this.monthNames = [\n 'Jan',\n 'Feb',\n 'Mar',\n 'Apr',\n 'May',\n 'Jun',\n 'Jul',\n 'Aug',\n 'Sep',\n 'Oct',\n 'Nov',\n 'Dec',\n ];\n this.months = [];\n this.firstDayOfWeek = firstDayOfWeek;\n\n // Loop through the timestamps to create a group of objects\n // The group of objects will be grouped based on the day of the week they are\n this.timestampsTmp = [];\n let group = 0;\n\n const today = getSystemDate(utcOffset);\n today.setHours(0, 0, 0, 0, 0);\n\n const oneYearAgo = new Date(today);\n oneYearAgo.setFullYear(today.getFullYear() - 1);\n\n const days = getDayDifference(oneYearAgo, today);\n\n for (let i = 0; i <= days; i += 1) {\n const date = new Date(oneYearAgo);\n date.setDate(date.getDate() + i);\n\n const day = date.getDay();\n const count = timestamps[dateFormat(date, 'yyyy-mm-dd')] || 0;\n\n // Create a new group array if this is the first day of the week\n // or if is first object\n if ((day === this.firstDayOfWeek && i !== 0) || i === 0) {\n this.timestampsTmp.push([]);\n group += 1;\n }\n\n // Push to the inner array the values that will be used to render map\n const innerArray = this.timestampsTmp[group - 1];\n innerArray.push({ count, date, day });\n }\n\n // Init color functions\n this.colorKey = initColorKey();\n this.color = this.initColor();\n\n // Init the svg element\n this.svg = this.renderSvg(container, group);\n this.renderDays();\n this.renderMonths();\n this.renderDayTitles();\n this.renderKey();\n\n // Init tooltips\n $(`${container} .js-tooltip`).tooltip({ html: true });\n }\n\n // Add extra padding for the last month label if it is also the last column\n getExtraWidthPadding(group) {\n let extraWidthPadding = 0;\n const lastColMonth = this.timestampsTmp[group - 1][0].date.getMonth();\n const secondLastColMonth = this.timestampsTmp[group - 2][0].date.getMonth();\n\n if (lastColMonth !== secondLastColMonth) {\n extraWidthPadding = 6;\n }\n\n return extraWidthPadding;\n }\n\n renderSvg(container, group) {\n const width = (group + 1) * this.daySizeWithSpace + this.getExtraWidthPadding(group);\n return d3\n .select(container)\n .append('svg')\n .attr('width', width)\n .attr('height', 167)\n .attr('class', 'contrib-calendar');\n }\n\n dayYPos(day) {\n return this.daySizeWithSpace * ((day + 7 - this.firstDayOfWeek) % 7);\n }\n\n renderDays() {\n this.svg\n .selectAll('g')\n .data(this.timestampsTmp)\n .enter()\n .append('g')\n .attr('transform', (group, i) => {\n _.each(group, (stamp, a) => {\n if (a === 0 && stamp.day === 0) {\n const month = stamp.date.getMonth();\n const x = this.daySizeWithSpace * i + 1 + this.daySizeWithSpace;\n const lastMonth = _.last(this.months);\n if (\n lastMonth == null ||\n (month !== lastMonth.month && x - this.daySizeWithSpace !== lastMonth.x)\n ) {\n this.months.push({ month, x });\n }\n }\n });\n return `translate(${this.daySizeWithSpace * i + 1 + this.daySizeWithSpace}, 18)`;\n })\n .selectAll('rect')\n .data(stamp => stamp)\n .enter()\n .append('rect')\n .attr('x', '0')\n .attr('y', stamp => this.dayYPos(stamp.day))\n .attr('width', this.daySize)\n .attr('height', this.daySize)\n .attr(\n 'fill',\n stamp => (stamp.count !== 0 ? this.color(Math.min(stamp.count, 40)) : '#ededed'),\n )\n .attr('title', stamp => formatTooltipText(stamp))\n .attr('class', 'user-contrib-cell js-tooltip')\n .attr('data-container', 'body')\n .on('click', this.clickDay);\n }\n\n renderDayTitles() {\n const days = [\n {\n text: 'M',\n y: 29 + this.dayYPos(1),\n },\n {\n text: 'W',\n y: 29 + this.dayYPos(3),\n },\n {\n text: 'F',\n y: 29 + this.dayYPos(5),\n },\n ];\n this.svg\n .append('g')\n .selectAll('text')\n .data(days)\n .enter()\n .append('text')\n .attr('text-anchor', 'middle')\n .attr('x', 8)\n .attr('y', day => day.y)\n .text(day => day.text)\n .attr('class', 'user-contrib-text');\n }\n\n renderMonths() {\n this.svg\n .append('g')\n .attr('direction', 'ltr')\n .selectAll('text')\n .data(this.months)\n .enter()\n .append('text')\n .attr('x', date => date.x)\n .attr('y', 10)\n .attr('class', 'user-contrib-text')\n .text(date => this.monthNames[date.month]);\n }\n\n renderKey() {\n const keyValues = [\n 'no contributions',\n '1-9 contributions',\n '10-19 contributions',\n '20-29 contributions',\n '30+ contributions',\n ];\n const keyColors = [\n '#ededed',\n this.colorKey(0),\n this.colorKey(1),\n this.colorKey(2),\n this.colorKey(3),\n ];\n\n this.svg\n .append('g')\n .attr('transform', `translate(18, ${this.daySizeWithSpace * 8 + 16})`)\n .selectAll('rect')\n .data(keyColors)\n .enter()\n .append('rect')\n .attr('width', this.daySize)\n .attr('height', this.daySize)\n .attr('x', (color, i) => this.daySizeWithSpace * i)\n .attr('y', 0)\n .attr('fill', color => color)\n .attr('class', 'js-tooltip')\n .attr('title', (color, i) => keyValues[i])\n .attr('data-container', 'body');\n }\n\n initColor() {\n const colorRange = [\n '#ededed',\n this.colorKey(0),\n this.colorKey(1),\n this.colorKey(2),\n this.colorKey(3),\n ];\n return d3\n .scaleThreshold()\n .domain([0, 10, 20, 30])\n .range(colorRange);\n }\n\n clickDay(stamp) {\n if (this.currentSelectedDate !== stamp.date) {\n this.currentSelectedDate = stamp.date;\n\n const date = [\n this.currentSelectedDate.getFullYear(),\n this.currentSelectedDate.getMonth() + 1,\n this.currentSelectedDate.getDate(),\n ].join('-');\n\n $('.user-calendar-activities').html(LOADING_HTML);\n\n axios\n .get(this.calendarActivitiesPath, {\n params: {\n date,\n },\n responseType: 'text',\n })\n .then(({ data }) => $('.user-calendar-activities').html(data))\n .catch(() => flash(__('An error occurred while retrieving calendar activity')));\n } else {\n this.currentSelectedDate = '';\n $('.user-calendar-activities').html('');\n }\n }\n}\n","import $ from 'jquery';\nimport axios from '~/lib/utils/axios_utils';\nimport Activities from '~/activities';\nimport { localTimeAgo } from '~/lib/utils/datetime_utility';\nimport { __ } from '~/locale';\nimport flash from '~/flash';\nimport ActivityCalendar from './activity_calendar';\n\n/**\n * UserTabs\n *\n * Handles persisting and restoring the current tab selection and lazily-loading\n * content on the Users#show page.\n *\n * ### Example Markup\n *\n * \n *\n *
\n *
\n * Activity Content\n *
\n *
\n * Groups Content\n *
\n *
\n * Contributed projects content\n *
\n *
\n * Projects content\n *
\n *
\n * Snippets content\n *
\n *
\n *\n *
\n *
\n * Loading Animation\n *
\n *
\n */\n\nconst CALENDAR_TEMPLATE = `\n
\n
\n
\n 问题、合并请求、推送事件和评论摘要\n
\n
\n`;\n\nexport default class UserTabs {\n constructor({ defaultAction, action, parentEl }) {\n this.loaded = {};\n this.defaultAction = defaultAction || 'activity';\n this.action = action || this.defaultAction;\n this.$parentEl = $(parentEl) || $(document);\n this.windowLocation = window.location;\n this.$parentEl.find('.nav-links a').each((i, navLink) => {\n this.loaded[$(navLink).attr('data-action')] = false;\n });\n this.actions = Object.keys(this.loaded);\n this.bindEvents();\n\n if (this.action === 'show') {\n this.action = this.defaultAction;\n }\n\n this.activateTab(this.action);\n }\n\n bindEvents() {\n this.$parentEl\n .off('shown.bs.tab', '.nav-links a[data-toggle=\"tab\"]')\n .on('shown.bs.tab', '.nav-links a[data-toggle=\"tab\"]', event => this.tabShown(event))\n .on('click', '.gl-pagination a', event => this.changeProjectsPage(event));\n }\n\n changeProjectsPage(e) {\n e.preventDefault();\n\n $('.tab-pane.active').empty();\n const endpoint = $(e.target).attr('href');\n this.loadTab(this.getCurrentAction(), endpoint);\n }\n\n tabShown(event) {\n const $target = $(event.target);\n const action = $target.data('action');\n const source = $target.attr('href');\n const endpoint = $target.data('endpoint');\n this.setTab(action, endpoint);\n return this.setCurrentAction(source);\n }\n\n activateTab(action) {\n return this.$parentEl.find(`.nav-links .js-${action}-tab a`).tab('show');\n }\n\n setTab(action, endpoint) {\n if (this.loaded[action]) {\n return;\n }\n if (action === 'activity') {\n this.loadActivities();\n }\n\n const loadableActions = ['groups', 'contributed', 'projects', 'snippets'];\n if (loadableActions.indexOf(action) > -1) {\n this.loadTab(action, endpoint);\n }\n }\n\n loadTab(action, endpoint) {\n this.toggleLoading(true);\n\n return axios\n .get(endpoint)\n .then(({ data }) => {\n const tabSelector = `div#${action}`;\n this.$parentEl.find(tabSelector).html(data.html);\n this.loaded[action] = true;\n localTimeAgo($('.js-timeago', tabSelector));\n\n this.toggleLoading(false);\n })\n .catch(() => {\n this.toggleLoading(false);\n });\n }\n\n loadActivities() {\n if (this.loaded.activity) {\n return;\n }\n const $calendarWrap = this.$parentEl.find('.user-calendar');\n const calendarPath = $calendarWrap.data('calendarPath');\n const calendarActivitiesPath = $calendarWrap.data('calendarActivitiesPath');\n const utcOffset = $calendarWrap.data('utcOffset');\n let utcFormatted = 'UTC';\n if (utcOffset !== 0) {\n utcFormatted = `UTC${utcOffset > 0 ? '+' : ''}${utcOffset / 3600}`;\n }\n\n axios\n .get(calendarPath)\n .then(({ data }) => {\n $calendarWrap.html(CALENDAR_TEMPLATE);\n $calendarWrap.find('.calendar-hint').append(`(Timezone: ${utcFormatted})`);\n\n // eslint-disable-next-line no-new\n new ActivityCalendar('.js-contrib-calendar', data, calendarActivitiesPath, utcOffset);\n })\n .catch(() => flash(__('There was an error loading users activity calendar.')));\n\n // eslint-disable-next-line no-new\n new Activities();\n this.loaded.activity = true;\n }\n\n toggleLoading(status) {\n return this.$parentEl.find('.loading-status .loading').toggleClass('hide', !status);\n }\n\n setCurrentAction(source) {\n let newState = source;\n newState = newState.replace(/\\/+$/, '');\n newState += this.windowLocation.search + this.windowLocation.hash;\n window.history.replaceState(\n {\n url: newState,\n },\n document.title,\n newState,\n );\n return newState;\n }\n\n getCurrentAction() {\n return this.$parentEl.find('.nav-links a.active').data('action');\n }\n}\n","import Mousetrap from 'mousetrap';\nimport findAndFollowLink from './shortcuts_dashboard_navigation';\nimport Shortcuts from './shortcuts';\n\nexport default class ShortcutsNavigation extends Shortcuts {\n constructor() {\n super();\n\n Mousetrap.bind('g p', () => findAndFollowLink('.shortcuts-project'));\n Mousetrap.bind('g v', () => findAndFollowLink('.shortcuts-project-activity'));\n Mousetrap.bind('g f', () => findAndFollowLink('.shortcuts-tree'));\n Mousetrap.bind('g c', () => findAndFollowLink('.shortcuts-commits'));\n Mousetrap.bind('g j', () => findAndFollowLink('.shortcuts-builds'));\n Mousetrap.bind('g n', () => findAndFollowLink('.shortcuts-network'));\n Mousetrap.bind('g d', () => findAndFollowLink('.shortcuts-repository-charts'));\n Mousetrap.bind('g i', () => findAndFollowLink('.shortcuts-issues'));\n Mousetrap.bind('g b', () => findAndFollowLink('.shortcuts-issue-boards'));\n Mousetrap.bind('g m', () => findAndFollowLink('.shortcuts-merge_requests'));\n Mousetrap.bind('g w', () => findAndFollowLink('.shortcuts-wiki'));\n Mousetrap.bind('g s', () => findAndFollowLink('.shortcuts-snippets'));\n Mousetrap.bind('g k', () => findAndFollowLink('.shortcuts-kubernetes'));\n Mousetrap.bind('g e', () => findAndFollowLink('.shortcuts-environments'));\n Mousetrap.bind('g l', () => findAndFollowLink('.shortcuts-metrics'));\n Mousetrap.bind('i', () => findAndFollowLink('.shortcuts-new-issue'));\n\n this.enabledHelp.push('.hidden-shortcut.project');\n }\n}\n","import { visitUrl } from '../lib/utils/url_utility';\nimport DropLab from '../droplab/drop_lab';\nimport ISetter from '../droplab/plugins/input_setter';\n\nconst InputSetter = Object.assign({}, ISetter);\n\nconst NEW_PROJECT = 'new-project';\nconst NEW_SUBGROUP = 'new-subgroup';\n\nexport default class NewGroupChild {\n constructor(buttonWrapper) {\n this.buttonWrapper = buttonWrapper;\n this.newGroupChildButton = this.buttonWrapper.querySelector('.js-new-group-child');\n this.dropdownToggle = this.buttonWrapper.querySelector('.js-dropdown-toggle');\n this.dropdownList = this.buttonWrapper.querySelector('.dropdown-menu');\n\n this.newGroupPath = this.buttonWrapper.dataset.projectPath;\n this.subgroupPath = this.buttonWrapper.dataset.subgroupPath;\n\n this.init();\n }\n\n init() {\n this.initDroplab();\n this.bindEvents();\n }\n\n initDroplab() {\n this.droplab = new DropLab();\n this.droplab.init(\n this.dropdownToggle,\n this.dropdownList,\n [InputSetter],\n this.getDroplabConfig(),\n );\n }\n\n getDroplabConfig() {\n return {\n InputSetter: [{\n input: this.newGroupChildButton,\n valueAttribute: 'data-value',\n inputAttribute: 'data-action',\n }, {\n input: this.newGroupChildButton,\n valueAttribute: 'data-text',\n }],\n };\n }\n\n bindEvents() {\n this.newGroupChildButton\n .addEventListener('click', this.onClickNewGroupChildButton.bind(this));\n }\n\n onClickNewGroupChildButton(e) {\n if (e.target.dataset.action === NEW_PROJECT) {\n visitUrl(this.newGroupPath);\n } else if (e.target.dataset.action === NEW_SUBGROUP) {\n visitUrl(this.subgroupPath);\n }\n }\n}\n","import $ from 'jquery';\nimport { removeParams } from '~/lib/utils/url_utility';\nimport createGroupTree from '~/groups';\nimport {\n ACTIVE_TAB_SUBGROUPS_AND_PROJECTS,\n ACTIVE_TAB_SHARED,\n ACTIVE_TAB_ARCHIVED,\n CONTENT_LIST_CLASS,\n GROUPS_LIST_HOLDER_CLASS,\n GROUPS_FILTER_FORM_CLASS,\n} from '~/groups/constants';\nimport UserTabs from '~/pages/users/user_tabs';\nimport GroupFilterableList from '~/groups/groups_filterable_list';\n\nexport default class GroupTabs extends UserTabs {\n constructor({ defaultAction = 'subgroups_and_projects', action, parentEl }) {\n super({ defaultAction, action, parentEl });\n }\n\n bindEvents() {\n this.$parentEl\n .off('shown.bs.tab', '.nav-links a[data-toggle=\"tab\"]')\n .on('shown.bs.tab', '.nav-links a[data-toggle=\"tab\"]', event => this.tabShown(event));\n }\n\n tabShown(event) {\n const $target = $(event.target);\n const action = $target.data('action') || $target.data('targetSection');\n const source = $target.attr('href') || $target.data('targetPath');\n\n document.querySelector(GROUPS_FILTER_FORM_CLASS).action = source;\n\n this.setTab(action);\n return this.setCurrentAction(source);\n }\n\n setTab(action) {\n const loadableActions = [\n ACTIVE_TAB_SUBGROUPS_AND_PROJECTS,\n ACTIVE_TAB_SHARED,\n ACTIVE_TAB_ARCHIVED,\n ];\n this.enableSearchBar(action);\n this.action = action;\n\n if (this.loaded[action]) {\n return;\n }\n\n if (loadableActions.includes(action)) {\n this.cleanFilterState();\n this.loadTab(action);\n }\n }\n\n loadTab(action) {\n const elId = `js-groups-${action}-tree`;\n const endpoint = this.getEndpoint(action);\n\n this.toggleLoading(true);\n\n createGroupTree(elId, endpoint, action);\n this.loaded[action] = true;\n\n this.toggleLoading(false);\n }\n\n getEndpoint(action) {\n const { endpointsDefault, endpointsShared } = this.$parentEl.data();\n let endpoint;\n\n switch (action) {\n case ACTIVE_TAB_ARCHIVED:\n endpoint = `${endpointsDefault}?archived=only`;\n break;\n case ACTIVE_TAB_SHARED:\n endpoint = endpointsShared;\n break;\n default:\n // ACTIVE_TAB_SUBGROUPS_AND_PROJECTS\n endpoint = endpointsDefault;\n break;\n }\n\n return endpoint;\n }\n\n enableSearchBar(action) {\n const containerEl = document.getElementById(action);\n const form = document.querySelector(GROUPS_FILTER_FORM_CLASS);\n const filter = form.querySelector('.js-groups-list-filter');\n const holder = containerEl.querySelector(GROUPS_LIST_HOLDER_CLASS);\n const dataEl = containerEl.querySelector(CONTENT_LIST_CLASS);\n const endpoint = this.getEndpoint(action);\n\n if (!dataEl) {\n return;\n }\n\n const { dataset } = dataEl;\n const opts = {\n form,\n filter,\n holder,\n filterEndpoint: endpoint || dataset.endpoint,\n pagePath: null,\n dropdownSel: '.js-group-filter-dropdown-wrap',\n filterInputField: 'filter',\n action,\n };\n\n if (!this.loaded[action]) {\n const filterableList = new GroupFilterableList(opts);\n filterableList.initSearch();\n }\n }\n\n cleanFilterState() {\n const values = Object.values(this.loaded);\n const loadedTabs = values.filter(e => e === true);\n\n if (!loadedTabs.length) {\n return;\n }\n\n const newState = removeParams(['page'], window.location.search);\n\n window.history.replaceState(\n {\n url: newState,\n },\n document.title,\n newState,\n );\n }\n}\n","/* eslint-disable no-new */\n\nimport { getPagePath } from '~/lib/utils/common_utils';\nimport { ACTIVE_TAB_SHARED, ACTIVE_TAB_ARCHIVED } from '~/groups/constants';\nimport NewGroupChild from '~/groups/new_group_child';\nimport notificationsDropdown from '~/notifications_dropdown';\nimport NotificationsForm from '~/notifications_form';\nimport ProjectsList from '~/projects_list';\nimport ShortcutsNavigation from '~/shortcuts_navigation';\nimport GroupTabs from './group_tabs';\n\ndocument.addEventListener('DOMContentLoaded', () => {\n const newGroupChildWrapper = document.querySelector('.js-new-project-subgroup');\n const loadableActions = [ACTIVE_TAB_SHARED, ACTIVE_TAB_ARCHIVED];\n const paths = window.location.pathname.split('/');\n const subpath = paths[paths.length - 1];\n const action = loadableActions.includes(subpath) ? subpath : getPagePath(1);\n\n new GroupTabs({ parentEl: '.groups-listing', action });\n new ShortcutsNavigation();\n new NotificationsForm();\n notificationsDropdown();\n new ProjectsList();\n\n if (newGroupChildWrapper) {\n new NewGroupChild(newGroupChildWrapper);\n }\n});\n"],"sourceRoot":""}