frst-components 0.23.13 → 0.23.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -43,6 +43,7 @@ var moment = require('moment');
43
43
  var _ = require('@mui/material/');
44
44
  var Slider = require('@mui/material/Slider');
45
45
  var styles$1 = require('@material-ui/styles');
46
+ var reactTooltip = require('react-tooltip');
46
47
  var IconButton = require('@mui/material/IconButton');
47
48
  var MoreVertIcon = require('@mui/icons-material/MoreVert');
48
49
  var ComputerIcon = require('@mui/icons-material/Computer');
@@ -16036,23 +16037,32 @@ function FeedInteraction(props) {
16036
16037
  setOpenComments(!openComments);
16037
16038
  setOpenReview(false);
16038
16039
  };
16039
- return (jsxRuntime.jsx(styled.ThemeProvider, { theme: FRSTTheme, children: jsxRuntime.jsxs(Container$2, { style: { ...props.style }, id: props.id, children: [!props.textTotalView && (props.qtdLikes || stateTotalComments) ?
16040
- jsxRuntime.jsxs(infoContent, { children: [props.qtdLikes ?
16041
- jsxRuntime.jsxs(info, { style: { left: 0 }, children: [" ", jsxRuntime.jsx(ThumbsUpCovered, {}), " \u00A0", props.qtdLikes] })
16042
- : null, stateTotalComments ?
16043
- jsxRuntime.jsx(info, { style: { right: 0 }, children: stateTotalComments })
16044
- : null] })
16045
- : jsxRuntime.jsx(jsxRuntime.Fragment, { children: (props.textTotalView || props.qtdLikes || stateTotalComments) &&
16046
- jsxRuntime.jsxs(infoContentWithView, { children: [jsxRuntime.jsxs("div", { style: { display: 'flex', flexDirection: 'row', gap: '5px' }, children: [props.qtdLikes && jsxRuntime.jsxs(infoWithView, { children: [" ", jsxRuntime.jsx(ThumbsUpCovered, {}), " \u00A0", props.qtdLikes] }), props.qtdLikes && stateTotalComments && jsxRuntime.jsx("div", { children: "\u2022" }), stateTotalComments && jsxRuntime.jsxs(infoWithView, { children: [" ", stateTotalComments, " "] })] }), props.textTotalView && jsxRuntime.jsx(infoWithView, { style: { color: '#0645AD', fontWeight: 700, cursor: 'pointer' }, onClick: () => props.handleClickTextTotalViews(), children: props.textTotalView })] }) }), jsxRuntime.jsxs(buttonsContent, { children: [props.isLiked ?
16047
- jsxRuntime.jsx(buttons, { children: jsxRuntime.jsx(Button$4, { startIcon: jsxRuntime.jsx(ThumbsUpIcon, { fill: 'currentColor' }), label: props.textDeslike, variant: 'link', handleClick: props.handleLikeClick }) })
16048
- :
16049
- jsxRuntime.jsx(buttons, { children: jsxRuntime.jsx(Button$4, { startIcon: jsxRuntime.jsx(ThumbsUpIcon, { fill: 'currentColor' }), label: props.textLikes, variant: 'link', handleClick: props.handleLikeClick }) }), isVisibleComments &&
16050
- jsxRuntime.jsxs(buttons, { onClick: OnCommentsClick, style: { color: openComments && FRSTTheme['colors'].linkPressed }, children: [jsxRuntime.jsx(TalkIcon, { fill: 'currentColor' }), " ", props.textComments] }), jsxRuntime.jsxs(buttons, { onClick: OnReviewClick, style: { color: openReview && FRSTTheme['colors'].linkPressed }, children: [jsxRuntime.jsx(StarOutlined, { fill: 'currentColor' }), " ", props.textAvaluation] })] }), openReview &&
16051
- jsxRuntime.jsxs(reviewContainer, { children: [props.textAvaluationTitle, jsxRuntime.jsxs(reviewContent, { children: [props.isChallengeReview &&
16052
- jsxRuntime.jsxs("div", { style: { display: 'flex', justifyContent: 'center', alignItems: 'center', flexDirection: 'column' }, children: [jsxRuntime.jsx(Rating, { isVisibleNumberRating: false, orientation: 'horizontal', qtdStars: 5, sizeStars: 20, marginStars: '3.5px', disabled: props.isDisabledAvaluation, rating: props.ratingImpacto, handleRating: props?.handleImpactoChange }), jsxRuntime.jsx("span", { children: props.textImpacto })] }), props.isChallengeReview &&
16053
- jsxRuntime.jsxs("div", { style: { display: 'flex', justifyContent: 'center', alignItems: 'center', flexDirection: 'column', marginLeft: 24 }, children: [jsxRuntime.jsx(Rating, { isVisibleNumberRating: false, orientation: 'horizontal', qtdStars: 5, sizeStars: 20, marginStars: '3.5px', disabled: props.isDisabledAvaluation, rating: props.ratingRelevancia, handleRating: props?.handleRelevanciaChange }), jsxRuntime.jsx("span", { children: props.textRelevancia })] }), props.isPostReview &&
16054
- jsxRuntime.jsx("div", { style: { display: 'flex', justifyContent: 'center', alignItems: 'center', flexDirection: 'column' }, children: jsxRuntime.jsx(Rating, { isVisibleNumberRating: false, orientation: 'horizontal', qtdStars: 5, sizeStars: 20, marginStars: '3.5px', disabled: props.isDisabledAvaluation, rating: props.ratingPostReview, handleRating: props?.handlePostReviewChange }) })] })] }), openComments && props?.isCommentV2 &&
16055
- jsxRuntime.jsx("div", { children: props?.childrenCommentV2 })] }) }));
16040
+ return (jsxRuntime.jsx(styled.ThemeProvider, { theme: FRSTTheme, children: jsxRuntime.jsxs(Container$2, { style: { ...props.style }, id: props.id, children: [!props.textTotalView && (props.qtdLikes || stateTotalComments) ? (jsxRuntime.jsxs(infoContent, { children: [props?.qtdLikes ? (jsxRuntime.jsxs(info, { style: { left: 0 }, children: [' ', jsxRuntime.jsx(ThumbsUpCovered, {}), " \u00A0", props?.tooltipLikesText ? (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx("span", { onClick: () => props?.handleShowLikes?.(), "data-tooltip-id": "my-tooltip-inline", "data-tooltip-place": "top", style: {
16041
+ cursor: 'pointer',
16042
+ color: '#0645AD',
16043
+ fontFamily: 'PT Sans',
16044
+ fontSize: '16px',
16045
+ lineHeight: '17.6px',
16046
+ fontWeight: 400,
16047
+ textDecoration: 'underline'
16048
+ }, "data-tooltip-content": props?.tooltipLikesText, children: props?.qtdLikes }), jsxRuntime.jsx(reactTooltip.Tooltip, { id: "my-tooltip-inline", style: {
16049
+ backgroundColor: '#222',
16050
+ color: '#fff'
16051
+ } })] })) : (jsxRuntime.jsx("span", { onClick: () => props?.handleShowLikes?.(), style: {
16052
+ cursor: 'pointer',
16053
+ color: '#0645AD',
16054
+ fontFamily: 'PT Sans',
16055
+ fontSize: '16px',
16056
+ lineHeight: '17.6px',
16057
+ fontWeight: 400,
16058
+ textDecoration: 'underline'
16059
+ }, children: props.qtdLikes }))] })) : null, stateTotalComments ? jsxRuntime.jsx(info, { style: { right: 0 }, children: stateTotalComments }) : null] })) : (jsxRuntime.jsx(jsxRuntime.Fragment, { children: (props.textTotalView || props.qtdLikes || stateTotalComments) && (jsxRuntime.jsxs(infoContentWithView, { children: [jsxRuntime.jsxs("div", { style: { display: 'flex', flexDirection: 'row', gap: '5px' }, children: [props.qtdLikes && (jsxRuntime.jsxs(infoWithView, { onClick: () => props?.handleShowLikes?.(), children: [' ', jsxRuntime.jsx(ThumbsUpCovered, {}), " \u00A0", jsxRuntime.jsx("a", { style: { cursor: 'pointer' }, children: props.qtdLikes })] })), props.qtdLikes && stateTotalComments && jsxRuntime.jsx("div", { children: "\u2022" }), stateTotalComments && jsxRuntime.jsxs(infoWithView, { children: [" ", stateTotalComments, " "] })] }), props.textTotalView && (jsxRuntime.jsx(infoWithView, { style: { color: '#0645AD', fontWeight: 700, cursor: 'pointer' }, onClick: () => props.handleClickTextTotalViews(), children: props.textTotalView }))] })) })), jsxRuntime.jsxs(buttonsContent, { children: [props.isLiked ? (jsxRuntime.jsx(buttons, { children: jsxRuntime.jsx(Button$4, { startIcon: jsxRuntime.jsx(ThumbsUpIcon, { fill: 'currentColor' }), label: props.textDeslike, variant: "link", handleClick: props.handleLikeClick }) })) : (jsxRuntime.jsx(buttons, { children: jsxRuntime.jsx(Button$4, { startIcon: jsxRuntime.jsx(ThumbsUpIcon, { fill: 'currentColor' }), label: props.textLikes, variant: "link", handleClick: props.handleLikeClick }) })), isVisibleComments && (jsxRuntime.jsxs(buttons, { onClick: OnCommentsClick, style: { color: openComments && FRSTTheme['colors'].linkPressed }, children: [jsxRuntime.jsx(TalkIcon, { fill: 'currentColor' }), " ", props.textComments] })), jsxRuntime.jsxs(buttons, { onClick: OnReviewClick, style: { color: openReview && FRSTTheme['colors'].linkPressed }, children: [jsxRuntime.jsx(StarOutlined, { fill: 'currentColor' }), " ", props.textAvaluation] })] }), openReview && (jsxRuntime.jsxs(reviewContainer, { children: [props.textAvaluationTitle, jsxRuntime.jsxs(reviewContent, { children: [props.isChallengeReview && (jsxRuntime.jsxs("div", { style: { display: 'flex', justifyContent: 'center', alignItems: 'center', flexDirection: 'column' }, children: [jsxRuntime.jsx(Rating, { isVisibleNumberRating: false, orientation: "horizontal", qtdStars: 5, sizeStars: 20, marginStars: '3.5px', disabled: props.isDisabledAvaluation, rating: props.ratingImpacto, handleRating: props?.handleImpactoChange }), jsxRuntime.jsx("span", { children: props.textImpacto })] })), props.isChallengeReview && (jsxRuntime.jsxs("div", { style: {
16060
+ display: 'flex',
16061
+ justifyContent: 'center',
16062
+ alignItems: 'center',
16063
+ flexDirection: 'column',
16064
+ marginLeft: 24
16065
+ }, children: [jsxRuntime.jsx(Rating, { isVisibleNumberRating: false, orientation: "horizontal", qtdStars: 5, sizeStars: 20, marginStars: '3.5px', disabled: props.isDisabledAvaluation, rating: props.ratingRelevancia, handleRating: props?.handleRelevanciaChange }), jsxRuntime.jsx("span", { children: props.textRelevancia })] })), props.isPostReview && (jsxRuntime.jsx("div", { style: { display: 'flex', justifyContent: 'center', alignItems: 'center', flexDirection: 'column' }, children: jsxRuntime.jsx(Rating, { isVisibleNumberRating: false, orientation: "horizontal", qtdStars: 5, sizeStars: 20, marginStars: '3.5px', disabled: props.isDisabledAvaluation, rating: props.ratingPostReview, handleRating: props?.handlePostReviewChange }) }))] })] })), openComments && props?.isCommentV2 && jsxRuntime.jsx("div", { children: props?.childrenCommentV2 })] }) }));
16056
16066
  }
16057
16067
 
16058
16068
  function BannerProblemFeed(props) {
@@ -21,6 +21,8 @@ interface IFeedInteraction {
21
21
  isDisabledAvaluation?: boolean;
22
22
  style?: React.CSSProperties;
23
23
  handleLikeClick?: () => void;
24
+ handleShowLikes?: () => void;
25
+ tooltipLikesText?: string;
24
26
  handleImpactoChange?: any;
25
27
  handleRelevanciaChange?: any;
26
28
  handlePostReviewChange?: any;
@@ -1 +1 @@
1
- {"version":3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AG,CAAA;CACxB;AAED,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,KAAK,EAAE,gBAAgB,eA8M9D"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "frst-components",
3
3
  "homepage": "http://FRST-Falconi.github.io/storybook.frstfalconi.com",
4
- "version": "0.23.13",
4
+ "version": "0.23.14",
5
5
  "private": false,
6
6
  "main": "./dist/index.js",
7
7
  "types": "./dist/index.d.ts",
@@ -55,6 +55,7 @@
55
55
  "react-scrollbars-custom": "^4.1.1",
56
56
  "react-select": "^5.3.2",
57
57
  "react-switch": "^7.0.0",
58
+ "react-tooltip": "^5.26.4",
58
59
  "slate-history": "^0.66.0",
59
60
  "slate-react": "^0.83.0",
60
61
  "styled-components": "^5.3.3",