diff --git a/.editorconfig b/.editorconfig index 0dcc739fa..2322ac0d2 100644 --- a/.editorconfig +++ b/.editorconfig @@ -3,5 +3,5 @@ root = true [*.scss] indent_size = 2 -[login.scss] +[{**/login.scss,**/tangerine/**/*.scss,**/gts/**/*.scss}] indent_size = 4 \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index d9a9a9db8..7bcb90502 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Preserve ‘mastodon-settings’ in localStorage (#66) - Redesigned the login page (#76) +- Changed all icons with the Phosphor icon set (#77) ### Fixed diff --git a/app/javascript/flavours/glitch/components/account.jsx b/app/javascript/flavours/glitch/components/account.jsx index bf09ec76c..8d182c5e8 100644 --- a/app/javascript/flavours/glitch/components/account.jsx +++ b/app/javascript/flavours/glitch/components/account.jsx @@ -123,7 +123,7 @@ class Account extends ImmutablePureComponent { if (requested) { buttons = ; } else if (blocking) { - buttons = ; + buttons = ; } else if (muting) { let hidingNotificationsButton; if (account.getIn(["relationship", "muting_notifications"])) { @@ -133,16 +133,16 @@ class Account extends ImmutablePureComponent { } buttons = ( <> - + {hidingNotificationsButton} ); } else if (defaultAction === "mute") { - buttons = ; + buttons = ; } else if (defaultAction === "block") { - buttons = ; + buttons = ; } else if (!account.get("moved") || following) { - buttons = ; + buttons = ; } } diff --git a/app/javascript/flavours/glitch/components/column_back_button.jsx b/app/javascript/flavours/glitch/components/column_back_button.jsx index 92c98cfa2..28744c6a5 100644 --- a/app/javascript/flavours/glitch/components/column_back_button.jsx +++ b/app/javascript/flavours/glitch/components/column_back_button.jsx @@ -32,7 +32,7 @@ export default class ColumnBackButton extends PureComponent { const component = ( ); diff --git a/app/javascript/flavours/glitch/components/column_back_button_slim.jsx b/app/javascript/flavours/glitch/components/column_back_button_slim.jsx index eaa08af53..f5219f28a 100644 --- a/app/javascript/flavours/glitch/components/column_back_button_slim.jsx +++ b/app/javascript/flavours/glitch/components/column_back_button_slim.jsx @@ -27,7 +27,7 @@ export default class ColumnBackButtonSlim extends PureComponent { return (
- +
diff --git a/app/javascript/flavours/glitch/components/column_header.jsx b/app/javascript/flavours/glitch/components/column_header.jsx index 4254995c8..9ce770c19 100644 --- a/app/javascript/flavours/glitch/components/column_header.jsx +++ b/app/javascript/flavours/glitch/components/column_header.jsx @@ -7,6 +7,7 @@ import { FormattedMessage, injectIntl, defineMessages } from "react-intl"; import classNames from "classnames"; import { Icon } from "flavours/glitch/components/icon"; +import { IconButton } from "flavours/glitch/components/icon_button"; const messages = defineMessages({ show: { id: "column_header.show_settings", defaultMessage: "Show settings" }, @@ -117,34 +118,39 @@ class ColumnHeader extends PureComponent { } if (multiColumn && pinned) { - pinButton = ; + pinButton = (); moveButtons = ( -
- - +
+ +
); } else if (multiColumn && this.props.onPin) { - pinButton = ; + pinButton = (); } if (!pinned && ((multiColumn && router.history.location?.state?.fromMastodon) || showBackButton)) { backButton = ( ); } + + const columnHeaderFooter = ( +
+ {pinButton} {moveButtons} +
+ ); const collapsedContent = [ extraContent, ]; if (multiColumn) { - collapsedContent.push(pinButton); - collapsedContent.push(moveButtons); + collapsedContent.push(columnHeaderFooter); } if (this.context.identity.signedIn && (children || (multiColumn && this.props.onPin))) { @@ -155,10 +161,10 @@ class ColumnHeader extends PureComponent { aria-label={formatMessage(collapsed ? messages.show : messages.hide)} onClick={this.handleToggleClick} > - - - {collapseIssues && } - +
+ + {collapseIssues && } +
); } diff --git a/app/javascript/flavours/glitch/components/dismissable_banner.tsx b/app/javascript/flavours/glitch/components/dismissable_banner.tsx index 50ec411e2..d3871f375 100644 --- a/app/javascript/flavours/glitch/components/dismissable_banner.tsx +++ b/app/javascript/flavours/glitch/components/dismissable_banner.tsx @@ -35,7 +35,8 @@ export const DismissableBanner: React.FC> = ({
diff --git a/app/javascript/flavours/glitch/components/domain.tsx b/app/javascript/flavours/glitch/components/domain.tsx index 624936438..d8b0045f5 100644 --- a/app/javascript/flavours/glitch/components/domain.tsx +++ b/app/javascript/flavours/glitch/components/domain.tsx @@ -34,7 +34,7 @@ export const Domain: React.FC = ({ domain, onUnblockDomain }) => {
diff --git a/app/javascript/flavours/glitch/components/icon.tsx b/app/javascript/flavours/glitch/components/icon.tsx index f51a13b20..7eb3de155 100644 --- a/app/javascript/flavours/glitch/components/icon.tsx +++ b/app/javascript/flavours/glitch/components/icon.tsx @@ -13,10 +13,11 @@ export const Icon: React.FC = ({ id, className, fixedWidth, + title, ...other }) => ( - + + {title && {title}} + + ); diff --git a/app/javascript/flavours/glitch/components/icon_button.tsx b/app/javascript/flavours/glitch/components/icon_button.tsx index 84ad5818e..99f897b86 100644 --- a/app/javascript/flavours/glitch/components/icon_button.tsx +++ b/app/javascript/flavours/glitch/components/icon_button.tsx @@ -82,24 +82,10 @@ export class IconButton extends React.PureComponent { }; render() { - // Hack required for some icons which have an overriden size - let containerSize = "1.28571429em"; - if (this.props.style?.fontSize) { - containerSize = `${this.props.size * 1.28571429}px`; - } - const style = { - fontSize: `${this.props.size}px`, - height: containerSize, - lineHeight: `${this.props.size}px`, ...this.props.style, ...(this.props.active ? this.props.activeStyle : {}), }; - if (!this.props.label) { - style.width = containerSize; - } else { - style.textAlign = "left"; - } const { active, diff --git a/app/javascript/flavours/glitch/components/icon_with_badge.tsx b/app/javascript/flavours/glitch/components/icon_with_badge.tsx index 4696f76ab..ef328c3f2 100644 --- a/app/javascript/flavours/glitch/components/icon_with_badge.tsx +++ b/app/javascript/flavours/glitch/components/icon_with_badge.tsx @@ -16,11 +16,11 @@ export const IconWithBadge: React.FC = ({ issueBadge, className, }) => ( - +
{count > 0 && ( - {formatNumber(count)} + {formatNumber(count)} )} - {issueBadge && } - + {issueBadge &&
} +
); diff --git a/app/javascript/flavours/glitch/components/load_gap.tsx b/app/javascript/flavours/glitch/components/load_gap.tsx index 054337ae9..8b10dbbc7 100644 --- a/app/javascript/flavours/glitch/components/load_gap.tsx +++ b/app/javascript/flavours/glitch/components/load_gap.tsx @@ -28,7 +28,7 @@ export const LoadGap: React.FC = ({ disabled, maxId, onClick }) => { onClick={handleClick} aria-label={intl.formatMessage(messages.load_more)} > - + ); }; diff --git a/app/javascript/flavours/glitch/components/notification_purge_buttons.jsx b/app/javascript/flavours/glitch/components/notification_purge_buttons.jsx index 73c878de0..444c137a0 100644 --- a/app/javascript/flavours/glitch/components/notification_purge_buttons.jsx +++ b/app/javascript/flavours/glitch/components/notification_purge_buttons.jsx @@ -17,10 +17,10 @@ import ImmutablePureComponent from "react-immutable-pure-component"; import { Icon } from "flavours/glitch/components/icon"; const messages = defineMessages({ - btnAll : { id: "notification_purge.btn_all", defaultMessage: "Select\nall" }, - btnNone : { id: "notification_purge.btn_none", defaultMessage: "Select\nnone" }, - btnInvert : { id: "notification_purge.btn_invert", defaultMessage: "Invert\nselection" }, - btnApply : { id: "notification_purge.btn_apply", defaultMessage: "Clear\nselected" }, + btnAll : { id: "notification_purge.btn_all", defaultMessage: "All" }, + btnNone : { id: "notification_purge.btn_none", defaultMessage: "None" }, + btnInvert : { id: "notification_purge.btn_invert", defaultMessage: "Invert" }, + btnApply : { id: "notification_purge.btn_apply", defaultMessage: "Remove" }, }); class NotificationPurgeButtons extends ImmutablePureComponent { @@ -35,25 +35,24 @@ class NotificationPurgeButtons extends ImmutablePureComponent { }; render () { - const { intl, markNewForDelete } = this.props; + const { intl } = this.props; - //className='active' return (
- -
); diff --git a/app/javascript/flavours/glitch/components/picture_in_picture_placeholder.jsx b/app/javascript/flavours/glitch/components/picture_in_picture_placeholder.jsx index e03555c71..f153fca7b 100644 --- a/app/javascript/flavours/glitch/components/picture_in_picture_placeholder.jsx +++ b/app/javascript/flavours/glitch/components/picture_in_picture_placeholder.jsx @@ -22,7 +22,7 @@ class PictureInPicturePlaceholder extends PureComponent { render () { return (
- +
); diff --git a/app/javascript/flavours/glitch/components/status.jsx b/app/javascript/flavours/glitch/components/status.jsx index 019faa3a0..452403d3b 100644 --- a/app/javascript/flavours/glitch/components/status.jsx +++ b/app/javascript/flavours/glitch/components/status.jsx @@ -648,7 +648,7 @@ class Status extends ImmutablePureComponent { if (pictureInPicture.get("inUse")) { media.push(); - mediaIcons.push("video-camera"); + mediaIcons.push("film-strip"); } else if (attachments.size > 0) { const language = status.getIn(["translation", "language"]) || status.get("language"); @@ -688,7 +688,7 @@ class Status extends ImmutablePureComponent { )} , ); - mediaIcons.push("music"); + mediaIcons.push("music-note"); } else if (attachments.getIn([0, "type"]) === "video") { const attachment = status.getIn(["media_attachments", 0]); const description = attachment.getIn(["translation", "description"]) || attachment.get("description"); @@ -715,7 +715,7 @@ class Status extends ImmutablePureComponent { />)} , ); - mediaIcons.push("video-camera"); + mediaIcons.push("film-strip"); } else { // Media type is 'image' or 'gifv' media.push( @@ -737,7 +737,7 @@ class Status extends ImmutablePureComponent { )} , ); - mediaIcons.push("picture-o"); + mediaIcons.push("image"); } if (!status.get("sensitive") && !(status.get("spoiler_text").length > 0) && settings.getIn(["collapsed", "backgrounds", "preview_images"])) { @@ -759,7 +759,7 @@ class Status extends ImmutablePureComponent { if (status.get("poll")) { const language = status.getIn(["translation", "language"]) || status.get("language"); contentMedia.push(); - contentMediaIcons.push("tasks"); + contentMediaIcons.push("chart-bar-horizontal"); } // Here we prepare extra data-* attributes for CSS selectors. @@ -819,17 +819,15 @@ class Status extends ImmutablePureComponent { {(connectReply || connectUp || connectToRoot) &&
}
- - {muted && prepend} - {!muted || !isCollapsed ? ( - - ) : null} - + {muted && prepend} + {!muted || !isCollapsed ? ( + + ) : null} - - - + + + {filterButton} @@ -323,7 +322,7 @@ class StatusActionBar extends ImmutablePureComponent { scrollKey={scrollKey} status={status} items={menu} - icon='ellipsis-h' + icon='dots-three-outline' size={18} direction='right' ariaLabel={intl.formatMessage(messages.more)} diff --git a/app/javascript/flavours/glitch/components/status_content.jsx b/app/javascript/flavours/glitch/components/status_content.jsx index e8277ed8e..f29ced63b 100644 --- a/app/javascript/flavours/glitch/components/status_content.jsx +++ b/app/javascript/flavours/glitch/components/status_content.jsx @@ -360,6 +360,7 @@ class StatusContent extends PureComponent { {" "}

diff --git a/app/javascript/flavours/glitch/components/status_icons.jsx b/app/javascript/flavours/glitch/components/status_icons.jsx index 0ca3864d1..77827b94a 100644 --- a/app/javascript/flavours/glitch/components/status_icons.jsx +++ b/app/javascript/flavours/glitch/components/status_icons.jsx @@ -114,7 +114,7 @@ class StatusIcons extends PureComponent {