Skip to content

Commit

Permalink
Merge pull request #452 from open-sauced/beta
Browse files Browse the repository at this point in the history
v1.7.0-beta.14 -> main
  • Loading branch information
ElpisHelle committed Sep 28, 2022
2 parents 649e8ed + bb69e4c commit 639d9ec
Show file tree
Hide file tree
Showing 30 changed files with 25,011 additions and 612 deletions.
69 changes: 50 additions & 19 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,40 +5,71 @@

> All notable changes to this project will be documented in this file
## [1.7.0](https://github.com/open-sauced/insights/compare/v1.6.0...v1.7.0) (2022-09-23)
## [1.8.0-beta.1](https://github.com/open-sauced/insights/compare/v1.7.0...v1.8.0-beta.1) (2022-09-28)


### 🎨 Styles
### 🍕 Features

* added hover state style to footer links ([#420](https://github.com/open-sauced/insights/issues/420)) ([3aa5f17](https://github.com/open-sauced/insights/commit/3aa5f1785df89fd7562f41478719835eb83377ee))
* change text font and icon size to xs(12px) ([#401](https://github.com/open-sauced/insights/issues/401)) ([741288e](https://github.com/open-sauced/insights/commit/741288e19a267e4ddcf5c1afb0fcc0e8308d75eb))
* refactor show us button style to match design ([#419](https://github.com/open-sauced/insights/issues/419)) ([b6c21b1](https://github.com/open-sauced/insights/commit/b6c21b153c136ed7d1ae9a2ac243232b71fb7e66)), closes [#408](https://github.com/open-sauced/insights/issues/408)
* add data from API to contributors page for hacktoberfest ([#431](https://github.com/open-sauced/insights/issues/431)) ([56e12ea](https://github.com/open-sauced/insights/commit/56e12ea18ec8a7983146a4f7a0f6fe13c10f36ca)), closes [#404](https://github.com/open-sauced/insights/issues/404)
* Add truncate string for long pr names ([#440](https://github.com/open-sauced/insights/issues/440)) ([35b8541](https://github.com/open-sauced/insights/commit/35b8541b71bcdd782af096f3332e64d75ea72d56)), closes [#438](https://github.com/open-sauced/insights/issues/438)
* adds initial support for restricting reports by user roles ([#451](https://github.com/open-sauced/insights/issues/451)) ([15a7643](https://github.com/open-sauced/insights/commit/15a764339c2b4cd87ecee8bc61d5c3c84cb9424a)), closes [#395](https://github.com/open-sauced/insights/issues/395)


### 🐛 Bug Fixes

* add tooltip message on information icon hover ([#421](https://github.com/open-sauced/insights/issues/421)) ([12ff851](https://github.com/open-sauced/insights/commit/12ff85193d0ab75f61e6e0eda09d3864b2d3ca8f)), closes [#366](https://github.com/open-sauced/insights/issues/366)
* adds brandon to top5 ([8bb56cb](https://github.com/open-sauced/insights/commit/8bb56cb72d2d904168f8443b3afe860faa98fc58))
* correct beta branch checking beta gitsense api ([2c6f576](https://github.com/open-sauced/insights/commit/2c6f57641838f5b219ce274b576e496daff2192b))
* redirect from onboarding if already complete with custom hook ([#388](https://github.com/open-sauced/insights/issues/388)) ([8600c76](https://github.com/open-sauced/insights/commit/8600c7648cc0092fa3b51de5e8a26d722e799819)), closes [#387](https://github.com/open-sauced/insights/issues/387)
* update PR overview calculation to use active PRs in last 30 days / total PRs ([#423](https://github.com/open-sauced/insights/issues/423)) ([05b48ff](https://github.com/open-sauced/insights/commit/05b48ffb4d50a0041060e07d78ab7e5f9eb79471)), closes [#418](https://github.com/open-sauced/insights/issues/418)
* adds links to footer ([#432](https://github.com/open-sauced/insights/issues/432)) ([7adfbe7](https://github.com/open-sauced/insights/commit/7adfbe72cc602748cad3e546d5e696ae60c101a6))
* inverse the scatter chart ([#433](https://github.com/open-sauced/insights/issues/433)) ([18dd094](https://github.com/open-sauced/insights/commit/18dd09474582269433cf36f29b17277b14ffceb5)), closes [#399](https://github.com/open-sauced/insights/issues/399)
* limit number of languages in contibutor's card ([#441](https://github.com/open-sauced/insights/issues/441)) ([4aba355](https://github.com/open-sauced/insights/commit/4aba355220a0b4f342dddf8f3ad6a0f4adadaa3c)), closes [#402](https://github.com/open-sauced/insights/issues/402)
* remove link from highlight card component ([#435](https://github.com/open-sauced/insights/issues/435)) ([25b6997](https://github.com/open-sauced/insights/commit/25b6997f8dbce1213ddbbaa367df9ebdd28b643e))
* remove remaining mock data for contributors ([#443](https://github.com/open-sauced/insights/issues/443)) ([974c739](https://github.com/open-sauced/insights/commit/974c7395f62c7518c14aaa6e1ab089ec0a5df88f)), closes [#404](https://github.com/open-sauced/insights/issues/404) [#444](https://github.com/open-sauced/insights/issues/444)

## [1.7.0-beta.14](https://github.com/open-sauced/insights/compare/v1.7.0-beta.13...v1.7.0-beta.14) (2022-09-28)

### 🐛 Bug Fixes

* limit number of languages in contibutor's card ([#441](https://github.com/open-sauced/insights/issues/441)) ([4aba355](https://github.com/open-sauced/insights/commit/4aba355220a0b4f342dddf8f3ad6a0f4adadaa3c)), closes [#402](https://github.com/open-sauced/insights/issues/402)

## [1.7.0-beta.13](https://github.com/open-sauced/insights/compare/v1.7.0-beta.12...v1.7.0-beta.13) (2022-09-28)

### 🍕 Features

* add privacy and license terms ([#422](https://github.com/open-sauced/insights/issues/422)) ([0dcc161](https://github.com/open-sauced/insights/commit/0dcc16129c7063dfb0d02e648beefd821f2c7dbb)), closes [#377](https://github.com/open-sauced/insights/issues/377)
* connect repositories page to API data and pagination ([#405](https://github.com/open-sauced/insights/issues/405)) ([634de8e](https://github.com/open-sauced/insights/commit/634de8ecf5f2eb5ce5967b5eac2b38262b5fc09c)), closes [#320](https://github.com/open-sauced/insights/issues/320) [#384](https://github.com/open-sauced/insights/issues/384)
* create mobile version of repo table ([#409](https://github.com/open-sauced/insights/issues/409)) ([9355968](https://github.com/open-sauced/insights/commit/9355968b04a7b9da66a7962fe1dc1c32640d83ab))
* Add truncate string for long pr names ([#440](https://github.com/open-sauced/insights/issues/440)) ([35b8541](https://github.com/open-sauced/insights/commit/35b8541b71bcdd782af096f3332e64d75ea72d56)), closes [#438](https://github.com/open-sauced/insights/issues/438)

## [1.7.0-beta.12](https://github.com/open-sauced/insights/compare/v1.7.0-beta.11...v1.7.0-beta.12) (2022-09-28)

### 🧑‍💻 Code Refactoring

* check avatarURL for orange avatar background and update pill colors ([#424](https://github.com/open-sauced/insights/issues/424)) ([c821cd5](https://github.com/open-sauced/insights/commit/c821cd53243f20255e2f5e7f22ad4fe8e0b55246)), closes [#414](https://github.com/open-sauced/insights/issues/414) [#416](https://github.com/open-sauced/insights/issues/416)
* Polish the Dashboard to match designs ([#427](https://github.com/open-sauced/insights/issues/427)) ([f919c27](https://github.com/open-sauced/insights/commit/f919c271d4a9e8dc8e826a49eb3b1946bb189bc9))
* Polish the Reports Page to match the design ([#425](https://github.com/open-sauced/insights/issues/425)) ([87a2bdc](https://github.com/open-sauced/insights/commit/87a2bdcbb8b1f5df88f1dd4f380aa6133face049))
* Update text styles on Scatter Chart card ([#429](https://github.com/open-sauced/insights/issues/429)) ([ab24703](https://github.com/open-sauced/insights/commit/ab24703ddd1d0c5b10448287fd450712e4b93114))
### 🍕 Features

* adds initial support for restricting reports by user roles ([#451](https://github.com/open-sauced/insights/issues/451)) ([15a7643](https://github.com/open-sauced/insights/commit/15a764339c2b4cd87ecee8bc61d5c3c84cb9424a)), closes [#395](https://github.com/open-sauced/insights/issues/395)

## [1.7.0-beta.11](https://github.com/open-sauced/insights/compare/v1.7.0-beta.10...v1.7.0-beta.11) (2022-09-27)


### 🐛 Bug Fixes

* remove remaining mock data for contributors ([#443](https://github.com/open-sauced/insights/issues/443)) ([974c739](https://github.com/open-sauced/insights/commit/974c7395f62c7518c14aaa6e1ab089ec0a5df88f)), closes [#404](https://github.com/open-sauced/insights/issues/404) [#444](https://github.com/open-sauced/insights/issues/444)

## [1.7.0-beta.10](https://github.com/open-sauced/insights/compare/v1.7.0-beta.9...v1.7.0-beta.10) (2022-09-27)


### 🍕 Features

* add data from API to contributors page for hacktoberfest ([#431](https://github.com/open-sauced/insights/issues/431)) ([56e12ea](https://github.com/open-sauced/insights/commit/56e12ea18ec8a7983146a4f7a0f6fe13c10f36ca)), closes [#404](https://github.com/open-sauced/insights/issues/404)

## [1.7.0-beta.9](https://github.com/open-sauced/insights/compare/v1.7.0-beta.8...v1.7.0-beta.9) (2022-09-26)


### 🐛 Bug Fixes

* remove link from highlight card component ([#435](https://github.com/open-sauced/insights/issues/435)) ([25b6997](https://github.com/open-sauced/insights/commit/25b6997f8dbce1213ddbbaa367df9ebdd28b643e))

## [1.7.0-beta.8](https://github.com/open-sauced/insights/compare/v1.7.0-beta.7...v1.7.0-beta.8) (2022-09-23)


### 🐛 Bug Fixes

## [1.7.0-beta.7](https://github.com/open-sauced/insights/compare/v1.7.0-beta.6...v1.7.0-beta.7) (2022-09-23)
* adds links to footer ([#432](https://github.com/open-sauced/insights/issues/432)) ([7adfbe7](https://github.com/open-sauced/insights/commit/7adfbe72cc602748cad3e546d5e696ae60c101a6))
* inverse the scatter chart ([#433](https://github.com/open-sauced/insights/issues/433)) ([18dd094](https://github.com/open-sauced/insights/commit/18dd09474582269433cf36f29b17277b14ffceb5)), closes [#399](https://github.com/open-sauced/insights/issues/399## [1.7.0-beta.7](https://github.com/open-sauced/insights/compare/v1.7.0-beta.6...v1.7.0-beta.7) (2022-09-23)


### 🍕 Features
Expand Down
8 changes: 4 additions & 4 deletions components/atoms/Typography/text.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ const { Text: SupabaseTextComponent } = Typography;

interface TextProps extends React.ComponentProps<typeof SupabaseTextComponent> {
//Add additional prop definitions here
title?: string
}

const Text: React.FC<TextProps> = ( props ) => {

const Text: React.FC<TextProps> = (props) => {
return (
<SupabaseTextComponent className={`${props.className && props.className}`} {...props}>
{props.children}
<span title={props.title}>{props.children}</span>
</SupabaseTextComponent>
);
};

export default Text;
export default Text;
4 changes: 2 additions & 2 deletions components/molecules/AuthSection/auth-section.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ import useSupabaseAuth from "../../../lib/hooks/useSupabaseAuth";
import {FiLogOut} from "react-icons/fi";
import GitHubIcon from "public/icons/github-icon.svg";
import Icon from "components/atoms/Icon/icon";
import useOnboarded from "lib/hooks/useOnboarded";
import useSession from "lib/hooks/useSession";

const AuthSection: React.FC = ({ }) => {
const { signIn, signOut, user } = useSupabaseAuth();
const { onboarded } = useOnboarded();
const { onboarded } = useSession();

const authMenu = {
authed: [
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { useState } from "react";
import { useEffect, useState } from "react";
import Text from "components/atoms/Typography/text";
import colors from "../../../lib/utils/color.json";

Expand All @@ -24,24 +24,38 @@ const languageToColor: AllSimpleColors = colors as AllSimpleColors;

const CardHorizontalBarChart = ({ languageList }: CardHorizontalBarChartProps): JSX.Element => {
const sortedLangArray = languageList.sort((a, b) => b.percentageUsed - a.percentageUsed);
// used this state to calculate thte percentage of each language
const [percentage, setPercentage] = useState<any>(0);

const [descriptText, setDescriptText] = useState(sortedLangArray[0].languageName);

const handleChangeDescriptText = (descriptText: string) => {
setDescriptText(descriptText);
};

useEffect(() =>{
const totalSumOfFirstFivePercentage = sortedLangArray
.slice(0,4)
.map(lang => lang.percentageUsed)
.reduce((prev: number, next: number) => prev + next); // need some help fixing this type error, used any to bypass 🙏
setPercentage(totalSumOfFirstFivePercentage);
},[percentage, sortedLangArray]);

return (
<div className="flex flex-col gap-1 min-w-[120px]">
{/* Progress Bar */}
<div className="flex items-center w-full rounded-full gap-0.5 overflow-hidden">
<div className="flex items-center w-full justify-end rounded-full gap-0.5 overflow-hidden">
{sortedLangArray.map(({ languageName, percentageUsed }, index) =>
<div
{

return index < 5 && ( <div
key={index}
onMouseOver={() => handleChangeDescriptText(languageName)}
className="h-2 transition-all duration-500 ease-in-out"
style={{ width: `${percentageUsed}%`, backgroundColor: languageToColor[languageName] ? languageToColor[languageName].color as string : NOTSUPPORTED }}
/>
style={{ width: `${percentageUsed < 20 ? percentageUsed / percentage * 100 : percentageUsed}%`, backgroundColor: languageToColor[languageName] ? languageToColor[languageName].color as string : NOTSUPPORTED }}
/>);
}

)}
</div>
<div className="flex gap-2 items-center">
Expand Down
Loading

0 comments on commit 639d9ec

Please sign in to comment.