diff --git a/src/ui/component/claimList/view.jsx b/src/ui/component/claimList/view.jsx
index 9b7014405..859fe9967 100644
--- a/src/ui/component/claimList/view.jsx
+++ b/src/ui/component/claimList/view.jsx
@@ -21,6 +21,7 @@ type Props = {
empty?: string,
defaultSort?: boolean,
onScrollBottom?: any => void,
+ page?: number,
// If using the default header, this is a unique ID needed to persist the state of the filter setting
persistedStorageKey?: string,
};
@@ -37,6 +38,7 @@ export default function ClaimList(props: Props) {
type,
header,
onScrollBottom,
+ page,
} = props;
const [currentSort, setCurrentSort] = usePersistedState(persistedStorageKey, SORT_NEW);
const hasUris = uris && !!uris.length;
@@ -101,7 +103,7 @@ export default function ClaimList(props: Props) {
{sortedUris.map((uri, index) => (
-
+
{index === 4 && injectedItem && - {injectedItem}
}
))}
diff --git a/src/ui/component/claimListDiscover/view.jsx b/src/ui/component/claimListDiscover/view.jsx
index 08af75482..c342c52b1 100644
--- a/src/ui/component/claimListDiscover/view.jsx
+++ b/src/ui/component/claimListDiscover/view.jsx
@@ -155,6 +155,7 @@ function ClaimListDiscover(props: Props) {
header={header}
headerAltControls={meta}
onScrollBottom={() => setPage(page + 1)}
+ page={page}
/>
{loading && page > 1 && new Array(PAGE_SIZE).fill(1).map((x, i) => )}
diff --git a/src/ui/component/claimPreview/index.js~HEAD b/src/ui/component/claimPreview/index.js~HEAD
deleted file mode 100644
index 6d08b46e0..000000000
--- a/src/ui/component/claimPreview/index.js~HEAD
+++ /dev/null
@@ -1,35 +0,0 @@
-import { connect } from 'react-redux';
-import {
- doResolveUri,
- makeSelectClaimForUri,
- makeSelectIsUriResolving,
- makeSelectClaimIsMine,
- makeSelectClaimIsPending,
- makeSelectThumbnailForUri,
- makeSelectTitleForUri,
- makeSelectClaimIsNsfw,
-} from 'lbry-redux';
-import { selectBlackListedOutpoints } from 'lbryinc';
-import { selectShowNsfw } from 'redux/selectors/settings';
-import ClaimPreview from './view';
-
-const select = (state, props) => ({
- pending: makeSelectClaimIsPending(props.uri)(state),
- claim: makeSelectClaimForUri(props.uri)(state),
- obscureNsfw: !selectShowNsfw(state),
- claimIsMine: makeSelectClaimIsMine(props.uri)(state),
- isResolvingUri: makeSelectIsUriResolving(props.uri)(state),
- thumbnail: makeSelectThumbnailForUri(props.uri)(state),
- title: makeSelectTitleForUri(props.uri)(state),
- nsfw: makeSelectClaimIsNsfw(props.uri)(state),
- blackListedOutpoints: selectBlackListedOutpoints(state),
-});
-
-const perform = dispatch => ({
- resolveUri: uri => dispatch(doResolveUri(uri)),
-});
-
-export default connect(
- select,
- perform
-)(ClaimPreview);
diff --git a/src/ui/component/claimPreview/view.jsx b/src/ui/component/claimPreview/view.jsx
index 9eeeaaa1a..839d79f27 100644
--- a/src/ui/component/claimPreview/view.jsx
+++ b/src/ui/component/claimPreview/view.jsx
@@ -92,7 +92,7 @@ function ClaimPreview(props: Props) {
return null;
}
- if (placeholder && !claim) {
+ if (placeholder || isResolvingUri) {
return (
-
diff --git a/src/ui/redux/actions/app.js b/src/ui/redux/actions/app.js
index 7be2c2f73..db18e0fed 100644
--- a/src/ui/redux/actions/app.js
+++ b/src/ui/redux/actions/app.js
@@ -24,6 +24,7 @@ import {
import { doAuthenticate } from 'lbryinc';
import { lbrySettings as config, version as appVersion } from 'package.json';
import { push } from 'connected-react-router';
+import { whiteListedReducers } from 'store';
// @if TARGET='app'
const { autoUpdater } = remote.require('electron-updater');
@@ -327,7 +328,8 @@ export function doDaemonReady() {
export function doClearCache() {
return () => {
- window.cacheStore.purge();
+ const reducersToClear = whiteListedReducers.filter(reducerKey => reducerKey !== 'tags');
+ window.cacheStore.purge(reducersToClear);
return Promise.resolve();
};
diff --git a/src/ui/scss/component/_placeholder.scss b/src/ui/scss/component/_placeholder.scss
index b86928c38..678984fab 100644
--- a/src/ui/scss/component/_placeholder.scss
+++ b/src/ui/scss/component/_placeholder.scss
@@ -18,6 +18,6 @@
margin-top: var(--spacing-small);
width: 30%;
- height: 2em;
+ height: 1.5em;
}
}
diff --git a/src/ui/store.js b/src/ui/store.js
index 1825afe9b..0b48beaa8 100644
--- a/src/ui/store.js
+++ b/src/ui/store.js
@@ -74,20 +74,20 @@ const appFilter = createFilter('app', ['hasClickedComment', 'searchOptionsExpand
// We only need to persist the receiveAddress for the wallet
const walletFilter = createFilter('wallet', ['receiveAddress']);
const searchFilter = createFilter('search', ['options']);
-
+const whiteListedReducers = [
+ // @if TARGET='app'
+ 'publish',
+ 'wallet',
+ 'fileInfo',
+ // @endif
+ 'content',
+ 'subscriptions',
+ 'app',
+ 'search',
+ 'tags',
+];
const persistOptions = {
- whitelist: [
- // @if TARGET='app'
- 'publish',
- 'wallet',
- 'fileInfo',
- // @endif
- 'content',
- 'subscriptions',
- 'app',
- 'search',
- 'tags',
- ],
+ whitelist: whiteListedReducers,
// Order is important. Needs to be compressed last or other transforms can't
// read the data
transforms: [
@@ -110,4 +110,4 @@ window.cacheStore = persistStore(store, persistOptions, err => {
}
});
-export { store, history };
+export { store, history, whiteListedReducers };
diff --git a/static/locales/en.json b/static/locales/en.json
index 2c0f875b0..89c4925f4 100644
--- a/static/locales/en.json
+++ b/static/locales/en.json
@@ -292,6 +292,7 @@
"Comment": "Comment",
"Your comment": "Your comment",
"Post": "Post",
+<<<<<<< HEAD
"No modifier provided after separator %s.": "No modifier provided after separator %s.",
"Incompatible Daemon": "Incompatible Daemon",
"Incompatible daemon running": "Incompatible daemon running",
@@ -308,6 +309,9 @@
"Your version is out of date and may be unreliable or insecure.": "Your version is out of date and may be unreliable or insecure.",
"Want to know what has changed?": "Want to know what has changed?",
"release notes": "release notes",
+=======
+ "You haven't downloaded anything from LBRY yet.": "You haven't downloaded anything from LBRY yet.",
+>>>>>>> ca0fd40a... add placeholders to claim previews
"Read the FAQ": "Read the FAQ",
"Our FAQ answers many common questions.": "Our FAQ answers many common questions.",
"Get Live Help": "Get Live Help",