diff options
author | hellekin <hellekin@cepheide.org> | 2021-01-22 05:32:15 +0100 |
---|---|---|
committer | hellekin <hellekin@cepheide.org> | 2021-01-22 05:32:15 +0100 |
commit | b54a8458d5029b3494165b7430e21b3ae34ecc0c (patch) | |
tree | 32ea6fc6b8774f672325fec52f0ffc97229a9568 | |
parent | 1c1aead78192982e221179de6688b944e5b01bf6 (diff) | |
download | incommon-map-b54a8458d5029b3494165b7430e21b3ae34ecc0c.tar.gz |
Upgrade Rails and add StimulusJS support
68 files changed, 1103 insertions, 277 deletions
diff --git a/.ruby-version b/.ruby-version index 338a5b5..c57e1bc 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1,2 @@ -2.6.6 +2.7.2 + @@ -1,10 +1,10 @@ source 'https://rubygems.org' git_source(:github) { |repo| "https://github.com/#{repo}.git" } -ruby '2.6.6' +ruby '2.7.2' # Bundle edge Rails instead: gem 'rails', github: 'rails/rails' -gem 'rails', '~> 6.0.3', '>= 6.0.3.2' +gem 'rails', '~> 6.1.0' # Use postgresql as the database for Active Record gem 'pg', '>= 0.18', '< 2.0' # Use Puma as the app server @@ -34,8 +34,8 @@ gem 'commonmarker' gem 'discourse_api' # User pagination gem 'kaminari' -# Use of Leaflet maps -gem 'leaflet-rails' +# Enhance SEO +gem 'meta-tags' # Validate phone numbers gem 'phony_rails' # Enforce stable UUIDs for models diff --git a/Gemfile.lock b/Gemfile.lock index 9d940e0..7dd197c 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,61 +1,65 @@ GEM remote: https://rubygems.org/ specs: - actioncable (6.0.3.3) - actionpack (= 6.0.3.3) + actioncable (6.1.1) + actionpack (= 6.1.1) + activesupport (= 6.1.1) nio4r (~> 2.0) websocket-driver (>= 0.6.1) - actionmailbox (6.0.3.3) - actionpack (= 6.0.3.3) - activejob (= 6.0.3.3) - activerecord (= 6.0.3.3) - activestorage (= 6.0.3.3) - activesupport (= 6.0.3.3) + actionmailbox (6.1.1) + actionpack (= 6.1.1) + activejob (= 6.1.1) + activerecord (= 6.1.1) + activestorage (= 6.1.1) + activesupport (= 6.1.1) mail (>= 2.7.1) - actionmailer (6.0.3.3) - actionpack (= 6.0.3.3) - actionview (= 6.0.3.3) - activejob (= 6.0.3.3) + actionmailer (6.1.1) + actionpack (= 6.1.1) + actionview (= 6.1.1) + activejob (= 6.1.1) + activesupport (= 6.1.1) mail (~> 2.5, >= 2.5.4) rails-dom-testing (~> 2.0) - actionpack (6.0.3.3) - actionview (= 6.0.3.3) - activesupport (= 6.0.3.3) - rack (~> 2.0, >= 2.0.8) + actionpack (6.1.1) + actionview (= 6.1.1) + activesupport (= 6.1.1) + rack (~> 2.0, >= 2.0.9) rack-test (>= 0.6.3) rails-dom-testing (~> 2.0) rails-html-sanitizer (~> 1.0, >= 1.2.0) - actiontext (6.0.3.3) - actionpack (= 6.0.3.3) - activerecord (= 6.0.3.3) - activestorage (= 6.0.3.3) - activesupport (= 6.0.3.3) + actiontext (6.1.1) + actionpack (= 6.1.1) + activerecord (= 6.1.1) + activestorage (= 6.1.1) + activesupport (= 6.1.1) nokogiri (>= 1.8.5) - actionview (6.0.3.3) - activesupport (= 6.0.3.3) + actionview (6.1.1) + activesupport (= 6.1.1) builder (~> 3.1) erubi (~> 1.4) rails-dom-testing (~> 2.0) rails-html-sanitizer (~> 1.1, >= 1.2.0) - activejob (6.0.3.3) - activesupport (= 6.0.3.3) + activejob (6.1.1) + activesupport (= 6.1.1) globalid (>= 0.3.6) - activemodel (6.0.3.3) - activesupport (= 6.0.3.3) - activerecord (6.0.3.3) - activemodel (= 6.0.3.3) - activesupport (= 6.0.3.3) - activestorage (6.0.3.3) - actionpack (= 6.0.3.3) - activejob (= 6.0.3.3) - activerecord (= 6.0.3.3) + activemodel (6.1.1) + activesupport (= 6.1.1) + activerecord (6.1.1) + activemodel (= 6.1.1) + activesupport (= 6.1.1) + activestorage (6.1.1) + actionpack (= 6.1.1) + activejob (= 6.1.1) + activerecord (= 6.1.1) + activesupport (= 6.1.1) marcel (~> 0.3.1) - activesupport (6.0.3.3) + mimemagic (~> 0.3.2) + activesupport (6.1.1) concurrent-ruby (~> 1.0, >= 1.0.2) - i18n (>= 0.7, < 2) - minitest (~> 5.1) - tzinfo (~> 1.1) - zeitwerk (~> 2.2, >= 2.2.2) + i18n (>= 1.6, < 2) + minitest (>= 5.1) + tzinfo (~> 2.0) + zeitwerk (~> 2.3) acts_as_list (1.0.2) activerecord (>= 4.2) bindex (0.8.1) @@ -68,13 +72,13 @@ GEM coderay (1.1.3) commonmarker (0.21.0) ruby-enum (~> 0.5) - concurrent-ruby (1.1.7) + concurrent-ruby (1.1.8) crass (1.0.6) discourse_api (0.42.0) faraday (~> 1.0) faraday_middleware (~> 1.0) rack (>= 1.6) - erubi (1.9.0) + erubi (1.10.0) faraday (1.0.1) multipart-post (>= 1.2, < 3) faraday_middleware (1.0.0) @@ -82,7 +86,7 @@ GEM ffi (1.13.1) globalid (0.4.2) activesupport (>= 4.2.0) - i18n (1.8.5) + i18n (1.8.7) concurrent-ruby (~> 1.0) jbuilder (2.10.1) activesupport (>= 5.0.0) @@ -99,28 +103,29 @@ GEM activerecord kaminari-core (= 1.2.1) kaminari-core (1.2.1) - leaflet-rails (1.7.0) - rails (>= 4.2.0) listen (3.2.1) rb-fsevent (~> 0.10, >= 0.10.3) rb-inotify (~> 0.9, >= 0.9.10) - loofah (2.7.0) + loofah (2.9.0) crass (~> 1.0.2) nokogiri (>= 1.5.9) mail (2.7.1) mini_mime (>= 0.1.1) marcel (0.3.3) mimemagic (~> 0.3.2) + meta-tags (2.14.0) + actionpack (>= 3.2.0, < 6.2) method_source (1.0.0) mimemagic (0.3.5) mini_mime (1.0.2) - mini_portile2 (2.4.0) - minitest (5.14.2) + mini_portile2 (2.5.0) + minitest (5.14.3) msgpack (1.3.3) multipart-post (2.1.1) nio4r (2.5.4) - nokogiri (1.10.10) - mini_portile2 (~> 2.4.0) + nokogiri (1.11.1) + mini_portile2 (~> 2.5.0) + racc (~> 1.4) pg (1.2.3) phony (2.18.15) phony_rails (0.14.13) @@ -137,38 +142,39 @@ GEM puma-plugin-systemd (0.1.5) json puma (>= 3.6, < 5) + racc (1.5.2) rack (2.2.3) rack-proxy (0.6.5) rack rack-test (1.1.0) rack (>= 1.0, < 3) - rails (6.0.3.3) - actioncable (= 6.0.3.3) - actionmailbox (= 6.0.3.3) - actionmailer (= 6.0.3.3) - actionpack (= 6.0.3.3) - actiontext (= 6.0.3.3) - actionview (= 6.0.3.3) - activejob (= 6.0.3.3) - activemodel (= 6.0.3.3) - activerecord (= 6.0.3.3) - activestorage (= 6.0.3.3) - activesupport (= 6.0.3.3) - bundler (>= 1.3.0) - railties (= 6.0.3.3) + rails (6.1.1) + actioncable (= 6.1.1) + actionmailbox (= 6.1.1) + actionmailer (= 6.1.1) + actionpack (= 6.1.1) + actiontext (= 6.1.1) + actionview (= 6.1.1) + activejob (= 6.1.1) + activemodel (= 6.1.1) + activerecord (= 6.1.1) + activestorage (= 6.1.1) + activesupport (= 6.1.1) + bundler (>= 1.15.0) + railties (= 6.1.1) sprockets-rails (>= 2.0.0) rails-dom-testing (2.0.3) activesupport (>= 4.2.0) nokogiri (>= 1.6) rails-html-sanitizer (1.3.0) loofah (~> 2.3) - railties (6.0.3.3) - actionpack (= 6.0.3.3) - activesupport (= 6.0.3.3) + railties (6.1.1) + actionpack (= 6.1.1) + activesupport (= 6.1.1) method_source rake (>= 0.8.7) - thor (>= 0.20.3, < 2.0) - rake (13.0.1) + thor (~> 1.0) + rake (13.0.3) rb-fsevent (0.10.4) rb-inotify (0.10.1) ffi (~> 1.0) @@ -195,14 +201,13 @@ GEM actionpack (>= 4.0) activesupport (>= 4.0) sprockets (>= 3.0.0) - thor (1.0.1) - thread_safe (0.3.6) + thor (1.1.0) tilt (2.0.10) turbolinks (5.2.1) turbolinks-source (~> 5.2) turbolinks-source (5.2.0) - tzinfo (1.2.7) - thread_safe (~> 0.1) + tzinfo (2.0.4) + concurrent-ruby (~> 1.0) uuid_parameter (0.2.6) rails (>= 5.2.1) validate_url (1.0.13) @@ -220,7 +225,7 @@ GEM websocket-driver (0.7.3) websocket-extensions (>= 0.1.0) websocket-extensions (0.1.5) - zeitwerk (2.4.0) + zeitwerk (2.4.2) PLATFORMS ruby @@ -234,15 +239,15 @@ DEPENDENCIES discourse_api jbuilder (~> 2.7) kaminari - leaflet-rails listen (~> 3.2) + meta-tags pg (>= 0.18, < 2.0) phony_rails pry pry-rails puma (~> 4.1) puma-plugin-systemd - rails (~> 6.0.3, >= 6.0.3.2) + rails (~> 6.1.0) sass-rails (>= 6) spring spring-watcher-listen (~> 2.0.0) @@ -254,7 +259,7 @@ DEPENDENCIES webpacker (~> 4.0) RUBY VERSION - ruby 2.6.6p146 + ruby 2.7.2p137 BUNDLED WITH 2.1.4 diff --git a/app/assets/stylesheets/application.css b/app/assets/stylesheets/application.scss index d05ea0f..94d00ec 100644 --- a/app/assets/stylesheets/application.css +++ b/app/assets/stylesheets/application.scss @@ -10,6 +10,12 @@ * files in this directory. Styles in this file should be added after the last require_* statement. * It is generally better to create a new file per style scope. * - *= require_tree . + *= require normalize.css/normalize.css *= require_self + *= require leaflet + *= require leaflet-defaulticon-compatibility/dist/leaflet-defaulticon-compatibility.webpack.css + *= require leaflet.markercluster/dist/MarkerCluster.css + *= require leaflet.markercluster/dist/MarkerCluster.Default.css + *= require_tree . + * */ diff --git a/app/assets/stylesheets/sections.scss b/app/assets/stylesheets/sections.scss new file mode 100644 index 0000000..d540c09 --- /dev/null +++ b/app/assets/stylesheets/sections.scss @@ -0,0 +1,3 @@ +// Place all the styles related to the sections controller here. +// They will automatically be included in application.css. +// You can use Sass (SCSS) here: https://sass-lang.com/ diff --git a/app/assets/stylesheets/taxonomies.scss b/app/assets/stylesheets/taxonomies.scss index 4e227da..b1fabcd 100644 --- a/app/assets/stylesheets/taxonomies.scss +++ b/app/assets/stylesheets/taxonomies.scss @@ -68,9 +68,11 @@ button[data-action="taxonomy#toggle"] { font-weight: bold; ol { display: block; + z-index: 1002; } li.active { text-align: right; + z-index: 1002; } } diff --git a/app/controllers/categories_controller.rb b/app/controllers/categories_controller.rb index 40f1ff5..da8d837 100644 --- a/app/controllers/categories_controller.rb +++ b/app/controllers/categories_controller.rb @@ -10,6 +10,11 @@ class CategoriesController < ApplicationController def show @category = Category.find(params[:id]) + + respond_to do |format| + format.html + format.js + end end def edit diff --git a/app/controllers/sections_controller.rb b/app/controllers/sections_controller.rb new file mode 100644 index 0000000..fed1d57 --- /dev/null +++ b/app/controllers/sections_controller.rb @@ -0,0 +1,16 @@ +# SPDX-FileCopyrightText: 2020 IN COMMON Collective <collective@incommon.cc> +# +# SPDX-License-Identifier: AGPL-3.0-or-later + +class SectionsController < ApplicationController + skip_before_action :verify_authenticity_token, only: :show + + def show + @section = Section.find(params[:id]) + respond_to do |format| + format.html + format.js + format.json + end + end +end diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb index 9a3cf74..f0479d1 100644 --- a/app/controllers/users_controller.rb +++ b/app/controllers/users_controller.rb @@ -3,18 +3,9 @@ # SPDX-License-Identifier: AGPL-3.0-or-later class UsersController < ApplicationController - # GET /my/users - # If you're a leader, you will see a list of Agent members + # GET /my/peers def index - begin - return 403 unless current_user.agencies.find_by(name: current_agent).leader? - rescue Exception => e - Rails.logger.info("Exception %s: %s" % [e.class, e.message]) - flash[:notice] = "Talk to your leader!" - redirect_to root_url and return - end - - @users = Agent.where(name: current_agent).members + @users = current_agent.members end # GET /my/account diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 15d5082..e39da5f 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -6,25 +6,6 @@ module ApplicationHelper def current_agency current_user.agencies.where(agent: current_agent).first end - %w(observer editor maintainer leader).each do |role| - define_method :"current_user_#{role}?" do - current_agency.send(:"#{role}?") - end - end - - def map_container(map = Map.first) - raw tag.div( - tag.div(id: 'map', - data: { - target: 'map.container' - }), - data: { - controller: 'map', - 'map-latitude': map.latitude, - 'map-longitude': map.longitude, - 'map-zoom': map.zoom - }) - end # Markdown helper # Always use all extensions. Additional parser and render options may be diff --git a/app/helpers/leaflet_helper.rb b/app/helpers/leaflet_helper.rb new file mode 100644 index 0000000..6ca03f3 --- /dev/null +++ b/app/helpers/leaflet_helper.rb @@ -0,0 +1,11 @@ +module LeafletHelper + def marker_for(resource, options = {}) + coords = [resource.latitude, resource.longitude] + + "L.marker(#{coords}, #{options}).bindPopup(%s)" % popup_for(resource) + end + + def popup_for(resource) + render partial: 'resource/popup', locals: { resource: resource } + end +end diff --git a/app/helpers/map_helper.rb b/app/helpers/map_helper.rb new file mode 100644 index 0000000..3403801 --- /dev/null +++ b/app/helpers/map_helper.rb @@ -0,0 +1,19 @@ +# SPDX-FileCopyrightText: 2020 IN COMMON Collective <collective@incommon.cc> +# +# SPDX-License-Identifier: AGPL-3.0-or-later + +module MapHelper + def map_container(map = Map.first) + raw tag.div( + tag.div(id: 'map', + data: { + target: 'map.container' + }), + data: { + controller: 'map', + 'map-latitude': map.latitude, + 'map-longitude': map.longitude, + 'map-zoom': map.zoom + }) + end +end diff --git a/app/helpers/sections_helper.rb b/app/helpers/sections_helper.rb new file mode 100644 index 0000000..8180fee --- /dev/null +++ b/app/helpers/sections_helper.rb @@ -0,0 +1,19 @@ +module SectionsHelper + # Render a section as a GeoJSON FeatureCollection + def geojson_feature_collection(section) + out = [] + class_name = { baseVal: "cat#{section.category_id} sec#{section.id}" } + style = { fill: section.category.color } + + section.resources.each do |marker| + # Add styling + marker = marker.to_geojson + marker['className'] = class_name + marker['style'] = style + + out << marker.to_json + end + + raw("{ \"type\": \"FeatureCollection\", \"features\": [ #{out.join(',')} ] }") + end +end diff --git a/app/helpers/taxonomies/filter_helper.rb b/app/helpers/taxonomies/filter_helper.rb index 97fe271..92a501f 100644 --- a/app/helpers/taxonomies/filter_helper.rb +++ b/app/helpers/taxonomies/filter_helper.rb @@ -11,7 +11,7 @@ module Taxonomies::FilterHelper @taxonomy.categories.each do |cat| list = [] cat.sections.each do |sec| - list << tag.li(h("#{sec.rank}. #{sec.name}"), id: "section-#{sec.id}", data: { action: "taxonomy#section", target: 'taxonomy.section', 'taxonomy-section-id': sec.id }) + list << tag.li(h("#{sec.rank}. #{sec.name}"), id: "section-#{sec.id}", data: { action: "click->taxonomy#section", target: 'taxonomy.section', 'taxonomy-section-id': sec.id }) end html << tag.li(h("#{cat.rank}. #{cat.name}") << tag.ol(list.join.html_safe), id: "category-#{cat.id}", diff --git a/app/javascript/controllers/map_controller.js b/app/javascript/controllers/map_controller.js index 30c1361..1704da8 100644 --- a/app/javascript/controllers/map_controller.js +++ b/app/javascript/controllers/map_controller.js @@ -7,32 +7,65 @@ // import { Controller } from "stimulus" -import "leaflet/dist/leaflet.css" -import 'leaflet-defaulticon-compatibility/dist/leaflet-defaulticon-compatibility.webpack.css'; // Re-uses images from ~leaflet package -import L from "leaflet" +import 'leaflet/dist/leaflet.css' +// Re-uses images from ~leaflet package +import 'leaflet-defaulticon-compatibility/dist/leaflet-defaulticon-compatibility.webpack.css' + +import * as L from 'leaflet' +import 'leaflet-defaulticon-compatibility' +import "leaflet-providers" +import "leaflet.markercluster/dist/leaflet.markercluster.js" + +import 'leaflet-makimarkers' export default class extends Controller { static targets = [ "container" ] initialize() { - + console.log("Map controller initialized.") + this.mapBoxAPIToken = 'pk.eyJ1IjoibmVtYWVsIiwiYSI6ImNrZzBrYjBudTB3bnMyenFmNWtrN3h3bmMifQ.Rkeyhm-9iIQOV7NAMA5LaA' } connect() { - this.map = L.map(this.containerTarget, { - zoomDelta: 0.5, - zoomSnap: 0.5, - }).setView(this._coordinates(), this._zoom()); + L.MakiMarkers.accessToken = this.mapBoxAPIToken - L.tileLayer('https://api.mapbox.com/styles/v1/{id}/tiles/{z}/{x}/{y}?access_token={accessToken}', { + var mapbox = L.tileLayer('https://api.mapbox.com/styles/v1/{id}/tiles/{z}/{x}/{y}?access_token={accessToken}', { attribution: 'Map data © <a href="https://www.openstreetmap.org/">OpenStreetMap</a> contributors, <a href="https://creativecommons.org/licenses/by-sa/2.0/">CC-BY-SA</a>, Imagery <a href="https://www.mapbox.com/">Mapbox</a>', maxZoom: 18, id: 'mapbox/streets-v11', tileSize: 512, zoomOffset: -1, - accessToken: 'pk.eyJ1IjoibmVtYWVsIiwiYSI6ImNrZzBrYjBudTB3bnMyenFmNWtrN3h3bmMifQ.Rkeyhm-9iIQOV7NAMA5LaA' - }).addTo(this.map); + accessToken: this.mapBoxAPIToken + }) + + var stamen_tr = L.tileLayer.provider('Stamen.Toner') + var stamen_wc = L.tileLayer.provider('Stamen.Watercolor') + var tiles_osm = L.tileLayer.provider('OpenStreetMap.Mapnik') + var tiles_sat = L.tileLayer.provider('Esri.WorldImagery') + + const tilemaps = { + 'osm': tiles_osm, + 'mapbox': mapbox, + 'watercolor': stamen_wc, + 'greyscale': stamen_tr, + 'satellite': tiles_sat + } + + const overlays = {} + + this.map = L.map(this.containerTarget, { + zoomDelta: 0.5, + zoomSnap: 0.5, + layers: [ tiles_osm ], + }).setView(this._coordinates(), this._zoom()); + + L.control.layers(tilemaps, overlays).addTo(this.map) + + L.DomEvent.on(window, 'hashchange', this.doSomethingCool); + + // Allow calling the mapController from elsewhere. + this.element[this.identifier] = this } disconnect() { @@ -40,6 +73,10 @@ export default class extends Controller { console.log('Map controller disconnected.') } + doSomethingCool() { + console.log(window.location.hash) + } + _coordinates() { return [this.data.get('latitude'), this.data.get('longitude')]; } diff --git a/app/javascript/controllers/taxonomy_controller.js b/app/javascript/controllers/taxonomy_controller.js index 16d57fa..02b1483 100644 --- a/app/javascript/controllers/taxonomy_controller.js +++ b/app/javascript/controllers/taxonomy_controller.js @@ -9,15 +9,18 @@ import { Controller } from "stimulus" export default class extends Controller { - static targets = [ "category", "deploy", "filter", "section", "toggle" ] + static targets = [ "category", "deploy", "filter", "layers", "section", "toggle" ] initialize() { console.log("Taxonomy controller initialized.") + + this.overlays = {} + this.sectionsOnMap = [] } connect() { console.log("Taxonomy controller connected.") - + this.taxonomy_uuid = this.data.get('uuid') if (this.hasFilterTarget) { let url = `/taxonomies/${this.data.get('uuid')}/filter.js` console.log(`loading url = ${url}`) @@ -29,10 +32,19 @@ export default class extends Controller { } else { console.log("Taxonomy filter is missing") } + + // Access the map + if (this.map = document.querySelector('#map').parentElement.map.map) { + console.log("Taxonomy Controller connected to this.map") + } else { + console.log("Taxonomy Controller could not load map!") + } } + deploy() { console.log(`deploying taxonomy ${this.data.get('uuid')}`); + fetch(`/taxonomies/${this.data.get('uuid')}.js`) .then(response => response.text()) .then(html => this.deployTarget.innerHTML = html); @@ -45,12 +57,100 @@ export default class extends Controller { } category(event) { - let catId = event.target.dataset.taxonomyCategoryId - event.target.classList.toggle('active') + let catId = (event.target.dataset.taxonomyCategoryId || event.target.parentNode.parentNode.dataset.CategoryId) + let secId = event.target.dataset.taxonomySectionId + console.log(`Category: ${catId}/${secId}`) + var active = event.target.classList.toggle('active') + if (active) { + console.log('activated') + } else { + console.log('deactivated') + } + } + + loadCategory(catId) { + document.querySelector(`#category-${catId}`).lastChild.childNodes.forEach(function(li) { + this._mapLayerToggleSection(li.dataset.taxonomySectionId) + }) } section(event) { - let catId = event.target.dataset.taxonomySectionId - event.target.classList.toggle('active') + let secId = event.target.dataset.taxonomySectionId + console.log(`Section: ${secId} to be loaded`) + this._loadMarkers(secId) + this._mapLayerToggleSection(secId) + } + + _sectionIconName(secId) { + const names = { + 215: 'campsite', + 216: 'hospital', + 217: 'landmark', + 218: 'shelter', + 219: 'lodging', + 220: 'playground', + 221: 'residential-community', + 222: 'home', + 223: 'residential-community', + 224: 'residential-community', + 225: 'home' + + } + return names[secId] || 'circle' + } + + _loadMarkers(secId) { + if (this.overlays[secId] == undefined) { + console.log(`loading markers for section ${secId} [${this._sectionIconName(secId)}]...`) + let overlay = L.layerGroup(); + let markers = L.markerClusterGroup(); + let iconName = this._sectionIconName(secId); + + fetch(`/sections/${secId}.json`, { + headers: { 'X-CSRF-Token': this._csrfToken() } + }) + .then(response => response.json()) + .then(data => { + L.geoJSON(data, { + pointToLayer: function (feature, latlng) { + return L.marker(latlng, { + attribution: feature.source, + icon: L.MakiMarkers.icon({ + icon: iconName, + className: feature.className.baseVal, + color: feature.style.fill, + size: 'm' + }) + }); + }, + onEachFeature: (feature, layer) => { + layer.on('click', () => this.onClick(layer)) + layer.addTo(markers) + } + }) + }) + console.log(`cluster counts ${markers.length} markers`) + this.overlays[secId] = markers + } + } + + onClick(layer) { + console.log(layer) + } + + _mapLayerToggleSection(secId) { + if (this.sectionsOnMap.includes(secId)) { + console.log(`removing section ${secId} from map`) + this.map.removeLayer(this.overlays[secId]) + this.sectionsOnMap.pop(secId) + } else { + console.log(`adding section ${secId} to the map`) + this.sectionsOnMap.push(secId) + this.overlays[secId].addTo(this.map) + } + } + + _csrfToken() { + return document.querySelector('[name=csrf-token]').content } } diff --git a/app/javascript/packs/application.js b/app/javascript/packs/application.js index 5e3eec0..a4b51a8 100644 --- a/app/javascript/packs/application.js +++ b/app/javascript/packs/application.js @@ -15,4 +15,10 @@ require("@rails/activestorage").start() // const images = require.context('../images', true) // const imagePath = (name) => images(name, true) +//= require leaflet +//= require leaflet-defaulticon-compatibility +//= require leaflet.markercluster + import "controllers" + +import 'stylesheets/application' diff --git a/app/models/agency.rb b/app/models/agency.rb index 7ffe489..842e8bd 100644 --- a/app/models/agency.rb +++ b/app/models/agency.rb @@ -3,34 +3,6 @@ # SPDX-License-Identifier: AGPL-3.0-or-later class Agency < ApplicationRecord - include Bitfields - belongs_to :agent belongs_to :user - - bitfield :roles, :observer, :editor, :maintainer, :leader - - class << self - # Grant role in agent to user - def grant(agent, user, role) - r = find_or_create_by(agent: agent, user: user) - r&.public_send("#{role}=", true) && r&.save - end - - # Revoke role in agent from user - def revoke(agent, user, role) - r = find_by(agent: agent, user: user) - r&.public_send("#{role}=", false) && r&.save - end - end - - # Grant role to current user in current agent - def grant(role) - self.class.grant(agent, user, role) - end - - # Revoke role from current user in current agent - def revoke(role) - self.class.revoke(agent, user, role) - end end diff --git a/app/models/resource.rb b/app/models/resource.rb index 8df106c..bde0c56 100644 --- a/app/models/resource.rb +++ b/app/models/resource.rb @@ -44,17 +44,17 @@ class Resource < ApplicationRecord # You can use, e.g.: res.longitude = 0.123 def longitude - feature['geometry']['coordinates'][0] + format('%<lon>3.7f', lon: feature['geometry']['coordinates'][0]).to_f end def longitude=(value) - feature['geometry']['coordinates'][0] = value + feature['geometry']['coordinates'][0] = format('%<lon>3.7f', lon: value).to_f end # You can use, e.g.: res.latitude = 0.123 def latitude - feature['geometry']['coordinates'][1] + format('%<lat>2.7f', lat: feature['geometry']['coordinates'][1]).to_f end def latitude=(value) - feature['geometry']['coordinates'][1] = value + feature['geometry']['coordinates'][1] = format('%<lat>2.7f', lat: value).to_f end # Properties @@ -68,4 +68,16 @@ class Resource < ApplicationRecord feature['properties'][prop.to_s] = v end end + + # Poor man's GeoJSON output + def to_geojson + out = feature.dup + # Convert original Dewey IDs with local Section IDs + out['properties']['categories'] = Section.where(dewey_id: out['properties']['categories']).pluck(:id) + # Add IN COMMON Resource UUID property + out['properties']['uuid'] = uuid + # Add IN COMMON Agent UUID property + out['properties']['agent_uuid'] = agent.uuid + out + end end diff --git a/app/views/agents/_edit.html.erb b/app/views/agents/_edit.html.erb new file mode 100644 index 0000000..72ce56d --- /dev/null +++ b/app/views/agents/_edit.html.erb @@ -0,0 +1,6 @@ +<h3>Edit <%= @agent.presence&.name || 'new agent' %></h3> +<h2>Context: <%= current_agent %></h2> + +<%= form_with model: @agent, url: controller.action_name == 'new' ? agents_path : agent_path(@agent) do |f| %> + <%= render partial: 'form', locals: { agent: @agent, f: f } %> +<% end %> diff --git a/app/views/agents/_form.html.erb b/app/views/agents/_form.html.erb new file mode 100644 index 0000000..563e8ec --- /dev/null +++ b/app/views/agents/_form.html.erb @@ -0,0 +1,22 @@ +<fieldset> + <%= tag.legend "Propriétés de l'Agent" %> + + <dl> + <dt><%= f.label :name %></dt> + <dd><%= f.text_field :name, maxlength: 64, placeholder: 'incommon' %> + <br>hint: this must match a group name on talk.incommon.cc</dd> + + <dt><%= f.label :summary %></dt> + <dd><%= f.text_field :summary, maxlength: 136, placeholder: 'Default Agent' %></dd> + + <dt><%= f.label :description %></dt> + <dd><%= f.text_area :description, cols: 72, rows: 10, spellcheck: true, +placeholder: '## IN COMMON Default Agent + +La description _peut_ comporter du [Markdown]. + +[Markdown]: https://www.markdownguide.org/getting-started/' %></dd> + </dl> +</fieldset> + +<p><%= f.submit 'Save' %></p> diff --git a/app/views/agents/index.html.erb b/app/views/agents/index.html.erb new file mode 100644 index 0000000..6cb9fb3 --- /dev/null +++ b/app/views/agents/index.html.erb @@ -0,0 +1,5 @@ +<article id="agents"> + <h1>Agents</h1> + + <%= render partial: @agents %> +</article> diff --git a/app/views/agents/new.html.erb b/app/views/agents/new.html.erb new file mode 100644 index 0000000..3794662 --- /dev/null +++ b/app/views/agents/new.html.erb @@ -0,0 +1,2 @@ +<%= render partial: 'edit', locals: { agent: @agent } %> + diff --git a/app/views/agents/show.html.erb b/app/views/agents/show.html.erb new file mode 100644 index 0000000..0652dc8 --- /dev/null +++ b/app/views/agents/show.html.erb @@ -0,0 +1,3 @@ +<article class="agent" id="agent-<%= @agent.to_param %>"> + <%= render partial: @agent %> +</article> diff --git a/app/views/categories/_category.html.erb b/app/views/categories/_category.html.erb new file mode 100644 index 0000000..d301fe6 --- /dev/null +++ b/app/views/categories/_category.html.erb @@ -0,0 +1,17 @@ +<article class="category" id="category-<%= category.id %>"> + <header style="background-color: <%= category.color %>"> + <h1><%= category.taxonomy.name %></h1> + <h2><%= category.name %></h2> + </header> + <p><%= h category.summary %></p> + <div class="markdown"><%= h category.description %></div> + <section id="stats"><h3>Info</h3> + <p><%= pluralize(category.sections_count, 'section') %></p> + <p><%= pluralize(category.sections.map { |s| s.resources }.sum(&:count) || 0, 'resources') %></p> + </section> + <section id="actions"> + <ul> + <li><%= link_to 'edit', edit_category_path(category) %></li> + </ul> + </section> +</article> diff --git a/app/views/categories/_edit.html.erb b/app/views/categories/_edit.html.erb new file mode 100644 index 0000000..4a2da94 --- /dev/null +++ b/app/views/categories/_edit.html.erb @@ -0,0 +1,6 @@ +<h3>Edit <%= @category.presence&.name || 'new category' %></h3> +<h2>Context: <%= @taxonomy %></h2> + +<%= form_with model: [@taxonomy,@category], url: controller.action_name == 'new' ? taxonomy_categories_path(taxonomy: @taxonomy) : category_path(@category) do |f| %> + <%= render partial: 'form', locals: { category: category, f: f } %> +<% end %> diff --git a/app/views/categories/_form.html.erb b/app/views/categories/_form.html.erb new file mode 100644 index 0000000..c4c77c6 --- /dev/null +++ b/app/views/categories/_form.html.erb @@ -0,0 +1,25 @@ +<fieldset> + <%= tag.legend "Categorie..." %> + + <dl> + <dt><%= f.label :name %></dt> + <dd><%= f.text_field :name, maxlength: 64, placeholder: 'Se loger' %></dd> + + <dt><%= f.label :summary %></dt> + <dd><%= f.text_field :summary, maxlength: 136, placeholder: 'Une ferme locale' %></dd> + + <dt><%= f.label :description %></dt> + <dd><%= f.text_area :description, cols: 72, rows: 10, placeholder: '## Un choix pertinent + +La description _peut_ comporter du [Markdown]. + +[Markdown]: https://www.markdownguide.org/getting-started/' %></dd> + + <dt><%= f.label :color %></dt> + <dd><%= f.color_field :color, placeholder: '#cc0077 (or: rgba(255 0 0 0.5)' %></dd> + </dl> +</fieldset> + +<%= f.hidden_field :taxonomy_id, value: @category.taxonomy_id %> + +<p><%= f.submit 'Save' %></p> diff --git a/app/views/categories/edit.html.erb b/app/views/categories/edit.html.erb new file mode 100644 index 0000000..054bed3 --- /dev/null +++ b/app/views/categories/edit.html.erb @@ -0,0 +1 @@ +<%= render partial: 'edit', locals: { category: @category } %> diff --git a/app/views/categories/show.html.erb b/app/views/categories/show.html.erb new file mode 100644 index 0000000..ed548c6 --- /dev/null +++ b/app/views/categories/show.html.erb @@ -0,0 +1,2 @@ +<%= @category.inspect %> +<%= render @category %> diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index 210ace8..bc02585 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -4,33 +4,34 @@ <meta charset="UTF-8"> <title>Carte IN COMMON</title> <meta name="viewport" content="initial-width: device-width initial-scale=1.0 viewport-fit=cover"> - <%= csrf_meta_tags %> - <%= csp_meta_tag %> + <%= csrf_meta_tags %> + <%= csp_meta_tag %> + <%= display_meta_tags site: 'IN COMMON Map' %> - <%= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track': 'reload' %> - <%= javascript_pack_tag 'application', 'data-turbolinks-track': 'reload' %> - <%= yield :head %> - </head> + <%= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track': 'reload' %> + <%= javascript_pack_tag 'application', 'data-turbolinks-track': 'reload' %> + <%= yield :head %> + </head> - <body> - <header> - <h1><%= link_to image_tag("https://talk.incommon.cc/uploads/disc_6_incommon/original/1X/92f926e8210ea7a5412d6e2bdabfa825233e808b.png", alt: "IN COMMON", size: "x4em"), '/' %></h1> - <%= render 'application/user_info' %> - <%= yield :header %> - </header> - <main> - <article> - <%= yield %> - </article> - </main> - <aside> - <%= yield :aside %> - </aside> - <footer> - <%= yield :footer %> - </footer> - <%= render partial: 'debug' %> - <%= render partial: 'flash' %> - <%= yield :body_end %> - </body> + <body> + <header> + <h1><%= link_to image_tag("https://talk.incommon.cc/uploads/disc_6_incommon/original/1X/92f926e8210ea7a5412d6e2bdabfa825233e808b.png", alt: "IN COMMON", size: "x4em"), '/' %></h1> + <%= render 'application/user_info' %> + <%= yield :header %> + </header> + <main> + <article> + <%= yield %> + </article> + </main> + <aside> + <%= yield :aside %> + </aside> + <footer> + <%= yield :footer %> + </footer> + <%= render partial: 'debug' %> + <%= render partial: 'flash' %> + <%= yield :body_end %> + </body> </html> diff --git a/app/views/resources/_resource.json.erb b/app/views/resources/_resource.json.erb new file mode 100644 index 0000000..a3769d6 --- /dev/null +++ b/app/views/resources/_resource.json.erb @@ -0,0 +1 @@ +<%= resource.as_json %> diff --git a/app/views/resources/show.json.erb b/app/views/resources/show.json.erb new file mode 100644 index 0000000..5855d72 --- /dev/null +++ b/app/views/resources/show.json.erb @@ -0,0 +1 @@ +<%= render @resource %> diff --git a/app/views/sections/show.html.erb b/app/views/sections/show.html.erb new file mode 100644 index 0000000..9a69891 --- /dev/null +++ b/app/views/sections/show.html.erb @@ -0,0 +1,11 @@ +<pre><code lang="ecmascript"> +// First, create a section layer on the map, then assign all resource markers to it. +sec<%= @section.id %> = L.layerGroup + +<% @section.resources.each_with_index do |res, i| %> +mk_<%= i %> = L.marker([<%= res.latitude %>, <%= res.longitude %>]).addTo(sec<%= @section.id %>) +<% end %> + +sec<%= @section.id %>.addTo(map) + +</code></pre> diff --git a/app/views/sections/show.json.erb b/app/views/sections/show.json.erb new file mode 100644 index 0000000..9520404 --- /dev/null +++ b/app/views/sections/show.json.erb @@ -0,0 +1 @@ +<%= geojson_feature_collection(@section) %> diff --git a/app/views/taxonomies/_taxonomy.html.erb b/app/views/taxonomies/_taxonomy.html.erb index eff6931..eb2dd79 100644 --- a/app/views/taxonomies/_taxonomy.html.erb +++ b/app/views/taxonomies/_taxonomy.html.erb @@ -5,4 +5,3 @@ <button data-action="taxonomy#deploy">Preview</button> <div class="deploy" data-target="taxonomy.deploy"></div> </section> - diff --git a/app/views/taxonomies/index.html.erb b/app/views/taxonomies/index.html.erb index d060f6c..705b0d4 100644 --- a/app/views/taxonomies/index.html.erb +++ b/app/views/taxonomies/index.html.erb @@ -1,5 +1,5 @@ <section id="taxonomies"> <h2>Available Taxonomies</h2> - <%= render collection: @taxonomies: %> + <%= render collection: @taxonomies %> </section> diff --git a/app/views/users/_user.html.erb b/app/views/users/_user.html.erb new file mode 100644 index 0000000..2da5239 --- /dev/null +++ b/app/views/users/_user.html.erb @@ -0,0 +1,3 @@ +<div class="member"> + <span class="name"><%= user.name %></span> +</div> diff --git a/app/views/users/index.html.erb b/app/views/users/index.html.erb index 0d53728..3451981 100644 --- a/app/views/users/index.html.erb +++ b/app/views/users/index.html.erb @@ -1,4 +1,4 @@ -<h1>Users#index</h1> -<p>Find me in app/views/users/index.html.erb</p> +<h1>Agent <%= current_agent %> Members</h1> +<p>This agent counts (<%= pluralize(@users.count, "member") %>)</p> -<p>Show a table with Agent <%= current_agent %> members (<%= pluralize(@users.count, "user") %>), their roles, and ways to change them.</p> +<%= render partial: 'user', collection: @users %> diff --git a/app/views/welcome/authenticate.html.erb b/app/views/welcome/authenticate.html.erb index 548101b..ba9f1c5 100644 --- a/app/views/welcome/authenticate.html.erb +++ b/app/views/welcome/authenticate.html.erb @@ -5,7 +5,7 @@ <p>Your Agents: <ul> <% @current_user&.agencies&.each do |a| %> - <li><%= a.name %> (<%= a.roles %>)</li> + <li><%= a.name %></li> <% end %> </ul> </p> diff --git a/app/views/welcome/index.html.erb b/app/views/welcome/index.html.erb index 2a154ae..d9fd0f6 100644 --- a/app/views/welcome/index.html.erb +++ b/app/views/welcome/index.html.erb @@ -8,14 +8,11 @@ <button data-action="taxonomy#toggle" data-target="taxonomy.toggle"></button> </div> <div data-target="taxonomy.filter"></div> + <div data-target="taxonomy.layers"></div> </div> <% end %> <% content_for :debug do %> <% if current_user.present? %> - <p>Premier élément de la liste:</p> - <% res = @resources.first %> - <p><%= res.feature["properties"]["name"] %></p> - <p><%= res.feature["geometry"]["coordinates"] %></p> <% end %><%# ensure it does not break when we don't have a record... %> <% end %> @@ -1,4 +1,5 @@ #!/usr/bin/env ruby +load File.expand_path("spring", __dir__) APP_PATH = File.expand_path('../config/application', __dir__) -require_relative '../config/boot' -require 'rails/commands' +require_relative "../config/boot" +require "rails/commands" @@ -1,4 +1,5 @@ #!/usr/bin/env ruby -require_relative '../config/boot' -require 'rake' +load File.expand_path("spring", __dir__) +require_relative "../config/boot" +require "rake" Rake.application.run @@ -1,5 +1,5 @@ #!/usr/bin/env ruby -require 'fileutils' +require "fileutils" # path to your application root. APP_ROOT = File.expand_path('..', __dir__) @@ -9,8 +9,8 @@ def system!(*args) end FileUtils.chdir APP_ROOT do - # This script is a way to setup or update your development environment automatically. - # This script is idempotent, so that you can run it at anytime and get an expectable outcome. + # This script is a way to set up or update your development environment automatically. + # This script is idempotent, so that you can run it at any time and get an expectable outcome. # Add necessary setup steps to this file. puts '== Installing dependencies ==' @@ -18,7 +18,7 @@ FileUtils.chdir APP_ROOT do system('bundle check') || system!('bundle install') # Install JavaScript dependencies - # system('bin/yarn') + system! 'bin/yarn' # puts "\n== Copying sample files ==" # unless File.exist?('config/database.yml') diff --git a/bin/spring b/bin/spring new file mode 100755 index 0000000..9675cce --- /dev/null +++ b/bin/spring @@ -0,0 +1,14 @@ +#!/usr/bin/env ruby +if !defined?(Spring) && [nil, "development", "test"].include?(ENV["RAILS_ENV"]) + gem "bundler" + require "bundler" + + # Load Spring without loading other gems in the Gemfile, for speed. + Bundler.locked_gems.specs.find { |spec| spec.name == "spring" }&.tap do |spring| + Gem.use_paths Gem.dir, Bundler.bundle_path.to_s, *Gem.path + gem "spring", spring.version + require "spring/binstub" + rescue Gem::LoadError + # Ignore when Spring is not installed. + end +end @@ -1,9 +1,15 @@ #!/usr/bin/env ruby APP_ROOT = File.expand_path('..', __dir__) Dir.chdir(APP_ROOT) do - begin - exec "yarnpkg", *ARGV - rescue Errno::ENOENT + yarn = ENV["PATH"].split(File::PATH_SEPARATOR). + select { |dir| File.expand_path(dir) != __dir__ }. + product(["yarn", "yarn.exe"]). + map { |dir, file| File.expand_path(file, dir) }. + find { |file| File.executable?(file) } + + if yarn + exec yarn, *ARGV + else $stderr.puts "Yarn executable was not detected in the system." $stderr.puts "Download Yarn at https://yarnpkg.com/en/docs/install" exit 1 @@ -1,5 +1,6 @@ # This file is used by Rack-based servers to start the application. -require_relative 'config/environment' +require_relative "config/environment" run Rails.application +Rails.application.load_server diff --git a/config/application.rb b/config/application.rb index 0ca42d8..8752f57 100644 --- a/config/application.rb +++ b/config/application.rb @@ -1,4 +1,4 @@ -require_relative 'boot' +require_relative "boot" require "rails" # Pick the frameworks you want: @@ -13,7 +13,7 @@ require "action_text/engine" require "action_view/railtie" # require "action_cable/engine" require "sprockets/railtie" -# require "rails/test_unit/railtie" +require "rails/test_unit/railtie" # Require the gems listed in Gemfile, including any gems # you've limited to :test, :development, or :production. @@ -22,14 +22,14 @@ Bundler.require(*Rails.groups) module IncommonMap class Application < Rails::Application # Initialize configuration defaults for originally generated Rails version. - config.load_defaults 6.0 + config.load_defaults 6.1 - # Settings in config/environments/* take precedence over those specified here. - # Application configuration can go into files in config/initializers - # -- all .rb files in that directory are automatically loaded after loading - # the framework and any gems in your application. - - # Don't generate system test files. - config.generators.system_tests = nil + # Configuration for the application, engines, and railties goes here. + # + # These settings can be overridden in specific environments using the files + # in config/environments, which are processed later. + # + # config.time_zone = "Central Time (US & Canada)" + # config.eager_load_paths << Rails.root.join("extras") end end diff --git a/config/boot.rb b/config/boot.rb index b9e460c..3cda23b 100644 --- a/config/boot.rb +++ b/config/boot.rb @@ -1,4 +1,4 @@ ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../Gemfile', __dir__) -require 'bundler/setup' # Set up gems listed in the Gemfile. -require 'bootsnap/setup' # Speed up boot time by caching expensive operations. +require "bundler/setup" # Set up gems listed in the Gemfile. +require "bootsnap/setup" # Speed up boot time by caching expensive operations. diff --git a/config/environment.rb b/config/environment.rb index 426333b..cac5315 100644 --- a/config/environment.rb +++ b/config/environment.rb @@ -1,5 +1,5 @@ # Load the Rails application. -require_relative 'application' +require_relative "application" # Initialize the Rails application. Rails.application.initialize! diff --git a/config/environments/development.rb b/config/environments/development.rb index 3ae395e..7a9f6c3 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -1,8 +1,10 @@ +require "active_support/core_ext/integer/time" + Rails.application.configure do # Settings specified here will take precedence over those in config/application.rb. - # In the development environment your application's code is reloaded on - # every request. This slows down response time but is perfect for development + # In the development environment your application's code is reloaded any time + # it changes. This slows down response time but is perfect for development # since you don't have to restart the web server when you make code changes. config.cache_classes = false @@ -29,16 +31,22 @@ Rails.application.configure do end # Store uploaded files on the local file system (see config/storage.yml for options). - # config.active_storage.service = :local + config.active_storage.service = :local # Don't care if the mailer can't send. - # config.action_mailer.raise_delivery_errors = false + config.action_mailer.raise_delivery_errors = false - # config.action_mailer.perform_caching = false + config.action_mailer.perform_caching = false # Print deprecation notices to the Rails logger. config.active_support.deprecation = :log + # Raise exceptions for disallowed deprecations. + config.active_support.disallowed_deprecation = :raise + + # Tell Active Support which deprecation messages to disallow. + config.active_support.disallowed_deprecation_warnings = [] + # Raise an error on page load if there are pending migrations. config.active_record.migration_error = :page_load @@ -54,9 +62,15 @@ Rails.application.configure do config.assets.quiet = true # Raises error for missing translations. - # config.action_view.raise_on_missing_translations = true + # config.i18n.raise_on_missing_translations = true + + # Annotate rendered view with file names. + # config.action_view.annotate_rendered_view_with_filenames = true # Use an evented file watcher to asynchronously detect changes in source code, # routes, locales, etc. This feature depends on the listen gem. config.file_watcher = ActiveSupport::EventedFileUpdateChecker + + # Uncomment if you wish to allow Action Cable access from any origin. + # config.action_cable.disable_request_forgery_protection = true end diff --git a/config/environments/production.rb b/config/environments/production.rb index c7d2778..8602e0b 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -1,3 +1,5 @@ +require "active_support/core_ext/integer/time" + Rails.application.configure do # Settings specified here will take precedence over those in config/application.rb. @@ -29,7 +31,7 @@ Rails.application.configure do config.assets.compile = false # Enable serving of images, stylesheets, and JavaScripts from an asset server. - # config.action_controller.asset_host = 'http://assets.example.com' + # config.asset_host = 'http://assets.example.com' # Specifies the header that your server uses for sending files. # config.action_dispatch.x_sendfile_header = 'X-Sendfile' # for Apache @@ -41,9 +43,9 @@ Rails.application.configure do # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies. # config.force_ssl = true - # Use the lowest log level to ensure availability of diagnostic information - # when problems arise. - config.log_level = :debug + # Include generic and useful information about system operation, but avoid logging too much + # information to avoid inadvertent exposure of personally identifiable information (PII). + config.log_level = :info # Prepend all log lines with the following tags. config.log_tags = [ :request_id ] @@ -68,11 +70,17 @@ Rails.application.configure do # Send deprecation notices to registered listeners. config.active_support.deprecation = :notify + # Log disallowed deprecations. + config.active_support.disallowed_deprecation = :log + + # Tell Active Support which deprecation messages to disallow. + config.active_support.disallowed_deprecation_warnings = [] + # Use default logging formatter so that PID and timestamp are not suppressed. config.log_formatter = ::Logger::Formatter.new # Use a different logger for distributed setups. - # require 'syslog/logger' + # require "syslog/logger" # config.logger = ActiveSupport::TaggedLogging.new(Syslog::Logger.new 'app-name') if ENV["RAILS_LOG_TO_STDOUT"].present? diff --git a/config/environments/test.rb b/config/environments/test.rb index 0cb2424..93ed4f1 100644 --- a/config/environments/test.rb +++ b/config/environments/test.rb @@ -1,3 +1,5 @@ +require "active_support/core_ext/integer/time" + # The test environment is used exclusively to run your application's # test suite. You never need to work with it otherwise. Remember that # your test database is "scratch space" for the test suite and is wiped @@ -44,6 +46,15 @@ Rails.application.configure do # Print deprecation notices to the stderr. config.active_support.deprecation = :stderr + # Raise exceptions for disallowed deprecations. + config.active_support.disallowed_deprecation = :raise + + # Tell Active Support which deprecation messages to disallow. + config.active_support.disallowed_deprecation_warnings = [] + # Raises error for missing translations. - # config.action_view.raise_on_missing_translations = true + # config.i18n.raise_on_missing_translations = true + + # Annotate rendered view with file names. + # config.action_view.annotate_rendered_view_with_filenames = true end diff --git a/config/initializers/assets.rb b/config/initializers/assets.rb index 4b828e8..20d4046 100644 --- a/config/initializers/assets.rb +++ b/config/initializers/assets.rb @@ -12,3 +12,4 @@ Rails.application.config.assets.paths << Rails.root.join('node_modules') # application.js, application.css, and all non-JS/CSS in the app/assets # folder are already added. # Rails.application.config.assets.precompile += %w( admin.js admin.css ) +Rails.application.config.assets.precompile += %w(leaflet.markercluster.js leaflet.markercluster.css leaflet.markercluster-default.css) diff --git a/config/initializers/backtrace_silencers.rb b/config/initializers/backtrace_silencers.rb index 59385cd..33699c3 100644 --- a/config/initializers/backtrace_silencers.rb +++ b/config/initializers/backtrace_silencers.rb @@ -1,7 +1,8 @@ # Be sure to restart your server when you modify this file. # You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces. -# Rails.backtrace_cleaner.add_silencer { |line| line =~ /my_noisy_library/ } +# Rails.backtrace_cleaner.add_silencer { |line| /my_noisy_library/.match?(line) } -# You can also remove all the silencers if you're trying to debug a problem that might stem from framework code. -# Rails.backtrace_cleaner.remove_silencers! +# You can also remove all the silencers if you're trying to debug a problem that might stem from framework code +# by setting BACKTRACE=1 before calling your invocation, like "BACKTRACE=1 ./bin/rails runner 'MyClass.perform'". +Rails.backtrace_cleaner.remove_silencers! if ENV["BACKTRACE"] diff --git a/config/initializers/content_security_policy.rb b/config/initializers/content_security_policy.rb index 35d0f26..9cd7f6a 100644 --- a/config/initializers/content_security_policy.rb +++ b/config/initializers/content_security_policy.rb @@ -28,3 +28,7 @@ # For further information see the following documentation: # https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy-Report-Only # Rails.application.config.content_security_policy_report_only = true + +Rails.application.config.content_security_policy do |policy| + policy.connect_src :self, :https, 'http://localhost:3035', 'ws://localhost:3035' if Rails.env.development? +end diff --git a/config/initializers/filter_parameter_logging.rb b/config/initializers/filter_parameter_logging.rb index 4a994e1..4b34a03 100644 --- a/config/initializers/filter_parameter_logging.rb +++ b/config/initializers/filter_parameter_logging.rb @@ -1,4 +1,6 @@ # Be sure to restart your server when you modify this file. # Configure sensitive parameters which will be filtered from the log file. -Rails.application.config.filter_parameters += [:password] +Rails.application.config.filter_parameters += [ + :passw, :secret, :token, :_key, :crypt, :salt, :certificate, :otp, :ssn +] diff --git a/config/initializers/meta_tags.rb b/config/initializers/meta_tags.rb new file mode 100644 index 0000000..464d964 --- /dev/null +++ b/config/initializers/meta_tags.rb @@ -0,0 +1,40 @@ +# frozen_string_literal: true + +# Use this setup block to configure all options available in MetaTags. +MetaTags.configure do |config| + # How many characters should the title meta tag have at most. Default is 70. + # Set to nil or 0 to remove limits. + # config.title_limit = 70 + + # When true, site title will be truncated instead of title. Default is false. + # config.truncate_site_title_first = false + + # Maximum length of the page description. Default is 300. + # Set to nil or 0 to remove limits. + # config.description_limit = 300 + + # Maximum length of the keywords meta tag. Default is 255. + # config.keywords_limit = 255 + + # Default separator for keywords meta tag (used when an Array passed with + # the list of keywords). Default is ", ". + # config.keywords_separator = ', ' + + # When true, keywords will be converted to lowercase, otherwise they will + # appear on the page as is. Default is true. + # config.keywords_lowercase = true + + # When true, the output will not include new line characters between meta tags. + # Default is false. + # config.minify_output = false + + # When false, generated meta tags will be self-closing (<meta ... />) instead + # of open (`<meta ...>`). Default is true. + # config.open_meta_tags = true + + # List of additional meta tags that should use "property" attribute instead + # of "name" attribute in <meta> tags. + # config.property_tags.push( + # 'x-hearthstone:deck', + # ) +end diff --git a/config/initializers/permissions_policy.rb b/config/initializers/permissions_policy.rb new file mode 100644 index 0000000..00f64d7 --- /dev/null +++ b/config/initializers/permissions_policy.rb @@ -0,0 +1,11 @@ +# Define an application-wide HTTP permissions policy. For further +# information see https://developers.google.com/web/updates/2018/06/feature-policy +# +# Rails.application.config.permissions_policy do |f| +# f.camera :none +# f.gyroscope :none +# f.microphone :none +# f.usb :none +# f.fullscreen :self +# f.payment :self, "https://secure.example.com" +# end diff --git a/config/routes.rb b/config/routes.rb index f5c6194..9be4a4e 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -2,6 +2,7 @@ # SPDX-License-Identifier: AGPL-3.0-or-later Rails.application.routes.draw do + get 'sections/show' # For details on the DSL available within this file, see https://guides.rubyonrails.org/routing.html root to: 'welcome#index' @@ -27,7 +28,7 @@ Rails.application.routes.draw do get '/my/account', to: 'users#show', as: 'account' patch '/my/current_agent', to: 'my/agent#switch', as: 'agent_switch' get '/my/dashboard', to: 'welcome#dashboard' - get 'my/users', to: 'users#index', as: 'users' + get 'my/peers', to: 'users#index', as: 'users' # Discourse SSO get 'authenticate(/:token)', to: 'welcome#authenticate' diff --git a/config/webpack/environment.js b/config/webpack/environment.js index d16d9af..6a6b545 100644 --- a/config/webpack/environment.js +++ b/config/webpack/environment.js @@ -1,3 +1,4 @@ const { environment } = require('@rails/webpacker') module.exports = environment + diff --git a/config/webpacker.yml b/config/webpacker.yml index 8581ac0..38c15d2 100644 --- a/config/webpacker.yml +++ b/config/webpacker.yml @@ -6,12 +6,12 @@ default: &default public_root_path: public public_output_path: packs cache_path: tmp/cache/webpacker - check_yarn_integrity: false + check_yarn_integrity: true webpack_compile_output: true # Additional paths webpack should lookup modules # ['app/assets', 'engine/foo/app/assets'] - resolved_paths: [] + resolved_paths: ['app/assets'] # Reload manifest.json on all requests so we reload latest compiled packs cache_manifest: false diff --git a/db/migrate/20210111142117_remove_agency_roles.rb b/db/migrate/20210111142117_remove_agency_roles.rb new file mode 100644 index 0000000..5a4b37f --- /dev/null +++ b/db/migrate/20210111142117_remove_agency_roles.rb @@ -0,0 +1,5 @@ +class RemoveAgencyRoles < ActiveRecord::Migration[6.0] + def change + remove_column :agencies, :roles + end +end diff --git a/db/migrate/20210121192037_create_active_storage_tables.active_storage.rb b/db/migrate/20210121192037_create_active_storage_tables.active_storage.rb new file mode 100644 index 0000000..8779826 --- /dev/null +++ b/db/migrate/20210121192037_create_active_storage_tables.active_storage.rb @@ -0,0 +1,36 @@ +# This migration comes from active_storage (originally 20170806125915) +class CreateActiveStorageTables < ActiveRecord::Migration[5.2] + def change + create_table :active_storage_blobs do |t| + t.string :key, null: false + t.string :filename, null: false + t.string :content_type + t.text :metadata + t.string :service_name, null: false + t.bigint :byte_size, null: false + t.string :checksum, null: false + t.datetime :created_at, null: false + + t.index [ :key ], unique: true + end + + create_table :active_storage_attachments do |t| + t.string :name, null: false + t.references :record, null: false, polymorphic: true, index: false + t.references :blob, null: false + + t.datetime :created_at, null: false + + t.index [ :record_type, :record_id, :name, :blob_id ], name: "index_active_storage_attachments_uniqueness", unique: true + t.foreign_key :active_storage_blobs, column: :blob_id + end + + create_table :active_storage_variant_records do |t| + t.belongs_to :blob, null: false, index: false + t.string :variation_digest, null: false + + t.index %i[ blob_id variation_digest ], name: "index_active_storage_variant_records_uniqueness", unique: true + t.foreign_key :active_storage_blobs, column: :blob_id + end + end +end diff --git a/db/migrate/20210121192038_add_service_name_to_active_storage_blobs.active_storage.rb b/db/migrate/20210121192038_add_service_name_to_active_storage_blobs.active_storage.rb new file mode 100644 index 0000000..9967a13 --- /dev/null +++ b/db/migrate/20210121192038_add_service_name_to_active_storage_blobs.active_storage.rb @@ -0,0 +1,18 @@ +# This migration comes from active_storage (originally 20190112182829) +class AddServiceNameToActiveStorageBlobs < ActiveRecord::Migration[6.0] + def up + unless column_exists?(:active_storage_blobs, :service_name) + add_column :active_storage_blobs, :service_name, :string + + if configured_service = ActiveStorage::Blob.service.name + ActiveStorage::Blob.unscoped.update_all(service_name: configured_service) + end + + change_column :active_storage_blobs, :service_name, :string, null: false + end + end + + def down + remove_column :active_storage_blobs, :service_name + end +end diff --git a/db/migrate/20210121192039_create_active_storage_variant_records.active_storage.rb b/db/migrate/20210121192039_create_active_storage_variant_records.active_storage.rb new file mode 100644 index 0000000..a286269 --- /dev/null +++ b/db/migrate/20210121192039_create_active_storage_variant_records.active_storage.rb @@ -0,0 +1,12 @@ +# This migration comes from active_storage (originally 20191206030411) +class CreateActiveStorageVariantRecords < ActiveRecord::Migration[6.0] + def change + create_table :active_storage_variant_records do |t| + t.belongs_to :blob, null: false, index: false + t.string :variation_digest, null: false + + t.index %i[ blob_id variation_digest ], name: "index_active_storage_variant_records_uniqueness", unique: true + t.foreign_key :active_storage_blobs, column: :blob_id + end + end +end diff --git a/db/schema.rb b/db/schema.rb index fa53f85..c97f290 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -2,23 +2,50 @@ # of editing this file, please use the migrations feature of Active Record to # incrementally modify your database, and then regenerate this schema definition. # -# This file is the source Rails uses to define your schema when running `rails -# db:schema:load`. When creating a new database, `rails db:schema:load` tends to +# This file is the source Rails uses to define your schema when running `bin/rails +# db:schema:load`. When creating a new database, `bin/rails db:schema:load` tends to # be faster and is potentially less error prone than running all of your # migrations from scratch. Old migrations may fail to apply correctly if those # migrations use external dependencies or application code. # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema.define(version: 2020_11_10_225447) do +ActiveRecord::Schema.define(version: 2021_01_21_192039) do # These are extensions that must be enabled in order to support this database enable_extension "plpgsql" + create_table "active_storage_attachments", force: :cascade do |t| + t.string "name", null: false + t.string "record_type", null: false + t.bigint "record_id", null: false + t.bigint "blob_id", null: false + t.datetime "created_at", null: false + t.index ["blob_id"], name: "index_active_storage_attachments_on_blob_id" + t.index ["record_type", "record_id", "name", "blob_id"], name: "index_active_storage_attachments_uniqueness", unique: true + end + + create_table "active_storage_blobs", force: :cascade do |t| + t.string "key", null: false + t.string "filename", null: false + t.string "content_type" + t.text "metadata" + t.bigint "byte_size", null: false + t.string "checksum", null: false + t.datetime "created_at", null: false + t.string "service_name", null: false + t.index ["key"], name: "index_active_storage_blobs_on_key", unique: true + end + + create_table "active_storage_variant_records", force: :cascade do |t| + t.bigint "blob_id", null: false + t.string "variation_digest", null: false + t.index ["blob_id", "variation_digest"], name: "index_active_storage_variant_records_uniqueness", unique: true + end + create_table "agencies", force: :cascade do |t| t.bigint "agent_id", null: false t.bigint "user_id", null: false - t.integer "roles", limit: 2, default: 0, null: false t.datetime "created_at", precision: 6, null: false t.datetime "updated_at", precision: 6, null: false t.index ["agent_id", "user_id"], name: "index_agencies_on_agent_id_and_user_id", unique: true @@ -55,6 +82,15 @@ ActiveRecord::Schema.define(version: 2020_11_10_225447) do t.bigint "section_id", null: false end + create_table "map_taxonomies", force: :cascade do |t| + t.bigint "map_id", null: false + t.bigint "taxonomy_id", null: false + t.datetime "created_at", precision: 6, null: false + t.datetime "updated_at", precision: 6, null: false + t.index ["map_id"], name: "index_map_taxonomies_on_map_id" + t.index ["taxonomy_id"], name: "index_map_taxonomies_on_taxonomy_id" + end + create_table "maps", force: :cascade do |t| t.uuid "uuid", null: false t.decimal "latitude", precision: 9, scale: 7 @@ -118,9 +154,13 @@ ActiveRecord::Schema.define(version: 2020_11_10_225447) do t.index ["external_id"], name: "index_users_on_external_id", unique: true end + add_foreign_key "active_storage_attachments", "active_storage_blobs", column: "blob_id" + add_foreign_key "active_storage_variant_records", "active_storage_blobs", column: "blob_id" add_foreign_key "agencies", "agents" add_foreign_key "agencies", "users" add_foreign_key "categories", "taxonomies" + add_foreign_key "map_taxonomies", "maps" + add_foreign_key "map_taxonomies", "taxonomies" add_foreign_key "maps", "taxonomies" add_foreign_key "resources", "agents" add_foreign_key "sections", "categories" diff --git a/package.json b/package.json index 552cedc..a597de3 100644 --- a/package.json +++ b/package.json @@ -1,17 +1,32 @@ { - "name": "incommon_map", - "private": true, - "dependencies": { - "@rails/activestorage": "^6.0.0", - "@rails/ujs": "^6.0.0", - "@rails/webpacker": "4.3.0", - "leaflet": "^1.7.1", - "leaflet-defaulticon-compatibility": "^0.1.1", - "stimulus": "^1.1.1", - "turbolinks": "^5.2.0" - }, - "version": "0.1.0", - "devDependencies": { - "webpack-dev-server": "^3.11.0" - } + "name": "incommon-map", + "version": "0.1.0", + "main": "index.js", + "repository": "git@gitlab.com:incommon.cc/incommon-map.git", + "author": "IN COMMON Collective", + "License": "AGPL-3.0-or-later", + "private": true, + "dependencies": { + "@rails/activestorage": "^6.0.0", + "@rails/ujs": "^6.0.0", + "@rails/webpacker": "4.3.0", + "css-loader": "^5.0.1", + "leaflet": "^1.7.1", + "leaflet-defaulticon-compatibility": "^0.1.1", + "leaflet-makimarkers": "^3.1.0", + "leaflet-providers": "^1.11.0", + "leaflet.markercluster": "^1.4.1", + "normalize.css": "^8.0.1", + "prunecluster": "^2.1.0", + "resolve-url-loader": "^3.1.2", + "sass-loader": "^10.1.0", + "stimulus": "^1.1.1", + "turbolinks": "^5.2.0" + }, + "devDependencies": { + "webpack-dev-server": "^3.11.0" + }, + "scripts": { + "preinstall": "node -e \"if(process.env.npm_execpath.indexOf('yarn') === -1) throw new Error('NPM is not supported, please use Yarn instead.')\"" + } } @@ -938,7 +938,7 @@ "@types/minimatch" "*" "@types/node" "*" -"@types/json-schema@^7.0.5": +"@types/json-schema@^7.0.5", "@types/json-schema@^7.0.6": version "7.0.6" resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.6.tgz#f4c7ec43e81b319a9815115031709f26987891f0" integrity sha512-3c+yGKvVP5Y9TYBEibGNR+kLtijnj7mYrXRg+WpFb2X9xm04g/DXYkfg4hmzJQosc9snFNUPkbYIhu+KAm6jJw== @@ -1136,6 +1136,14 @@ acorn@^6.4.1: resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.4.2.tgz#35866fd710528e92de10cf06016498e47e39e1e6" integrity sha512-XtGIhXwF8YM8bJhGxG5kXgjkEuNGLTkoYqVE+KMR+aspr4KGYmKYg7yUe3KghyQ9yheNwLnjmzh/7+gfDBmHCQ== +adjust-sourcemap-loader@3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/adjust-sourcemap-loader/-/adjust-sourcemap-loader-3.0.0.tgz#5ae12fb5b7b1c585e80bbb5a63ec163a1a45e61e" + integrity sha512-YBrGyT2/uVQ/c6Rr+t6ZJXniY03YtHGMJQYal368burRGYKqhx9qGTWqcBU5s1CwYY9E/ri63RYyG1IacMZtqw== + dependencies: + loader-utils "^2.0.0" + regex-parser "^2.2.11" + aggregate-error@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/aggregate-error/-/aggregate-error-3.1.0.tgz#92670ff50f5359bdb7a3e0d40d0ec30c5737687a" @@ -1164,6 +1172,16 @@ ajv@^6.1.0, ajv@^6.10.2, ajv@^6.12.3, ajv@^6.12.4: json-schema-traverse "^0.4.1" uri-js "^4.2.2" +ajv@^6.12.5: + version "6.12.6" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" + integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== + dependencies: + fast-deep-equal "^3.1.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.2" + alphanum-sort@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/alphanum-sort/-/alphanum-sort-1.0.2.tgz#97a1119649b211ad33691d9f9f486a8ec9fbe0a3" @@ -1247,6 +1265,11 @@ argparse@^1.0.7: dependencies: sprintf-js "~1.0.2" +arity-n@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/arity-n/-/arity-n-1.0.4.tgz#d9e76b11733e08569c0847ae7b39b2860b30b745" + integrity sha1-2edrEXM+CFacCEeuezmyhgswt0U= + arr-diff@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-4.0.0.tgz#d6461074febfec71e7e15235761a329a5dc7c520" @@ -1784,15 +1807,20 @@ camelcase-keys@^2.0.0: camelcase "^2.0.0" map-obj "^1.0.0" +camelcase@5.3.1, camelcase@^5.0.0, camelcase@^5.3.1: + version "5.3.1" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" + integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== + camelcase@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-2.1.1.tgz#7c1d16d679a1bbe59ca02cacecfb011e201f5a1f" integrity sha1-fB0W1nmhu+WcoCys7PsBHiAfWh8= -camelcase@^5.0.0, camelcase@^5.3.1: - version "5.3.1" - resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" - integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== +camelcase@^6.2.0: + version "6.2.0" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-6.2.0.tgz#924af881c9d525ac9d87f40d964e5cea982a1809" + integrity sha512-c7wVvbw3f37nuobQNtgsgG9POC9qMbNuMQmTCqZv23b6MIz0fcYpBiOlv9gEN/hdLdnZTDQhg6e9Dq5M1vKvfg== caniuse-api@^3.0.0: version "3.0.0" @@ -2013,6 +2041,13 @@ component-emitter@^1.2.1: resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.3.0.tgz#16e4070fba8ae29b679f2215853ee181ab2eabc0" integrity sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg== +compose-function@3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/compose-function/-/compose-function-3.0.3.tgz#9ed675f13cc54501d30950a486ff6a7ba3ab185f" + integrity sha1-ntZ18TzFRQHTCVCkhv9qe6OrGF8= + dependencies: + arity-n "^1.0.4" + compressible@~2.0.16: version "2.0.18" resolved "https://registry.yarnpkg.com/compressible/-/compressible-2.0.18.tgz#af53cca6b070d4c3c0750fbd77286a6d7cc46fba" @@ -2091,13 +2126,18 @@ content-type@~1.0.4: resolved "https://registry.yarnpkg.com/content-type/-/content-type-1.0.4.tgz#e138cc75e040c727b1966fe5e5f8c9aee256fe3b" integrity sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA== -convert-source-map@^1.7.0: +convert-source-map@1.7.0, convert-source-map@^1.7.0: version "1.7.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.7.0.tgz#17a2cb882d7f77d3490585e2ce6c524424a3a442" integrity sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA== dependencies: safe-buffer "~5.1.1" +convert-source-map@^0.3.3: + version "0.3.5" + resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-0.3.5.tgz#f1d802950af7dd2631a1febe0596550c86ab3190" + integrity sha1-8dgClQr33SYxof6+BZZVDIarMZA= + cookie-signature@1.0.6: version "1.0.6" resolved "https://registry.yarnpkg.com/cookie-signature/-/cookie-signature-1.0.6.tgz#e303a882b342cc3ee8ca513a79999734dab3ae2c" @@ -2278,6 +2318,24 @@ css-loader@^3.2.0: schema-utils "^2.7.0" semver "^6.3.0" +css-loader@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/css-loader/-/css-loader-5.0.1.tgz#9e4de0d6636a6266a585bd0900b422c85539d25f" + integrity sha512-cXc2ti9V234cq7rJzFKhirb2L2iPy8ZjALeVJAozXYz9te3r4eqLSixNAbMDJSgJEQywqXzs8gonxaboeKqwiw== + dependencies: + camelcase "^6.2.0" + cssesc "^3.0.0" + icss-utils "^5.0.0" + loader-utils "^2.0.0" + postcss "^8.1.4" + postcss-modules-extract-imports "^3.0.0" + postcss-modules-local-by-default "^4.0.0" + postcss-modules-scope "^3.0.0" + postcss-modules-values "^4.0.0" + postcss-value-parser "^4.1.0" + schema-utils "^3.0.0" + semver "^7.3.2" + css-prefers-color-scheme@^3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/css-prefers-color-scheme/-/css-prefers-color-scheme-3.1.1.tgz#6f830a2714199d4f0d0d0bb8a27916ed65cff1f4" @@ -2321,6 +2379,16 @@ css-what@^3.2.1: resolved "https://registry.yarnpkg.com/css-what/-/css-what-3.4.1.tgz#81cb70b609e4b1351b1e54cbc90fd9c54af86e2e" integrity sha512-wHOppVDKl4vTAOWzJt5Ek37Sgd9qq1Bmj/T1OjvicWbU5W7ru7Pqbn0Jdqii3Drx/h+dixHKXNhZYx7blthL7g== +css@^2.0.0: + version "2.2.4" + resolved "https://registry.yarnpkg.com/css/-/css-2.2.4.tgz#c646755c73971f2bba6a601e2cf2fd71b1298929" + integrity sha512-oUnjmWpy0niI3x/mPL8dVEI1l7MnG3+HHyRPHf+YFSbK+svOhXpmSOcDURUh2aOCgl2grzrOPt1nHLuCVFULLw== + dependencies: + inherits "^2.0.3" + source-map "^0.6.1" + source-map-resolve "^0.5.2" + urix "^0.1.0" + cssdb@^4.4.0: version "4.4.0" resolved "https://registry.yarnpkg.com/cssdb/-/cssdb-4.4.0.tgz#3bf2f2a68c10f5c6a08abd92378331ee803cddb0" @@ -2423,6 +2491,14 @@ cyclist@^1.0.1: resolved "https://registry.yarnpkg.com/cyclist/-/cyclist-1.0.1.tgz#596e9698fd0c80e12038c2b82d6eb1b35b6224d9" integrity sha1-WW6WmP0MgOEgOMK4LW6xs1tiJNk= +d@1, d@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/d/-/d-1.0.1.tgz#8698095372d58dbee346ffd0c7093f99f8f9eb5a" + integrity sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA== + dependencies: + es5-ext "^0.10.50" + type "^1.0.1" + dashdash@^1.12.0: version "1.14.1" resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" @@ -2674,6 +2750,11 @@ emoji-regex@^7.0.1: resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156" integrity sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA== +emojis-list@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/emojis-list/-/emojis-list-2.1.0.tgz#4daa4d9db00f9819880c79fa457ae5b09a1fd389" + integrity sha1-TapNnbAPmBmIDHn6RXrlsJof04k= + emojis-list@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/emojis-list/-/emojis-list-3.0.0.tgz#5570662046ad29e2e916e71aae260abdff4f6a78" @@ -2763,6 +2844,32 @@ es-to-primitive@^1.2.1: is-date-object "^1.0.1" is-symbol "^1.0.2" +es5-ext@^0.10.35, es5-ext@^0.10.50: + version "0.10.53" + resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.53.tgz#93c5a3acfdbef275220ad72644ad02ee18368de1" + integrity sha512-Xs2Stw6NiNHWypzRTY1MtaG/uJlwCk8kH81920ma8mvN8Xq1gsfhZvpkImLQArw8AHnv8MT2I45J3c0R8slE+Q== + dependencies: + es6-iterator "~2.0.3" + es6-symbol "~3.1.3" + next-tick "~1.0.0" + +es6-iterator@2.0.3, es6-iterator@~2.0.3: + version "2.0.3" + resolved "https://registry.yarnpkg.com/es6-iterator/-/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7" + integrity sha1-p96IkUGgWpSwhUQDstCg+/qY87c= + dependencies: + d "1" + es5-ext "^0.10.35" + es6-symbol "^3.1.1" + +es6-symbol@^3.1.1, es6-symbol@~3.1.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.3.tgz#bad5d3c1bcdac28269f4cb331e431c78ac705d18" + integrity sha512-NJ6Yn3FuDinBaBRWl/q5X/s4koRHBrgKAu+yGI6JCBeiu3qrcbJhwT2GeR/EXVfylRk8dpQVJoLEFhK+Mu31NA== + dependencies: + d "^1.0.1" + ext "^1.1.2" + escalade@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.0.tgz#e8e2d7c7a8b76f6ee64c2181d6b8151441602d4e" @@ -2912,6 +3019,13 @@ express@^4.17.1: utils-merge "1.0.1" vary "~1.1.2" +ext@^1.1.2: + version "1.4.0" + resolved "https://registry.yarnpkg.com/ext/-/ext-1.4.0.tgz#89ae7a07158f79d35517882904324077e4379244" + integrity sha512-Key5NIsUxdqKg3vIsdw9dSuXpPCQ297y6wBjL30edxwPgt2E44WcWBZey/ZvUc6sERLTxKdyCu4gZFmUbk1Q7A== + dependencies: + type "^2.0.0" + extend-shallow@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f" @@ -3589,6 +3703,11 @@ icss-utils@^4.0.0, icss-utils@^4.1.1: dependencies: postcss "^7.0.14" +icss-utils@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/icss-utils/-/icss-utils-5.0.0.tgz#03ed56c3accd32f9caaf1752ebf64ef12347bb84" + integrity sha512-aF2Cf/CkEZrI/vsu5WI/I+akFgdbwQHVE9YRZxATrhH4PVIe6a3BIjwjEcW+z+jP/hNh+YvM3lAAn1wJQ6opSg== + ieee754@^1.1.4: version "1.1.13" resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.1.13.tgz#ec168558e95aa181fd87d37f55c32bbcb6708b84" @@ -4152,6 +4271,11 @@ kind-of@^6.0.0, kind-of@^6.0.2: resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.3.tgz#07c05034a6c349fa06e24fa35aa76db4580ce4dd" integrity sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw== +klona@^2.0.4: + version "2.0.4" + resolved "https://registry.yarnpkg.com/klona/-/klona-2.0.4.tgz#7bb1e3affb0cb8624547ef7e8f6708ea2e39dfc0" + integrity sha512-ZRbnvdg/NxqzC7L9Uyqzf4psi1OM4Cuc+sJAkQPjO6XkQIJTNbfK2Rsmbw8fx1p2mkZdp2FZYo2+LwXYY/uwIA== + last-call-webpack-plugin@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/last-call-webpack-plugin/-/last-call-webpack-plugin-3.0.0.tgz#9742df0e10e3cf46e5c0381c2de90d3a7a2d7555" @@ -4165,7 +4289,24 @@ leaflet-defaulticon-compatibility@^0.1.1: resolved "https://registry.yarnpkg.com/leaflet-defaulticon-compatibility/-/leaflet-defaulticon-compatibility-0.1.1.tgz#ab72257b3da66fb48dab69a10c3824012a15a20a" integrity sha512-vDBFdlUAwjSEGep9ih8kfJilf6yN8V9zTbF5NC/1ZwLeGko3RUQepspPnGCRMFV51dY3Lb3hziboicrFz+rxQA== -leaflet@^1.7.1: +leaflet-makimarkers@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/leaflet-makimarkers/-/leaflet-makimarkers-3.1.0.tgz#b6cf89b161153bac8746f15726daa27afae6117c" + integrity sha1-ts+JsWEVO6yHRvFXJtqievrmEXw= + dependencies: + leaflet ">=0.5.0" + +leaflet-providers@^1.11.0: + version "1.11.0" + resolved "https://registry.yarnpkg.com/leaflet-providers/-/leaflet-providers-1.11.0.tgz#e3787c2a45cc1baaaaedd9251a564e88ae882046" + integrity sha512-eu/28vrWZqxv9+fXze/4ZwbjHgaWjyeLS5fDtk95W/myDBRAyaAca/5an6WFSheYyhohuLy94vpBLuGHFXiJog== + +leaflet.markercluster@^1.4.1: + version "1.4.1" + resolved "https://registry.yarnpkg.com/leaflet.markercluster/-/leaflet.markercluster-1.4.1.tgz#b53f2c4f2ca7306ddab1dbb6f1861d5e8aa6c5e5" + integrity sha512-ZSEpE/EFApR0bJ1w/dUGwTSUvWlpalKqIzkaYdYB7jaftQA/Y2Jav+eT4CMtEYFj+ZK4mswP13Q2acnPBnhGOw== + +leaflet@>=0.5.0, leaflet@^1.7.1: version "1.7.1" resolved "https://registry.yarnpkg.com/leaflet/-/leaflet-1.7.1.tgz#10d684916edfe1bf41d688a3b97127c0322a2a19" integrity sha512-/xwPEBidtg69Q3HlqPdU3DnrXQOvQU/CCHA1tcDQVzOwm91YMYaILjNp7L4Eaw5Z4sOYdbBz6koWyibppd8Zqw== @@ -4182,6 +4323,14 @@ levenary@^1.1.1: dependencies: leven "^3.1.0" +line-column@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/line-column/-/line-column-1.0.2.tgz#d25af2936b6f4849172b312e4792d1d987bc34a2" + integrity sha1-0lryk2tvSEkXKzEuR5LR2Ye8NKI= + dependencies: + isarray "^1.0.0" + isobject "^2.0.0" + lines-and-columns@^1.1.6: version "1.1.6" resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.1.6.tgz#1c00c743b433cd0a4e80758f7b64a57440d9ff00" @@ -4203,6 +4352,15 @@ loader-runner@^2.4.0: resolved "https://registry.yarnpkg.com/loader-runner/-/loader-runner-2.4.0.tgz#ed47066bfe534d7e84c4c7b9998c2a75607d9357" integrity sha512-Jsmr89RcXGIwivFY21FcRrisYZfvLMTWx5kOLc+JTxtpBOG6xML0vzbc6SEQG2FO9/4Fc3wW4LVcB5DmGflaRw== +loader-utils@1.2.3: + version "1.2.3" + resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-1.2.3.tgz#1ff5dc6911c9f0a062531a4c04b609406108c2c7" + integrity sha512-fkpz8ejdnEMG3s37wGL07iSBDg99O9D5yflE9RGNH3hRdx9SOwYfnGYdZOUIZitN8E+E2vkq3MUMYMvPYl5ZZA== + dependencies: + big.js "^5.2.2" + emojis-list "^2.0.0" + json5 "^1.0.1" + loader-utils@^1.0.1, loader-utils@^1.1.0, loader-utils@^1.2.3, loader-utils@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-1.4.0.tgz#c579b5e34cb34b1a74edc6c1fb36bfa371d5a613" @@ -4629,6 +4787,11 @@ nan@^2.12.1, nan@^2.13.2: resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.1.tgz#d7be34dfa3105b91494c3147089315eff8874b01" integrity sha512-isWHgVjnFjh2x2yuJ/tj3JbwoHu3UC2dX5G/88Cm24yB6YopVgxvBObDY7n5xW6ExmFhJpSEQqFPvq9zaXc8Jw== +nanoid@^3.1.16: + version "3.1.16" + resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.1.16.tgz#b21f0a7d031196faf75314d7c65d36352beeef64" + integrity sha512-+AK8MN0WHji40lj8AEuwLOvLSbWYApQpre/aFJZD71r43wVRLrOYS4FmJOPQYon1TqB462RzrrxlfA74XRES8w== + nanomatch@^1.2.9: version "1.2.13" resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.13.tgz#b87a8aa4fc0de8fe6be88895b38983ff265bd119" @@ -4651,11 +4814,16 @@ negotiator@0.6.2: resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.2.tgz#feacf7ccf525a77ae9634436a64883ffeca346fb" integrity sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw== -neo-async@^2.5.0, neo-async@^2.6.1: +neo-async@^2.5.0, neo-async@^2.6.1, neo-async@^2.6.2: version "2.6.2" resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== +next-tick@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c" + integrity sha1-yobR/ogoFpsBICCOPchCS524NCw= + nice-try@^1.0.4: version "1.0.5" resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" @@ -4790,6 +4958,11 @@ normalize-url@^3.0.0: resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-3.3.0.tgz#b2e1c4dc4f7c6d57743df733a4f5978d18650559" integrity sha512-U+JJi7duF1o+u2pynbp2zXDW2/PADgC30f0GsHZtRh+HOcXHnw137TrNlyxxRvWW5fjKd3bcLHPxofWuCjaeZg== +normalize.css@^8.0.1: + version "8.0.1" + resolved "https://registry.yarnpkg.com/normalize.css/-/normalize.css-8.0.1.tgz#9b98a208738b9cc2634caacbc42d131c97487bf3" + integrity sha512-qizSNPO93t1YUuUhP22btGOo3chcvDFqFaj2TRybP0DMxkHOCTYwp3n34fel4a31ORXy4m1Xq0Gyqpb5m33qIg== + npm-run-path@^2.0.0: version "2.0.2" resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f" @@ -5574,6 +5747,11 @@ postcss-modules-extract-imports@^2.0.0: dependencies: postcss "^7.0.5" +postcss-modules-extract-imports@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/postcss-modules-extract-imports/-/postcss-modules-extract-imports-3.0.0.tgz#cda1f047c0ae80c97dbe28c3e76a43b88025741d" + integrity sha512-bdHleFnP3kZ4NYDhuGlVK+CMrQ/pqUm8bx/oGL93K6gVwiclvX5x0n76fYMKuIGKzlABOy13zsvqjb0f92TEXw== + postcss-modules-local-by-default@^3.0.2: version "3.0.3" resolved "https://registry.yarnpkg.com/postcss-modules-local-by-default/-/postcss-modules-local-by-default-3.0.3.tgz#bb14e0cc78279d504dbdcbfd7e0ca28993ffbbb0" @@ -5584,6 +5762,15 @@ postcss-modules-local-by-default@^3.0.2: postcss-selector-parser "^6.0.2" postcss-value-parser "^4.1.0" +postcss-modules-local-by-default@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/postcss-modules-local-by-default/-/postcss-modules-local-by-default-4.0.0.tgz#ebbb54fae1598eecfdf691a02b3ff3b390a5a51c" + integrity sha512-sT7ihtmGSF9yhm6ggikHdV0hlziDTX7oFoXtuVWeDd3hHObNkcHRo9V3yg7vCAY7cONyxJC/XXCmmiHHcvX7bQ== + dependencies: + icss-utils "^5.0.0" + postcss-selector-parser "^6.0.2" + postcss-value-parser "^4.1.0" + postcss-modules-scope@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/postcss-modules-scope/-/postcss-modules-scope-2.2.0.tgz#385cae013cc7743f5a7d7602d1073a89eaae62ee" @@ -5592,6 +5779,13 @@ postcss-modules-scope@^2.2.0: postcss "^7.0.6" postcss-selector-parser "^6.0.0" +postcss-modules-scope@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/postcss-modules-scope/-/postcss-modules-scope-3.0.0.tgz#9ef3151456d3bbfa120ca44898dfca6f2fa01f06" + integrity sha512-hncihwFA2yPath8oZ15PZqvWGkWf+XUfQgUGamS4LqoP1anQLOsOJw0vr7J7IwLpoY9fatA2qiGUGmuZL0Iqlg== + dependencies: + postcss-selector-parser "^6.0.4" + postcss-modules-values@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/postcss-modules-values/-/postcss-modules-values-3.0.0.tgz#5b5000d6ebae29b4255301b4a3a54574423e7f10" @@ -5600,6 +5794,13 @@ postcss-modules-values@^3.0.0: icss-utils "^4.0.0" postcss "^7.0.6" +postcss-modules-values@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/postcss-modules-values/-/postcss-modules-values-4.0.0.tgz#d7c5e7e68c3bb3c9b27cbf48ca0bb3ffb4602c9c" + integrity sha512-RDxHkAiEGI78gS2ofyvCsu7iycRv7oqw5xMWn9iMoR0N/7mf9D50ecQqUo5BZ9Zh2vH4bCUR/ktCqbB9m8vJjQ== + dependencies: + icss-utils "^5.0.0" + postcss-nesting@^7.0.0: version "7.0.1" resolved "https://registry.yarnpkg.com/postcss-nesting/-/postcss-nesting-7.0.1.tgz#b50ad7b7f0173e5b5e3880c3501344703e04c052" @@ -5838,7 +6039,7 @@ postcss-selector-parser@^5.0.0-rc.3, postcss-selector-parser@^5.0.0-rc.4: indexes-of "^1.0.1" uniq "^1.0.1" -postcss-selector-parser@^6.0.0, postcss-selector-parser@^6.0.2: +postcss-selector-parser@^6.0.0, postcss-selector-parser@^6.0.2, postcss-selector-parser@^6.0.4: version "6.0.4" resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-6.0.4.tgz#56075a1380a04604c38b063ea7767a129af5c2b3" integrity sha512-gjMeXBempyInaBqpp8gODmwZ52WaYsVOsfr4L4lDQ7n3ncD6mEyySiDtgzCT+NYC0mmeOLvtsF8iaEf0YT6dBw== @@ -5886,6 +6087,15 @@ postcss-values-parser@^2.0.0, postcss-values-parser@^2.0.1: indexes-of "^1.0.1" uniq "^1.0.1" +postcss@7.0.21: + version "7.0.21" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.21.tgz#06bb07824c19c2021c5d056d5b10c35b989f7e17" + integrity sha512-uIFtJElxJo29QC753JzhidoAhvp/e/Exezkdhfmt8AymWT6/5B7W1WmponYWkHk2eg6sONyTch0A3nkMPun3SQ== + dependencies: + chalk "^2.4.2" + source-map "^0.6.1" + supports-color "^6.1.0" + postcss@^7.0.0, postcss@^7.0.1, postcss@^7.0.14, postcss@^7.0.17, postcss@^7.0.2, postcss@^7.0.26, postcss@^7.0.27, postcss@^7.0.32, postcss@^7.0.5, postcss@^7.0.6: version "7.0.35" resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.35.tgz#d2be00b998f7f211d8a276974079f2e92b970e24" @@ -5895,6 +6105,16 @@ postcss@^7.0.0, postcss@^7.0.1, postcss@^7.0.14, postcss@^7.0.17, postcss@^7.0.2 source-map "^0.6.1" supports-color "^6.1.0" +postcss@^8.1.4: + version "8.1.7" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.1.7.tgz#ff6a82691bd861f3354fd9b17b2332f88171233f" + integrity sha512-llCQW1Pz4MOPwbZLmOddGM9eIJ8Bh7SZ2Oj5sxZva77uVaotYDsYTch1WBTNu7fUY0fpWp0fdt7uW40D4sRiiQ== + dependencies: + colorette "^1.2.1" + line-column "^1.0.2" + nanoid "^3.1.16" + source-map "^0.6.1" + prepend-http@^1.0.0: version "1.0.4" resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-1.0.4.tgz#d4f4562b0ce3696e41ac52d0e002e57a635dc6dc" @@ -5928,6 +6148,11 @@ prr@~1.0.1: resolved "https://registry.yarnpkg.com/prr/-/prr-1.0.1.tgz#d3fc114ba06995a45ec6893f484ceb1d78f5f476" integrity sha1-0/wRS6BplaRexok/SEzrHXj19HY= +prunecluster@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/prunecluster/-/prunecluster-2.1.0.tgz#7f95cb98db08a325743bccc5382c30e4966e4cbd" + integrity sha512-kTp14zyPyeCgzHUiEfTcEUNzQ/96Rwij/wAQhvNaob7Gpub0jw4I8x0XIdjL0UL3zeNZeEcywJwbS4rEAhKfSg== + pseudomap@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" @@ -6160,6 +6385,11 @@ regex-not@^1.0.0, regex-not@^1.0.2: extend-shallow "^3.0.2" safe-regex "^1.1.0" +regex-parser@^2.2.11: + version "2.2.11" + resolved "https://registry.yarnpkg.com/regex-parser/-/regex-parser-2.2.11.tgz#3b37ec9049e19479806e878cabe7c1ca83ccfe58" + integrity sha512-jbD/FT0+9MBU2XAZluI7w2OBs1RBi6p9M83nkoZayQXXU9e8Robt69FcZc7wU4eJD/YFTjn1JdCk3rbMJajz8Q== + regexp.prototype.flags@^1.2.0: version "1.3.0" resolved "https://registry.yarnpkg.com/regexp.prototype.flags/-/regexp.prototype.flags-1.3.0.tgz#7aba89b3c13a64509dabcf3ca8d9fbb9bdf5cb75" @@ -6280,6 +6510,22 @@ resolve-from@^4.0.0: resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== +resolve-url-loader@^3.1.2: + version "3.1.2" + resolved "https://registry.yarnpkg.com/resolve-url-loader/-/resolve-url-loader-3.1.2.tgz#235e2c28e22e3e432ba7a5d4e305c59a58edfc08" + integrity sha512-QEb4A76c8Mi7I3xNKXlRKQSlLBwjUV/ULFMP+G7n3/7tJZ8MG5wsZ3ucxP1Jz8Vevn6fnJsxDx9cIls+utGzPQ== + dependencies: + adjust-sourcemap-loader "3.0.0" + camelcase "5.3.1" + compose-function "3.0.3" + convert-source-map "1.7.0" + es6-iterator "2.0.3" + loader-utils "1.2.3" + postcss "7.0.21" + rework "1.0.1" + rework-visit "1.0.0" + source-map "0.6.1" + resolve-url@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" @@ -6302,6 +6548,19 @@ retry@^0.12.0: resolved "https://registry.yarnpkg.com/retry/-/retry-0.12.0.tgz#1b42a6266a21f07421d1b0b54b7dc167b01c013b" integrity sha1-G0KmJmoh8HQh0bC1S33BZ7AcATs= +rework-visit@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/rework-visit/-/rework-visit-1.0.0.tgz#9945b2803f219e2f7aca00adb8bc9f640f842c9a" + integrity sha1-mUWygD8hni96ygCtuLyfZA+ELJo= + +rework@1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/rework/-/rework-1.0.1.tgz#30806a841342b54510aa4110850cd48534144aa7" + integrity sha1-MIBqhBNCtUUQqkEQhQzUhTQUSqc= + dependencies: + convert-source-map "^0.3.3" + css "^2.0.0" + rgb-regex@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/rgb-regex/-/rgb-regex-1.0.1.tgz#c0e0d6882df0e23be254a475e8edd41915feaeb1" @@ -6384,6 +6643,17 @@ sass-loader@7.3.1: pify "^4.0.1" semver "^6.3.0" +sass-loader@^10.1.0: + version "10.1.0" + resolved "https://registry.yarnpkg.com/sass-loader/-/sass-loader-10.1.0.tgz#1727fcc0c32ab3eb197cda61d78adf4e9174a4b3" + integrity sha512-ZCKAlczLBbFd3aGAhowpYEy69Te3Z68cg8bnHHl6WnSCvnKpbM6pQrz957HWMa8LKVuhnD9uMplmMAHwGQtHeg== + dependencies: + klona "^2.0.4" + loader-utils "^2.0.0" + neo-async "^2.6.2" + schema-utils "^3.0.0" + semver "^7.3.2" + sax@~1.2.4: version "1.2.4" resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9" @@ -6407,6 +6677,15 @@ schema-utils@^2.5.0, schema-utils@^2.6.5, schema-utils@^2.6.6, schema-utils@^2.7 ajv "^6.12.4" ajv-keywords "^3.5.2" +schema-utils@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-3.0.0.tgz#67502f6aa2b66a2d4032b4279a2944978a0913ef" + integrity sha512-6D82/xSzO094ajanoOSbe4YvXWMfn2A//8Y1+MUqFAJul5Bs+yn36xbK9OtNDcRVSBJ9jjeoXftM6CfztsjOAA== + dependencies: + "@types/json-schema" "^7.0.6" + ajv "^6.12.5" + ajv-keywords "^3.5.2" + scss-tokenizer@^0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/scss-tokenizer/-/scss-tokenizer-0.2.3.tgz#8eb06db9a9723333824d3f5530641149847ce5d1" @@ -6442,6 +6721,11 @@ semver@^6.0.0, semver@^6.3.0: resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== +semver@^7.3.2: + version "7.3.2" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.2.tgz#604962b052b81ed0786aae84389ffba70ffd3938" + integrity sha512-OrOb32TeeambH6UrhtShmF7CRDqhL6/5XpPNp2DuRH6+9QLw/orhp72j87v8Qa1ScDkvrrBNpZcDejAirJmfXQ== + semver@~5.3.0: version "5.3.0" resolved "https://registry.yarnpkg.com/semver/-/semver-5.3.0.tgz#9b2ce5d3de02d17c6012ad326aa6b4d0cf54f94f" @@ -6628,7 +6912,7 @@ source-list-map@^2.0.0: resolved "https://registry.yarnpkg.com/source-list-map/-/source-list-map-2.0.1.tgz#3993bd873bfc48479cca9ea3a547835c7c154b34" integrity sha512-qnQ7gVMxGNxsiL4lEuJwe/To8UnK7fAnmbGEEH8RpLouuKbeEm0lhbQVFIrNSuB+G7tVrAlVsZgETT5nljf+Iw== -source-map-resolve@^0.5.0: +source-map-resolve@^0.5.0, source-map-resolve@^0.5.2: version "0.5.3" resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.3.tgz#190866bece7553e1f8f267a2ee82c606b5509a1a" integrity sha512-Htz+RnsXWk5+P2slx5Jh3Q66vhQj1Cllm0zvnaY98+NFx+Dv2CF/f5O/t8x+KaNdrdIAsruNzoh/KpialbqAnw== @@ -6652,6 +6936,11 @@ source-map-url@^0.4.0: resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3" integrity sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM= +source-map@0.6.1, source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" + integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== + source-map@^0.4.2: version "0.4.4" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.4.4.tgz#eba4f5da9c0dc999de68032d8b4f76173652036b" @@ -6664,11 +6953,6 @@ source-map@^0.5.0, source-map@^0.5.6: resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= -source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" - integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== - spark-md5@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/spark-md5/-/spark-md5-3.0.1.tgz#83a0e255734f2ab4e5c466e5a2cfc9ba2aa2124d" @@ -7197,6 +7481,16 @@ type-is@~1.6.17, type-is@~1.6.18: media-typer "0.3.0" mime-types "~2.1.24" +type@^1.0.1: + version "1.2.0" + resolved "https://registry.yarnpkg.com/type/-/type-1.2.0.tgz#848dd7698dafa3e54a6c479e759c4bc3f18847a0" + integrity sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg== + +type@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/type/-/type-2.1.0.tgz#9bdc22c648cf8cf86dd23d32336a41cfb6475e3f" + integrity sha512-G9absDWvhAWCV2gmF1zKud3OyC61nZDwWvBL2DApaVFogI07CprggiQAOOjvp2NRjYWFzPyu7vwtDrQFq8jeSA== + typedarray@^0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" |