diff --git a/CHANGELOG.md b/CHANGELOG.md
index a6118a90e..93caaaafa 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -19,7 +19,6 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- Update lighthouse search api _community pr!_ ([#6731](https://github.com/lbryio/lbry-desktop/pull/6731))
- Update sockety api _community pr!_ ([#6747](https://github.com/lbryio/lbry-desktop/pull/6747))
- Use resolve for OG metadata instead of chainquery _community pr!_ ([#6787](https://github.com/lbryio/lbry-desktop/pull/6787))
-- Improved clickability of notification links _community pr!_ ([#6711](https://github.com/lbryio/lbry-desktop/pull/6711))
### Fixed
- App now supports '#' and ':' for claimId separator ([#6496](https://github.com/lbryio/lbry-desktop/pull/6496))
diff --git a/ui/component/app/view.jsx b/ui/component/app/view.jsx
index aadc719e4..4ab5d4fbf 100644
--- a/ui/component/app/view.jsx
+++ b/ui/component/app/view.jsx
@@ -5,7 +5,7 @@ import { lazyImport } from 'util/lazyImport';
import classnames from 'classnames';
import analytics from 'analytics';
import { buildURI, parseURI } from 'lbry-redux';
-import { SIMPLE_SITE, ENABLE_PREROLL_ADS } from 'config';
+import { SIMPLE_SITE } from 'config';
import Router from 'component/router/index';
import ReactModal from 'react-modal';
import { openContextMenu } from 'util/context-menu';
@@ -325,23 +325,6 @@ function App(props: Props) {
}
}, [previousRewardApproved, isRewardApproved]);
- // Load IMA3 SDK for aniview
- // @if TARGET='web'
- useEffect(() => {
- if (ENABLE_PREROLL_ADS) {
- const script = document.createElement('script');
- script.src = `https://imasdk.googleapis.com/js/sdkloader/ima3.js`;
- script.async = true;
- // $FlowFixMe
- document.body.appendChild(script);
- return () => {
- // $FlowFixMe
- document.body.removeChild(script);
- };
- }
- });
- // @endif
-
// @if TARGET='app'
useEffect(() => {
if (updatePreferences && getWalletSyncPref && readyForPrefs) {
diff --git a/ui/component/collectionsListMine/index.js b/ui/component/collectionsListMine/index.js
index d4b92bf2a..92bd2f2f7 100644
--- a/ui/component/collectionsListMine/index.js
+++ b/ui/component/collectionsListMine/index.js
@@ -9,7 +9,7 @@ import CollectionsListMine from './view';
const select = (state) => ({
builtinCollections: selectBuiltinCollections(state),
- publishedPlaylists: selectMyPublishedPlaylistCollections(state),
+ publishedCollections: selectMyPublishedPlaylistCollections(state),
unpublishedCollections: selectMyUnpublishedCollections(state),
// savedCollections: selectSavedCollections(state),
});
diff --git a/ui/component/collectionsListMine/view.jsx b/ui/component/collectionsListMine/view.jsx
index 45b3b6c96..ee3be8b17 100644
--- a/ui/component/collectionsListMine/view.jsx
+++ b/ui/component/collectionsListMine/view.jsx
@@ -8,48 +8,78 @@ import Icon from 'component/common/icon';
import * as ICONS from 'constants/icons';
import * as PAGES from 'constants/pages';
import Yrbl from 'component/yrbl';
-import usePersistedState from 'effects/use-persisted-state';
-import Card from 'component/common/card';
import classnames from 'classnames';
+import { FormField, Form } from 'component/common/form';
type Props = {
builtinCollections: CollectionGroup,
publishedCollections: CollectionGroup,
- publishedPlaylists: CollectionGroup,
+ publishedCollections: CollectionGroup,
unpublishedCollections: CollectionGroup,
// savedCollections: CollectionGroup,
};
+const ALL = 'All';
+const PRIVATE = 'Private';
+const PUBLIC = 'Public';
+const COLLECTION_FILTERS = [ALL, PRIVATE, PUBLIC];
+
export default function CollectionsListMine(props: Props) {
const {
builtinCollections,
- publishedPlaylists,
+ publishedCollections,
unpublishedCollections,
// savedCollections, these are resolved on startup from sync'd claimIds or urls
} = props;
const builtinCollectionsList = (Object.values(builtinCollections || {}): any);
const unpublishedCollectionsList = (Object.keys(unpublishedCollections || {}): any);
- const publishedList = (Object.keys(publishedPlaylists || {}): any);
+ const publishedList = (Object.keys(publishedCollections || {}): any);
const hasCollections = unpublishedCollectionsList.length || publishedList.length;
+ const [filterType, setFilterType] = React.useState(ALL);
+ const [searchText, setSearchText] = React.useState('');
+
+ let collectionsToShow = [];
+ if (filterType === ALL) {
+ collectionsToShow = unpublishedCollectionsList.concat(publishedList);
+ } else if (filterType === PRIVATE) {
+ collectionsToShow = unpublishedCollectionsList;
+ } else if (filterType === PUBLIC) {
+ collectionsToShow = publishedList;
+ }
+
+ let filteredCollections;
+ if (searchText && collectionsToShow) {
+ filteredCollections = collectionsToShow.filter((id) => {
+ return (
+ (unpublishedCollections[id] &&
+ unpublishedCollections[id].name.toLocaleLowerCase().includes(searchText.toLocaleLowerCase())) ||
+ (publishedCollections[id] &&
+ publishedCollections[id].name.toLocaleLowerCase().includes(searchText.toLocaleLowerCase()))
+ );
+ });
+ } else {
+ filteredCollections = collectionsToShow || [];
+ }
const watchLater = builtinCollectionsList.find((list) => list.id === COLLECTIONS_CONSTS.WATCH_LATER_ID);
const favorites = builtinCollectionsList.find((list) => list.id === COLLECTIONS_CONSTS.FAVORITES_ID);
const builtin = [watchLater, favorites];
- const [showHelp, setShowHelp] = usePersistedState('livestream-help-seen', true);
+ function escapeListener(e: SyntheticKeyboardEvent<*>) {
+ const KEYCODE_ESCAPE = 27;
+ if (e.keyCode === KEYCODE_ESCAPE) {
+ e.preventDefault();
+ setSearchText('');
+ }
+ }
- const helpText = (
-
-
{__(`Everyone starts with 2 private lists - Watch Later and Favorites.`)}
-
{__(`Add content to existing lists or new lists from content pages or content previews.`)}
-
- {__(
- `By default, lists are private. You can edit them and later publish them from the Lists page or the Publish context menu on this page. Similar to uploads, small blockchain fees apply.`
- )}
-