Only import bootstrap component that we need
authorChocobozzz <me@florianbigard.com>
Wed, 20 Dec 2017 08:26:50 +0000 (09:26 +0100)
committerChocobozzz <me@florianbigard.com>
Wed, 20 Dec 2017 08:26:50 +0000 (09:26 +0100)
client/src/sass/application.scss
client/src/sass/include/_bootstrap.scss
server/lib/activitypub/process/process-announce.ts

index 968dc5f5887a3496dae7e3dd06c52b809e8752d6..a1c222c31d1b3ae034c94908611f4a66ca38dddc 100644 (file)
@@ -2,7 +2,7 @@
 @import '_mixins';
 
 $icon-font-path: '../../node_modules/bootstrap-sass/assets/fonts/bootstrap/';
-@import '~bootstrap-sass/assets/stylesheets/_bootstrap';
+@import '_bootstrap';
 
 $FontPathSourceSansPro: '../../node_modules/npm-font-source-sans-pro/fonts';
 @import '~npm-font-source-sans-pro/source-sans-pro';
index e72d1def2a217b615f5a931d1d7e84d9332cbc6a..3857bb521ffa9857569e267aa5195878ec7dd93a 100644 (file)
@@ -1,56 +1,50 @@
-/*!
- * Bootstrap v3.3.7 (http://getbootstrap.com)
- * Copyright 2011-2016 Twitter, Inc.
- * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
- */
-
 // Core variables and mixins
-@import "bootstrap/variables";
-@import "bootstrap/mixins";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/variables";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/mixins";
 
 // Reset and dependencies
-@import "bootstrap/normalize";
-@import "bootstrap/print";
-@import "bootstrap/glyphicons";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/normalize";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/print";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/glyphicons";
 
 // Core CSS
-@import "bootstrap/scaffolding";
-@import "bootstrap/type";
-@import "bootstrap/code";
-@import "bootstrap/grid";
-@import "bootstrap/tables";
-@import "bootstrap/forms";
-@import "bootstrap/buttons";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/scaffolding";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/type";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/code";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/grid";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/tables";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/forms";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/buttons";
 
 // Components
-@import "bootstrap/component-animations";
-@import "bootstrap/dropdowns";
-@import "bootstrap/button-groups";
-@import "bootstrap/input-groups";
-@import "bootstrap/navs";
-@import "bootstrap/navbar";
-@import "bootstrap/breadcrumbs";
-@import "bootstrap/pagination";
-@import "bootstrap/pager";
-@import "bootstrap/labels";
-@import "bootstrap/badges";
-@import "bootstrap/jumbotron";
-@import "bootstrap/thumbnails";
-@import "bootstrap/alerts";
-@import "bootstrap/progress-bars";
-@import "bootstrap/media";
-@import "bootstrap/list-group";
-@import "bootstrap/panels";
-@import "bootstrap/responsive-embed";
-@import "bootstrap/wells";
-@import "bootstrap/close";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/component-animations";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/dropdowns";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/button-groups";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/input-groups";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/navs";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/navbar";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/breadcrumbs";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/pagination";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/pager";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/labels";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/badges";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/jumbotron";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/thumbnails";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/alerts";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/progress-bars";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/media";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/list-group";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/panels";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/responsive-embed";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/wells";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/close";
 
 // Components w/ JavaScript
-@import "bootstrap/modals";
-@import "bootstrap/tooltip";
-@import "bootstrap/popovers";
-@import "bootstrap/carousel";
+@import "~bootstrap-sass/assets/stylesheets/bootstrap/modals";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/tooltip";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/popovers";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/carousel";
 
-// Utility classes
-@import "bootstrap/utilities";
-@import "bootstrap/responsive-utilities";
+//// Utility classes
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/utilities";
+//@import "~bootstrap-sass/assets/stylesheets/bootstrap/responsive-utilities";
index 5568ff538d21ae7f9e290d6627fe6c09ca33da8d..c9738f926c0f356df641c58301d35783b510bb5d 100644 (file)
@@ -51,10 +51,10 @@ function shareVideo (actorAnnouncer: ActorModel, activity: ActivityAnnounce) {
     let video: VideoModel
 
     if (typeof announced === 'string') {
-      video = await VideoModel.loadByUrlAndPopulateAccount(announced as string)
+      video = await VideoModel.loadByUrlAndPopulateAccount(announced)
       if (!video) throw new Error('Unknown video to share ' + announced)
     } else {
-      video = await processCreateActivity(announced as ActivityCreate)
+      video = await processCreateActivity(announced)
     }
 
     const share = {