Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into develop

This commit is contained in:
lain 2018-04-02 13:15:38 +02:00
commit cd543d58a1
297 changed files with 1548 additions and 139218 deletions

View File

@ -50,6 +50,7 @@ config :pleroma, :instance,
name: "Pleroma",
email: "example@example.com",
limit: 5000,
upload_limit: 16_000_000,
registrations_open: true,
federating: true

View File

@ -28,7 +28,16 @@ server {
gzip_http_version 1.1;
gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript application/activity+json application/atom+xml;
location / {
add_header 'Access-Control-Allow-Origin' '*';
# if you do not want remote frontends to be able to access your Pleroma backend
# server, remove these lines.
add_header 'Access-Control-Allow-Origin' '*' always;
add_header 'Access-Control-Allow-Methods' 'POST, GET, OPTIONS' always;
add_header 'Access-Control-Allow-Headers' 'Authorization, Content-Type' always;
if ($request_method = OPTIONS) {
return 204;
}
# stop removing lines here.
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";

View File

@ -34,7 +34,8 @@ defmodule Pleroma.Web.Endpoint do
Plug.Parsers,
parsers: [:urlencoded, :multipart, :json],
pass: ["*/*"],
json_decoder: Jason
json_decoder: Jason,
length: Application.get_env(:pleroma, :instance) |> Keyword.get(:upload_limit)
)
plug(Plug.MethodOverride)

View File

@ -513,12 +513,16 @@ defmodule Pleroma.Web.MastodonAPI.MastodonAPIController do
)
statuses = Repo.all(q) ++ fetched
tags = String.split(query)
|> Enum.uniq()
|> Enum.filter(fn tag -> String.starts_with?(tag, "#") end)
|> Enum.map(fn tag -> String.slice(tag, 1..-1) end)
res = %{
"accounts" => AccountView.render("accounts.json", users: accounts, for: user, as: :user),
"statuses" =>
StatusView.render("index.json", activities: statuses, for: user, as: :activity),
"hashtags" => []
"hashtags" => tags
}
json(conn, res)

View File

@ -9,14 +9,17 @@
<link rel="icon" type="image/png" href="/favicon.png"/>
<link rel="stylesheet" media="all" href="/packs/common.css" />
<link rel="stylesheet" media="all" href="/packs/default.css" />
<link rel="stylesheet" media="all" href="/packs/pl-dark-masto-fe.css" />
<script src="/packs/common.js"></script>
<script src="/packs/locale_en.js"></script>
<link as='script' crossorigin='anonymous' href='/packs/features/getting_started.js' rel='preload'>
<link as='script' crossorigin='anonymous' href='/packs/features/compose.js' rel='preload'>
<link as='script' crossorigin='anonymous' href='/packs/features/home_timeline.js' rel='preload'>
<link as='script' crossorigin='anonymous' href='/packs/features/notifications.js' rel='preload'>
<script id='initial-state' type='application/json'><%= raw @initial_state %></script>
<script src="/packs/application.js"></script>
</head>
<body class='app-body'>
<body class='app-body no-reduce-motion'>
<div class='app-holder' data-props='{&quot;locale&quot;:&quot;en&quot;}' id='mastodon'>
</div>
</body>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,2 +0,0 @@
webpackJsonp([64],{622:function(e,c,t){"use strict";function o(e){var c=e.detail,t=c[0],o=document.querySelector('[data-id="'+t.id+'"]');o&&o.parentNode.removeChild(o)}Object.defineProperty(c,"__esModule",{value:!0});var a=t(146);t.n(a);[].forEach.call(document.querySelectorAll(".trash-button"),function(e){e.addEventListener("ajax:success",o)});Object(a.delegate)(document,"#batch_checkbox_all","change",function(e){var c=e.target;[].forEach.call(document.querySelectorAll('.batch-checkbox input[type="checkbox"]'),function(e){e.checked=c.checked})}),Object(a.delegate)(document,'.batch-checkbox input[type="checkbox"]',"change",function(){var e=document.querySelector("#batch_checkbox_all");e&&(e.checked=[].every.call(document.querySelectorAll('.batch-checkbox input[type="checkbox"]'),function(e){return e.checked}))}),Object(a.delegate)(document,".media-spoiler-show-button","click",function(){[].forEach.call(document.querySelectorAll(".activity-stream .media-spoiler-wrapper"),function(e){e.classList.add("media-spoiler-wrapper__visible")})}),Object(a.delegate)(document,".media-spoiler-hide-button","click",function(){[].forEach.call(document.querySelectorAll(".activity-stream .media-spoiler-wrapper"),function(e){e.classList.remove("media-spoiler-wrapper__visible")})})}},[622]);
//# sourceMappingURL=admin-1bab981afc4fd0d71402.js.map

View File

@ -0,0 +1,2 @@
webpackJsonp([69],{657:function(e,c,t){"use strict";function o(e){var c=e.detail,t=c[0],o=document.querySelector('[data-id="'+t.id+'"]');o&&o.parentNode.removeChild(o)}Object.defineProperty(c,"__esModule",{value:!0});var n=t(144);t.n(n);[].forEach.call(document.querySelectorAll(".trash-button"),function(e){e.addEventListener("ajax:success",o)});Object(n.delegate)(document,"#batch_checkbox_all","change",function(e){var c=e.target;[].forEach.call(document.querySelectorAll('.batch-checkbox input[type="checkbox"]'),function(e){e.checked=c.checked})}),Object(n.delegate)(document,'.batch-checkbox input[type="checkbox"]',"change",function(){var e=document.querySelector("#batch_checkbox_all");e&&(e.checked=[].every.call(document.querySelectorAll('.batch-checkbox input[type="checkbox"]'),function(e){return e.checked}))}),Object(n.delegate)(document,".media-spoiler-show-button","click",function(){[].forEach.call(document.querySelectorAll("button.media-spoiler"),function(e){e.click()})}),Object(n.delegate)(document,".media-spoiler-hide-button","click",function(){[].forEach.call(document.querySelectorAll(".spoiler-button.spoiler-button--visible button"),function(e){e.click()})})}},[657]);
//# sourceMappingURL=admin.js.map

File diff suppressed because one or more lines are too long

View File

@ -1,42 +1,45 @@
CACHE MANIFEST
#ver:11/12/2017, 12:40:57 PM
#ver:2018-4-1 11:28:19
#plugin:4.8.4
CACHE:
/packs/features/compose-4617f6e912b5bfa71c43.js
/packs/modals/onboarding_modal-399f44a19ddd0ddc4e9c.js
/packs/features/public_timeline-d6e6bc704f49ebf922be.js
/packs/features/community_timeline-20bc8a94c08809c127d0.js
/packs/features/hashtag_timeline-3ed7e7bf18fd2fc04c9e.js
/packs/emoji_picker-9cf581d158c1cefc73c9.js
/packs/features/notifications-99d27ff7a90c7f701400.js
/packs/features/home_timeline-c146f32b0118845677ee.js
/packs/features/account_timeline-cad2550e777d3958eca4.js
/packs/features/pinned_statuses-fc56dd5916a37286e823.js
/packs/features/favourited_statuses-b15a9a6cc711cca1eb76.js
/packs/features/status-1f1807fdb4d1fd6daf40.js
/packs/features/following-9060b3726e6ad25f3621.js
/packs/features/followers-6716b8606f70dfa12ed7.js
/packs/features/account_gallery-b13924812f8dd47200c2.js
/packs/modals/report_modal-7a2950f40d4867b9cbb0.js
/packs/features/follow_requests-281e5b40331385149920.js
/packs/features/mutes-60c139f123f8d11ed903.js
/packs/features/blocks-e9605338ea941de78465.js
/packs/features/reblogs-e284a8647e830c151a40.js
/packs/features/favourites-083fedd11007764f7fad.js
/packs/features/getting_started-b65f1e917d66a972f2bf.js
/packs/features/generic_not_found-dc757b4cfe00489a06fb.js
/packs/modals/embed_modal-c776fd6a0ea581675783.js
/packs/status/media_gallery-7642f779bf4243e58b78.js
/packs/application-1b1f37dff2aac402336b.js
/packs/share-914b479bea45d0f6d4aa.js
/packs/about-d6275c885cd0e28a1186.js
/packs/public-88b87539fc95f07f2721.js
/packs/default-99ffdcf166b2dedef105.js
/packs/admin-1bab981afc4fd0d71402.js
/packs/common-1789b98651001ef10c0b.js
/packs/common-daadaac9454e7d14470e7954e3143dca.css
/packs/default-818c1287ac3c764905d81e549d5e0160.css
/packs/base_polyfills.js
/packs/extra_polyfills.js
/packs/features/compose.js
/packs/modals/onboarding_modal.js
/packs/emoji_picker.js
/packs/features/notifications.js
/packs/features/account_timeline.js
/packs/features/home_timeline.js
/packs/features/public_timeline.js
/packs/features/community_timeline.js
/packs/features/favourited_statuses.js
/packs/features/list_timeline.js
/packs/features/following.js
/packs/features/followers.js
/packs/features/hashtag_timeline.js
/packs/features/status.js
/packs/features/account_gallery.js
/packs/features/blocks.js
/packs/features/follow_requests.js
/packs/features/reblogs.js
/packs/features/favourites.js
/packs/features/getting_started.js
/packs/features/keyboard_shortcuts.js
/packs/features/generic_not_found.js
/packs/features/list_editor.js
/packs/status/media_gallery.js
/packs/share.js
/packs/application.js
/packs/about.js
/packs/public.js
/packs/mailer.js
/packs/default.js
/packs/admin.js
/packs/common.js
/packs/common.css
/packs/mailer.css
/packs/default.css
/packs/manifest.json
NETWORK:

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1 @@
{"version":3,"sources":[],"names":[],"mappings":"","file":"common.css","sourceRoot":""}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,2 +0,0 @@
webpackJsonp([63],{748:function(n,c){}},[748]);
//# sourceMappingURL=default-99ffdcf166b2dedef105.js.map

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1 @@
{"version":3,"sources":[],"names":[],"mappings":"","file":"default.css","sourceRoot":""}

View File

@ -0,0 +1,2 @@
webpackJsonp([68],{799:function(n,c){}},[799]);
//# sourceMappingURL=default.js.map

View File

@ -0,0 +1 @@
{"version":3,"sources":["webpack:///default.js"],"names":["webpackJsonp","799","module","exports"],"mappings":"AAAAA,cAAc,KAERC,IACA,SAAUC,EAAQC,OAMrB","file":"default.js","sourcesContent":["webpackJsonp([68],{\n\n/***/ 799:\n/***/ (function(module, exports) {\n\n// removed by extract-text-webpack-plugin\n\n/***/ })\n\n},[799]);\n\n\n// WEBPACK FOOTER //\n// default.js"],"sourceRoot":""}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 142 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 11 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 17 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 11 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 8.3 KiB

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,2 +0,0 @@
webpackJsonp([24],{150:function(n,e,t){"use strict";t.d(e,"a",function(){return f});var i=t(2),r=t.n(i),o=t(1),a=t.n(o),c=t(3),l=t.n(c),u=t(4),s=t.n(u),d=t(0),p=t.n(d),f=function(n){function e(){var t,i,r;a()(this,e);for(var o=arguments.length,c=Array(o),u=0;u<o;u++)c[u]=arguments[u];return t=i=l()(this,n.call.apply(n,[this].concat(c))),i.handleClick=function(){i.props.onClick()},r=t,l()(i,r)}return s()(e,n),e.prototype.render=function(){var n=this.props,e=n.type,t=n.active,i=n.columnHeaderId,o="";return this.props.icon&&(o=r()("i",{className:"fa fa-fw fa-"+this.props.icon+" column-header__icon"})),r()("div",{role:"heading",tabIndex:"0",className:"column-header "+(t?"active":""),onClick:this.handleClick,id:i||null},void 0,o,e)},e}(p.a.PureComponent)},259:function(n,e,t){"use strict";t.d(e,"a",function(){return y});var i=t(2),r=t.n(i),o=t(1),a=t.n(o),c=t(3),l=t.n(c),u=t(4),s=t.n(u),d=t(42),p=t.n(d),f=t(0),h=t.n(f),v=t(150),m=t(91),b=t(33),y=function(n){function e(){var t,i,r;a()(this,e);for(var o=arguments.length,c=Array(o),u=0;u<o;u++)c[u]=arguments[u];return t=i=l()(this,n.call.apply(n,[this].concat(c))),i.handleHeaderClick=function(){var n=i.node.querySelector(".scrollable");n&&(i._interruptScrollAnimation=Object(m.b)(n))},i.handleScroll=p()(function(){void 0!==i._interruptScrollAnimation&&i._interruptScrollAnimation()},200),i.setRef=function(n){i.node=n},r=t,l()(i,r)}return s()(e,n),e.prototype.scrollTop=function(){var n=this.node.querySelector(".scrollable");n&&(this._interruptScrollAnimation=Object(m.b)(n))},e.prototype.render=function(){var n=this.props,e=n.heading,t=n.icon,i=n.children,o=n.active,a=n.hideHeadingOnMobile,c=e&&(!a||a&&!Object(b.b)(window.innerWidth)),l=c&&e.replace(/ /g,"-"),u=c&&r()(v.a,{icon:t,active:o,type:e,onClick:this.handleHeaderClick,columnHeaderId:l});return h.a.createElement("div",{ref:this.setRef,role:"region","aria-labelledby":l,className:"column",onScroll:this.handleScroll},u,i)},e}(h.a.PureComponent)},768:function(n,e,t){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=t(2),r=t.n(i),o=t(0),a=(t.n(o),t(259)),c=t(780),l=function(){return r()(a.a,{},void 0,r()(c.a,{}))};e.default=l},780:function(n,e,t){"use strict";var i=t(2),r=t.n(i),o=t(0),a=(t.n(o),t(6)),c=function(){return r()("div",{className:"missing-indicator"},void 0,r()("div",{},void 0,r()(a.b,{id:"missing_indicator.label",defaultMessage:"Not found"})))};e.a=c}});
//# sourceMappingURL=generic_not_found-dc757b4cfe00489a06fb.js.map

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,2 @@
webpackJsonp([23],{150:function(n,e,i){"use strict";i.d(e,"a",function(){return v});var t=i(2),r=i.n(t),o=i(1),a=i.n(o),c=i(3),l=i.n(c),u=i(4),s=i.n(u),d=i(0),f=i.n(d),h=i(10),p=i.n(h),v=function(n){function e(){var i,t,r;a()(this,e);for(var o=arguments.length,c=Array(o),u=0;u<o;u++)c[u]=arguments[u];return i=t=l()(this,n.call.apply(n,[this].concat(c))),t.handleClick=function(){t.props.onClick()},r=i,l()(t,r)}return s()(e,n),e.prototype.render=function(){var n=this.props,e=n.icon,i=n.type,t=n.active,o=n.columnHeaderId,a="";return e&&(a=r()("i",{className:"fa fa-fw fa-"+e+" column-header__icon"})),r()("h1",{className:p()("column-header",{active:t}),id:o||null},void 0,r()("button",{onClick:this.handleClick},void 0,a,i))},e}(f.a.PureComponent)},283:function(n,e,i){"use strict";i.d(e,"a",function(){return g});var t=i(2),r=i.n(t),o=i(1),a=i.n(o),c=i(3),l=i.n(c),u=i(4),s=i.n(u),d=i(34),f=i.n(d),h=i(0),p=i.n(h),v=i(150),b=i(90),m=i(35),g=function(n){function e(){var i,t,r;a()(this,e);for(var o=arguments.length,c=Array(o),u=0;u<o;u++)c[u]=arguments[u];return i=t=l()(this,n.call.apply(n,[this].concat(c))),t.handleHeaderClick=function(){var n=t.node.querySelector(".scrollable");n&&(t._interruptScrollAnimation=Object(b.b)(n))},t.handleScroll=f()(function(){void 0!==t._interruptScrollAnimation&&t._interruptScrollAnimation()},200),t.setRef=function(n){t.node=n},r=i,l()(t,r)}return s()(e,n),e.prototype.scrollTop=function(){var n=this.node.querySelector(".scrollable");n&&(this._interruptScrollAnimation=Object(b.b)(n))},e.prototype.render=function(){var n=this.props,e=n.heading,i=n.icon,t=n.children,o=n.active,a=n.hideHeadingOnMobile,c=e&&(!a||a&&!Object(m.b)(window.innerWidth)),l=c&&e.replace(/ /g,"-"),u=c&&r()(v.a,{icon:i,active:o,type:e,onClick:this.handleHeaderClick,columnHeaderId:l});return p.a.createElement("div",{ref:this.setRef,role:"region","aria-labelledby":l,className:"column",onScroll:this.handleScroll},u,t)},e}(p.a.PureComponent)},820:function(n,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var t=i(2),r=i.n(t),o=i(0),a=(i.n(o),i(283)),c=i(843),l=function(){return r()(a.a,{},void 0,r()(c.a,{}))};e.default=l},843:function(n,e,i){"use strict";var t=i(2),r=i.n(t),o=i(0),a=(i.n(o),i(6)),c=function(){return r()("div",{className:"regeneration-indicator missing-indicator"},void 0,r()("div",{},void 0,r()("div",{className:"regeneration-indicator__label"},void 0,r()(a.b,{id:"missing_indicator.label",tagName:"strong",defaultMessage:"Not found"}),r()(a.b,{id:"missing_indicator.sublabel",defaultMessage:"This resource could not be found"}))))};e.a=c}});
//# sourceMappingURL=generic_not_found.js.map

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Some files were not shown because too many files have changed in this diff Show More