diff options
author | ThibG <thib@sitedethib.com> | 2019-01-13 10:23:54 +0100 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2019-01-13 09:23:54 +0000 |
commit | 4fb94c758e3bf2e1c0525e9075c2d5dedc14c666 (patch) | |
tree | c08ae8ba9144ece107fac0893ea055a7079edcd1 /app/javascript | |
parent | 9ee9cb549b58a33a81a9da318cbdc26ed2e47788 (diff) |
Add attachment list fallback to public pages (#9780)
* Add attachment list fallback to public pages Fixes #6714 * Refactor attachments lists
Diffstat (limited to 'app/javascript')
-rw-r--r-- | app/javascript/packs/public.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/javascript/packs/public.js b/app/javascript/packs/public.js index a9a3d738a..a86dc7831 100644 --- a/app/javascript/packs/public.js +++ b/app/javascript/packs/public.js @@ -83,6 +83,12 @@ function main() { if (reactComponents.length > 0) { import(/* webpackChunkName: "containers/media_container" */ '../mastodon/containers/media_container') .then(({ default: MediaContainer }) => { + [].forEach.call(reactComponents, (component) => { + [].forEach.call(component.children, (child) => { + component.removeChild(child); + }); + }); + const content = document.createElement('div'); ReactDOM.render(<MediaContainer locale={locale} components={reactComponents} />, content); |