diff --git a/ui/component/claimRepostAuthor/view.jsx b/ui/component/claimRepostAuthor/view.jsx
index 7634ac582..4525560b0 100644
--- a/ui/component/claimRepostAuthor/view.jsx
+++ b/ui/component/claimRepostAuthor/view.jsx
@@ -47,7 +47,7 @@ function ClaimRepostAuthor(props: Props) {
return (
-
+
}}>
%repost_channel_link% reposted
diff --git a/ui/component/comment/view.jsx b/ui/component/comment/view.jsx
index 61b042b8a..955039988 100644
--- a/ui/component/comment/view.jsx
+++ b/ui/component/comment/view.jsx
@@ -20,6 +20,7 @@ import CommentsReplies from 'component/commentsReplies';
import { useHistory } from 'react-router';
import CommentCreate from 'component/commentCreate';
import CommentMenuList from 'component/commentMenuList';
+import UriIndicator from 'component/uriIndicator';
type Props = {
closeInlinePlayer: () => void,
@@ -33,7 +34,7 @@ type Props = {
claimIsMine: boolean, // if you control the claim which this comment was posted on
commentIsMine: boolean, // if this comment was signed by an owned channel
updateComment: (string, string) => void,
- commentModBlock: string => void,
+ commentModBlock: (string) => void,
linkedComment?: any,
myChannels: ?Array
,
commentingEnabled: boolean,
@@ -105,7 +106,7 @@ function Comment(props: Props) {
setCharCount(editedMessage.length);
// a user will try and press the escape key to cancel editing their comment
- const handleEscape = event => {
+ const handleEscape = (event) => {
if (event.keyCode === ESCAPE_KEY) {
setEditing(false);
}
@@ -180,11 +181,7 @@ function Comment(props: Props) {
{!author ? (
{__('Anonymous')}
) : (
-
+
)}
),
+ [ICONS.CHANNEL_LEVEL_1]: (props: CustomProps) => (
+
+ ),
+ [ICONS.CHANNEL_LEVEL_2]: (props: CustomProps) => (
+
+ ),
+ [ICONS.CHANNEL_LEVEL_3]: (props: CustomProps) => (
+
+ ),
+ [ICONS.CHANNEL_LEVEL_4]: (props: CustomProps) => (
+
+ ),
+ [ICONS.CHANNEL_LEVEL_5]: (props: CustomProps) => (
+
+ ),
};
diff --git a/ui/component/common/lbc-symbol.jsx b/ui/component/common/lbc-symbol.jsx
index 9fd879301..1e841739e 100644
--- a/ui/component/common/lbc-symbol.jsx
+++ b/ui/component/common/lbc-symbol.jsx
@@ -1,4 +1,5 @@
// @flow
+import type { Node } from 'react';
import * as ICONS from 'constants/icons';
import React from 'react';
import classnames from 'classnames';
@@ -8,8 +9,8 @@ type Props = {
withText?: boolean,
isTitle?: boolean,
size?: number,
- prefix?: string | number,
- postfix?: string | number,
+ prefix?: string | number | Node,
+ postfix?: string | number | Node,
};
const LbcSymbol = (props: Props) => {
diff --git a/ui/component/common/tooltip.jsx b/ui/component/common/tooltip.jsx
index b3fa33992..1d52bf8db 100644
--- a/ui/component/common/tooltip.jsx
+++ b/ui/component/common/tooltip.jsx
@@ -1,6 +1,8 @@
// @flow
import type { Node } from 'react';
import React from 'react';
+import ReachTooltip from '@reach/tooltip';
+import '@reach/tooltip/styles.css';
type Props = {
label: string | Node,
@@ -10,11 +12,7 @@ type Props = {
function Tooltip(props: Props) {
const { children, label } = props;
- if (typeof label !== 'string') {
- return children;
- }
-
- return {children};
+ return {children};
}
export default Tooltip;
diff --git a/ui/component/fileThumbnail/FreezeframeLite/styles.scss b/ui/component/fileThumbnail/FreezeframeLite/styles.scss
index 4430db501..7eab7838b 100644
--- a/ui/component/fileThumbnail/FreezeframeLite/styles.scss
+++ b/ui/component/fileThumbnail/FreezeframeLite/styles.scss
@@ -23,7 +23,6 @@ $transition-duration: 300ms;
top: 0;
left: 0;
pointer-events: none;
- z-index: $base-zindex + 1;
vertical-align: top;
opacity: 0;
diff --git a/ui/component/fileThumbnail/FreezeframeWrapper.jsx b/ui/component/fileThumbnail/FreezeframeWrapper.jsx
index fb32c846b..2c2ec9afd 100644
--- a/ui/component/fileThumbnail/FreezeframeWrapper.jsx
+++ b/ui/component/fileThumbnail/FreezeframeWrapper.jsx
@@ -3,7 +3,7 @@ import classnames from 'classnames';
import PropTypes from 'prop-types';
import Freezeframe from './FreezeframeLite';
-const FreezeframeWrapper = props => {
+const FreezeframeWrapper = (props) => {
const imgRef = React.useRef();
const freezeframe = React.useRef();
// eslint-disable-next-line
diff --git a/ui/component/router/view.jsx b/ui/component/router/view.jsx
index 61f08ebb9..4fe537452 100644
--- a/ui/component/router/view.jsx
+++ b/ui/component/router/view.jsx
@@ -70,17 +70,17 @@ type Props = {
index: number,
length: number,
location: { pathname: string },
- push: string => void,
+ push: (string) => void,
state: {},
replaceState: ({}, string, string) => void,
- listen: any => () => void,
+ listen: (any) => () => void,
},
uri: string,
title: string,
welcomeVersion: number,
hasNavigated: boolean,
setHasNavigated: () => void,
- setReferrer: string => void,
+ setReferrer: (string) => void,
hasUnclaimedRefereeReward: boolean,
homepageData: any,
};
@@ -95,7 +95,7 @@ function PrivateRoute(props: PrivateRouteProps) {
return (
+ render={(props) =>
isAuthenticated || !IS_WEB ? (
) : (
@@ -220,7 +220,7 @@ function AppRouter(props: Props) {
}
+ component={(routerProps) => }
/>
))}
diff --git a/ui/component/uriIndicator/view.jsx b/ui/component/uriIndicator/view.jsx
index 58c6addba..03484b0a0 100644
--- a/ui/component/uriIndicator/view.jsx
+++ b/ui/component/uriIndicator/view.jsx
@@ -9,11 +9,10 @@ type Props = {
channelUri: ?string,
link: ?boolean,
claim: ?Claim,
-
hideAnonymous: boolean,
// Lint thinks we aren't using these, even though we are.
// Possibly because the resolve function is an arrow function that is passed in props?
- resolveUri: string => void,
+ resolveUri: (string) => void,
uri: string,
// to allow for other elements to be nested within the UriIndicator
children: ?Node,
diff --git a/ui/component/wunderbarSuggestion/view.jsx b/ui/component/wunderbarSuggestion/view.jsx
index ee274734b..032d31991 100644
--- a/ui/component/wunderbarSuggestion/view.jsx
+++ b/ui/component/wunderbarSuggestion/view.jsx
@@ -28,7 +28,7 @@ export default function WunderbarSuggestion(props: Props) {
>
{isChannel ? : }
- {claim.value.title}
+ {claim.value.title}
{isChannel ? claim.name : (claim.signing_channel && claim.signing_channel.name) || __('Anonymous')}
diff --git a/ui/constants/icons.js b/ui/constants/icons.js
index 99cb6df27..df733f879 100644
--- a/ui/constants/icons.js
+++ b/ui/constants/icons.js
@@ -131,3 +131,8 @@ export const BEST = 'Best';
export const CREATOR_LIKE = 'CreatorLike';
export const CHEF = 'Chef';
export const ANONYMOUS = 'Anonymous';
+export const CHANNEL_LEVEL_1 = 'ChannelLevel1';
+export const CHANNEL_LEVEL_2 = 'ChannelLevel2';
+export const CHANNEL_LEVEL_3 = 'ChannelLevel3';
+export const CHANNEL_LEVEL_4 = 'ChannelLevel4';
+export const CHANNEL_LEVEL_5 = 'ChannelLevel5';
diff --git a/ui/page/channel/view.jsx b/ui/page/channel/view.jsx
index 56c02f1b0..c48ec52b7 100644
--- a/ui/page/channel/view.jsx
+++ b/ui/page/channel/view.jsx
@@ -21,6 +21,7 @@ import ChannelEdit from 'component/channelEdit';
import classnames from 'classnames';
import HelpLink from 'component/common/help-link';
import ClaimSupportButton from 'component/claimSupportButton';
+import ChannelStakedIndicator from 'component/channelStakedIndicator';
export const PAGE_VIEW_QUERY = `view`;
const ABOUT_PAGE = `about`;
@@ -42,7 +43,7 @@ type Props = {
txid: string,
nout: number,
}>,
- fetchSubCount: string => void,
+ fetchSubCount: (string) => void,
subCount: number,
pending: boolean,
youtubeChannels: ?Array<{ channel_claim_id: string, sync_status: string, transfer_state: string }>,
@@ -93,7 +94,7 @@ function ChannelPage(props: Props) {
if (claim && blackListedOutpoints) {
channelIsBlackListed = blackListedOutpoints.some(
- outpoint => outpoint.txid === claim.txid && outpoint.nout === claim.nout
+ (outpoint) => outpoint.txid === claim.txid && outpoint.nout === claim.nout
);
}
@@ -171,8 +172,12 @@ function ChannelPage(props: Props) {
uri={uri}
obscure={channelIsBlocked}
allowGifs
+ hideStakedIndicator
/>
- {title || '@' + channelName}
+
+ {title || '@' + channelName}
+
+
{formattedSubCount} {subCount !== 1 ? __('Followers') : __('Follower')}
@@ -198,6 +203,7 @@ function ChannelPage(props: Props) {
+
{__('Content')}
diff --git a/ui/redux/selectors/search.js b/ui/redux/selectors/search.js
index ce60b4405..7c9dcbf46 100644
--- a/ui/redux/selectors/search.js
+++ b/ui/redux/selectors/search.js
@@ -17,22 +17,25 @@ type State = { search: SearchState };
export const selectState = (state: State): SearchState => state.search;
-export const selectSearchValue: (state: State) => string = createSelector(selectState, state => state.searchQuery);
+export const selectSearchValue: (state: State) => string = createSelector(selectState, (state) => state.searchQuery);
-export const selectSearchOptions: (state: State) => SearchOptions = createSelector(selectState, state => state.options);
+export const selectSearchOptions: (state: State) => SearchOptions = createSelector(
+ selectState,
+ (state) => state.options
+);
-export const selectIsSearching: (state: State) => boolean = createSelector(selectState, state => state.searching);
+export const selectIsSearching: (state: State) => boolean = createSelector(selectState, (state) => state.searching);
export const selectSearchUrisByQuery: (state: State) => { [string]: Array } = createSelector(
selectState,
- state => state.urisByQuery
+ (state) => state.urisByQuery
);
export const makeSelectSearchUris = (query: string): ((state: State) => Array) =>
// replace statement below is kind of ugly, and repeated in doSearch action
createSelector(
selectSearchUrisByQuery,
- byQuery => byQuery[query ? query.replace(/^lbry:\/\//i, '').replace(/\//, ' ') : query]
+ (byQuery) => byQuery[query ? query.replace(/^lbry:\/\//i, '').replace(/\//, ' ') : query]
);
// Creates a query string based on the state in the search reducer
@@ -82,7 +85,7 @@ export const makeSelectRecommendedContentForUri = (uri: string) =>
let searchUris = searchUrisByQuery[searchQuery];
if (searchUris) {
- searchUris = searchUris.filter(searchUri => searchUri !== currentUri);
+ searchUris = searchUris.filter((searchUri) => searchUri !== currentUri);
recommendedContent = searchUris;
}
}
diff --git a/ui/scss/all.scss b/ui/scss/all.scss
index c7bb2f7fa..cba01e29b 100644
--- a/ui/scss/all.scss
+++ b/ui/scss/all.scss
@@ -50,10 +50,10 @@
@import 'component/spinner';
@import 'component/splash';
@import 'component/status-bar';
-@import 'component/subscriptions';
@import 'component/syntax-highlighter';
@import 'component/table';
@import 'component/tabs';
+@import 'component/tooltip';
@import 'component/txo-list';
@import 'component/tags';
@import 'component/wunderbar';
diff --git a/ui/scss/component/_channel.scss b/ui/scss/component/_channel.scss
index a11638f0f..4669ea680 100644
--- a/ui/scss/component/_channel.scss
+++ b/ui/scss/component/_channel.scss
@@ -61,6 +61,7 @@ $metadata-z-index: 1;
.channel-thumbnail {
display: flex;
+ position: relative;
height: 5rem;
width: 5rem;
background-size: cover;
@@ -166,7 +167,7 @@ $metadata-z-index: 1;
// Quick hack to get this to work
// We should have a generic style for "header with button next to it"
.button {
- margin-left: var(--spacing-m);
+ margin-left: var(--spacing-xs);
}
@media (max-width: $breakpoint-small) {
@@ -351,3 +352,59 @@ $metadata-z-index: 1;
margin-bottom: var(--spacing-l);
}
}
+
+.channel-staked__tooltip {
+ display: flex;
+ align-items: center;
+}
+
+.channel-staked__tooltip-text {
+ margin-left: var(--spacing-xs);
+ font-size: var(--font-xsmall);
+
+ .icon--LBC {
+ opacity: 0.7;
+ margin-top: -2px;
+ }
+}
+
+.channel-staked__wrapper {
+ display: flex;
+ position: absolute;
+ bottom: -0.9rem;
+ left: -0.9rem;
+ padding: 0.25rem;
+ background-color: var(--color-card-background);
+ border-radius: 50%;
+}
+
+.channel-staked__wrapper--large {
+ position: relative;
+ background-color: transparent;
+ display: inline-block;
+ bottom: auto;
+ left: auto;
+ top: var(--spacing-xs);
+ margin-left: var(--spacing-s);
+ padding: 0;
+}
+
+.channel-staked__indicator {
+ margin-left: 2px;
+ z-index: 3;
+ fill: var(--color-gray-3);
+}
+
+.channel-staked__indicator--controlling {
+ fill: #00eaff;
+}
+
+.channel-staked__amount {
+ display: inline-block;
+ font-size: var(--font-xxsmall);
+ margin-left: var(--spacing-s);
+
+ .credit-amount {
+ color: var(--color-gray-3);
+ }
+}
diff --git a/ui/scss/component/_claim-list.scss b/ui/scss/component/_claim-list.scss
index b44f6c47a..f76fe3c33 100644
--- a/ui/scss/component/_claim-list.scss
+++ b/ui/scss/component/_claim-list.scss
@@ -169,6 +169,11 @@
.channel-thumbnail {
@include handleChannelGif(4rem);
}
+
+ .media__subtitle {
+ display: flex;
+ flex-direction: column;
+ }
}
.claim-preview--pending {
@@ -242,6 +247,11 @@
.claim-preview-info {
align-items: flex-start;
+
+ .channel-thumbnail {
+ @include handleChannelGif(1.4rem);
+ margin-right: 0;
+ }
}
.claim-preview-info,
@@ -425,10 +435,6 @@
&:nth-child(3n + 1) {
margin-left: 0;
}
-
- .channel-thumbnail {
- display: none;
- }
}
@media (max-width: $breakpoint-small) {
@@ -526,11 +532,11 @@
transform: translateY(calc(var(--spacing-xs) * -1));
font-size: var(--font-xsmall);
color: var(--color-text-subtitle);
+}
- .icon {
- margin-right: var(--spacing-xxs);
- margin-bottom: -1px; // Offset it slightly because it doesn't look aligned next to all lowercase text + the @ from a channel
- }
+.claim-preview__repost-icon {
+ margin-right: var(--spacing-xxs);
+ margin-bottom: -1px; // Offset it slightly because it doesn't look aligned next to all lowercase text + the @ from a channel
}
.claim-tile__repost-author {
diff --git a/ui/scss/component/_comments.scss b/ui/scss/component/_comments.scss
index c95e37298..4a5f3f33d 100644
--- a/ui/scss/component/_comments.scss
+++ b/ui/scss/component/_comments.scss
@@ -204,6 +204,7 @@ $thumbnailWidthSmall: 0rem;
opacity: 0.5;
white-space: nowrap;
height: 100%;
+ margin-left: var(--spacing-xs);
&:focus {
@include linkFocus;
diff --git a/ui/scss/component/_header.scss b/ui/scss/component/_header.scss
index 292d383db..7a9849562 100644
--- a/ui/scss/component/_header.scss
+++ b/ui/scss/component/_header.scss
@@ -46,10 +46,6 @@
display: flex;
justify-content: space-between;
align-items: center;
-
- > .button:only-child {
- margin-left: auto;
- }
}
.header__buttons {
@@ -133,6 +129,7 @@
.header__navigation-item--balance {
@extend .button--link;
+ margin-left: var(--spacing-m);
}
.header__navigation-item--forward {
diff --git a/ui/scss/component/_media.scss b/ui/scss/component/_media.scss
index 65f8fab03..e62e7734a 100644
--- a/ui/scss/component/_media.scss
+++ b/ui/scss/component/_media.scss
@@ -40,8 +40,10 @@
color: var(--color-text-subtitle);
font-size: var(--font-small);
- svg {
- stroke: var(--color-text-subtitle);
+ .channel-thumbnail {
+ display: inline-block;
+ @include handleChannelGif(1rem);
+ margin-right: var(--spacing-xs);
}
}
diff --git a/ui/scss/component/_subscriptions.scss b/ui/scss/component/_subscriptions.scss
deleted file mode 100644
index 5c5b23e74..000000000
--- a/ui/scss/component/_subscriptions.scss
+++ /dev/null
@@ -1,4 +0,0 @@
-.subscriptions__suggested {
- animation: expand 0.2s;
- position: relative;
-}
diff --git a/ui/scss/component/_tooltip.scss b/ui/scss/component/_tooltip.scss
new file mode 100644
index 000000000..2013b410a
--- /dev/null
+++ b/ui/scss/component/_tooltip.scss
@@ -0,0 +1,8 @@
+[data-reach-tooltip] {
+ border-radius: var(--border-radius);
+ background-color: var(--color-tooltip-bg);
+ color: var(--color-tooltip-text);
+ border: none;
+ padding: var(--spacing-s);
+ overflow: hidden;
+}
diff --git a/ui/scss/component/_wunderbar.scss b/ui/scss/component/_wunderbar.scss
index 7ab899620..3eabf08ca 100644
--- a/ui/scss/component/_wunderbar.scss
+++ b/ui/scss/component/_wunderbar.scss
@@ -170,6 +170,9 @@
font-size: var(--font-small);
min-width: 0;
white-space: nowrap;
+}
+
+.wunderbar__suggestion-title {
overflow: hidden;
text-overflow: ellipsis;
}
diff --git a/ui/scss/themes/dark.scss b/ui/scss/themes/dark.scss
index 2f4e87d2f..e692394a7 100644
--- a/ui/scss/themes/dark.scss
+++ b/ui/scss/themes/dark.scss
@@ -59,6 +59,7 @@
--color-thumbnail-background: var(--color-gray-5);
--color-comment-threadline: #434b54;
--color-comment-threadline-hover: var(--color-gray-4);
+ --color-tooltip-bg: #2f3337;
// Text
--color-text: #d8d8d8;
diff --git a/ui/scss/themes/light.scss b/ui/scss/themes/light.scss
index f6893d5b3..50d7f549c 100644
--- a/ui/scss/themes/light.scss
+++ b/ui/scss/themes/light.scss
@@ -28,6 +28,8 @@
--color-comment-threadline: var(--color-gray-1);
--color-comment-threadline-hover: var(--color-gray-4);
--color-thumbnail-background: var(--color-gray-1);
+ --color-tooltip-bg: #222;
+ --color-tooltip-text: #fafafa;
// Icons
--color-follow-bg: #ffd4da;
diff --git a/yarn.lock b/yarn.lock
index f7b90bb7e..681ae0a2c 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -1493,6 +1493,19 @@
"@reach/utils" "^0.2.3"
warning "^4.0.2"
+"@reach/tooltip@^0.12.1":
+ version "0.12.1"
+ resolved "https://registry.yarnpkg.com/@reach/tooltip/-/tooltip-0.12.1.tgz#76f8e2337aa7dda20928ec4bbca247d39b4326af"
+ integrity sha512-9qk7WcgAjN/2tFEHN3Oi1m7BrSsL+MBFTFaxTaNqQacXYIKO3jNVFzLxkDVgyFP82h6EMJ5CkAJjOMi4aNyicQ==
+ dependencies:
+ "@reach/auto-id" "0.12.1"
+ "@reach/portal" "0.12.1"
+ "@reach/rect" "0.12.1"
+ "@reach/utils" "0.12.1"
+ "@reach/visually-hidden" "0.12.0"
+ prop-types "^15.7.2"
+ tslib "^2.0.0"
+
"@reach/utils@0.12.1", "@reach/utils@^0.12.1":
version "0.12.1"
resolved "https://registry.yarnpkg.com/@reach/utils/-/utils-0.12.1.tgz#02b9c15ba5cddf23e16f2d2ca77aef98a9702607"
@@ -1519,6 +1532,13 @@
version "0.7.4"
resolved "https://registry.yarnpkg.com/@reach/utils/-/utils-0.7.4.tgz#cdd0cff8c57445ce9c2b11204e6a62868f1093a1"
+"@reach/visually-hidden@0.12.0":
+ version "0.12.0"
+ resolved "https://registry.yarnpkg.com/@reach/visually-hidden/-/visually-hidden-0.12.0.tgz#c6c39f0bf292ae97a480ba3ed32e8a6149e852d4"
+ integrity sha512-VXtyR36WOS0FHmFQ/BzfswwPyBXICl/YjmTPtx/I0Vy5C6djjhD9kDsE+h/FpHzP3ugTdqdqiPBVElIZTSwOSA==
+ dependencies:
+ tslib "^2.0.0"
+
"@samverschueren/stream-to-observable@^0.3.0":
version "0.3.0"
resolved "https://registry.yarnpkg.com/@samverschueren/stream-to-observable/-/stream-to-observable-0.3.0.tgz#ecdf48d532c58ea477acfcab80348424f8d0662f"