Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v3.1.19 release 🚀 #1486

Merged
merged 70 commits into from
Aug 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
70 commits
Select commit Hold shift + click to select a range
595f5ce
build(deps): bump github.com/Azure/azure-sdk-for-go/sdk/azidentity
dependabot[bot] Jun 11, 2024
d59d4a9
build(deps-dev): bump storybook from 7.4.5 to 8.1.10 in /dashboard
dependabot[bot] Jun 18, 2024
17c211e
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/storybo…
Azanul Jun 23, 2024
f1222d7
build(deps): bump @sentry/react from 8.5.0 to 8.13.0 in /dashboard
dependabot[bot] Jul 1, 2024
1f0d649
Merge pull request #1455 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 2, 2024
8f2d5d5
build(deps-dev): bump ws from 6.2.2 to 6.2.3 in /dashboard
dependabot[bot] Jul 2, 2024
eec5b1e
Merge pull request #1448 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 2, 2024
7312a68
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/storybo…
Azanul Jul 2, 2024
2b7e8fd
Merge pull request #1444 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 2, 2024
b191486
Merge branch 'develop' into dependabot/go_modules/github.com/Azure/az…
Azanul Jul 2, 2024
a911572
build(deps-dev): bump @types/react from 18.3.2 to 18.3.3 in /dashboard
dependabot[bot] Jul 2, 2024
ca030d0
build(deps-dev): bump braces from 3.0.2 to 3.0.3 in /dashboard
dependabot[bot] Jul 2, 2024
4815e0e
Merge pull request #1440 from tailwarden/dependabot/go_modules/github…
Azanul Jul 2, 2024
15495c7
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/types/r…
Azanul Jul 2, 2024
55750a1
Merge pull request #1453 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 2, 2024
6c01ec3
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/braces-…
Azanul Jul 2, 2024
f1b149a
Merge pull request #1439 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 2, 2024
f52f0cf
create local network gateway resource with resource group
Jul 6, 2024
2776bf4
fix lint and resource group resources model
Jul 7, 2024
6b0a777
fix capitalization
Jul 8, 2024
f5397c7
build(deps-dev): bump @storybook/addon-links in /dashboard
dependabot[bot] Jul 8, 2024
a2a23f9
build(deps): bump react-dom and @types/react-dom in /dashboard
dependabot[bot] Jul 8, 2024
b83ee45
Merge pull request #1457 from azgcloudev/feature/396-support-localnet…
Azanul Jul 8, 2024
53003d4
build(deps): bump github.com/gin-contrib/cors from 1.4.0 to 1.6.0
dependabot[bot] Jul 8, 2024
ef98fda
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/multi-e…
Azanul Jul 18, 2024
61f4c99
Merge pull request #1462 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 18, 2024
a5a8cbf
build(deps-dev): bump postcss from 8.4.31 to 8.4.39 in /dashboard
dependabot[bot] Jul 18, 2024
7630904
Merge pull request #1461 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 18, 2024
94a9f9b
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/storybo…
Azanul Jul 18, 2024
50144df
Merge pull request #1459 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 18, 2024
d894963
build(deps-dev): bump @storybook/addon-links in /dashboard
dependabot[bot] Jul 18, 2024
21b5936
Merge branch 'develop' into dependabot/go_modules/github.com/gin-cont…
Azanul Jul 18, 2024
071e712
Merge pull request #1465 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 18, 2024
01bc422
build(deps): bump @formbricks/js from 2.0.0 to 2.1.0 in /dashboard
dependabot[bot] Jul 18, 2024
88f19bb
Merge pull request #1458 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 18, 2024
a3f93e3
feature: add banner to storybook
knav33n Jul 19, 2024
d32d96c
fix: revert github banner display logic
knav33n Jul 20, 2024
1b409ba
build(deps-dev): bump @storybook/nextjs in /dashboard
dependabot[bot] Jul 22, 2024
37137c8
build(deps-dev): bump @types/node in /dashboard
dependabot[bot] Jul 22, 2024
2832ddb
Merge pull request #1467 from knav33n/feature/1243-banner-story
Azanul Jul 25, 2024
726124d
Merge branch 'develop' into dependabot/go_modules/github.com/gin-cont…
Azanul Jul 26, 2024
aea005f
Merge pull request #1456 from tailwarden/dependabot/go_modules/github…
Azanul Jul 26, 2024
2f63e6e
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/storybo…
Azanul Jul 26, 2024
eb42e37
Merge pull request #1468 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 26, 2024
c0a7e53
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/types/n…
Azanul Jul 26, 2024
7df17b6
Merge pull request #1469 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Jul 26, 2024
c2329a4
fix: failing redis price calculation
Azanul Jul 27, 2024
d547f7c
build(deps): bump next from 14.1.3 to 14.2.5 in /dashboard
dependabot[bot] Jul 29, 2024
3ba592b
build(deps-dev): bump @storybook/addons in /dashboard
dependabot[bot] Jul 29, 2024
1c87ef7
fix: gcp buckets size calculation
Azanul Jul 30, 2024
92cffbd
refac: show service disabled as warnings
Azanul Jul 30, 2024
24b39da
Merge branch 'develop' into develop
Azanul Jul 30, 2024
5655ca0
Merge pull request #1478 from Azanul/develop
Azanul Aug 1, 2024
c87c43d
feat: support aws redshift cluster
Azanul Aug 1, 2024
19d8c32
refac: redundent if and dot imports removed
Azanul Aug 1, 2024
cf2cac2
refac: service name typo
Azanul Aug 1, 2024
cbb01cf
Merge branch 'develop' into develop
Azanul Aug 1, 2024
c40e317
Merge pull request #1479 from Azanul/develop
Azanul Aug 4, 2024
39eafdd
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/storybo…
Azanul Aug 4, 2024
f082b9d
Merge pull request #1476 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Aug 4, 2024
d46c7b0
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/next-14…
Azanul Aug 4, 2024
9279479
build(deps-dev): bump @testing-library/react in /dashboard
dependabot[bot] Aug 4, 2024
fe98bf1
Merge pull request #1475 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Aug 4, 2024
46ef3c3
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/testing…
Azanul Aug 4, 2024
9ed6039
build(deps): bump @sentry/react from 8.13.0 to 8.22.0 in /dashboard
dependabot[bot] Aug 4, 2024
7315cad
Merge pull request #1474 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Aug 5, 2024
d2352fa
Merge branch 'develop' into dependabot/npm_and_yarn/dashboard/sentry/…
Azanul Aug 5, 2024
ea26997
Merge pull request #1481 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Aug 6, 2024
52fe376
build(deps-dev): bump @storybook/blocks in /dashboard
dependabot[bot] Aug 6, 2024
bb9ba35
Merge pull request #1485 from tailwarden/dependabot/npm_and_yarn/dash…
Azanul Aug 6, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
89 changes: 89 additions & 0 deletions dashboard/components/banner/Banner.mocks.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
import { StarIcon } from '@components/icons';
import formatNumber from '@utils/formatNumber';
import Image from 'next/image';
import { BannerProps } from './Banner';

const base: BannerProps = {
children: 'Banner Content',
displayBanner: true,
dismissBanner: () => {}
};

const primary: BannerProps = {
children: (
<>
<span className="text-sm font-medium">
Support Komiser by giving us a star on GitHub.
</span>

<a
href="https://github.com/tailwarden/komiser"
target="_blank"
rel="noreferrer"
className="group flex items-center gap-3 rounded border-[1.5px] border-white pl-4 text-sm text-white transition-colors hover:bg-white/10"
>
<Image
src="/assets/img/others/github-white.svg"
width="18"
height="16"
alt="Github logo"
/>
<span>Star Komiser</span>
<div className="flex h-full items-center justify-center gap-2 border-l border-white/10 bg-white/10 px-3 py-2.5">
<StarIcon
width={16}
height={16}
className="group-hover:fill-orange-400 group-hover:text-orange-400"
/>
{formatNumber(100000)}
</div>
</a>
</>
),
displayBanner: true,
dismissBanner: () => {}
};

const secondary: BannerProps = {
children: (
<>
<span className="text-sm font-medium">
Support Komiser by giving us a star on GitHub.
</span>

<a
href="https://github.com/tailwarden/komiser"
target="_blank"
rel="noreferrer"
className="group flex items-center gap-3 rounded border-[1.5px] border-darkcyan-500 text-darkcyan-500 pl-4 text-sm transition-colors hover:bg-black/10"
>
<Image
src="/assets/img/others/github-black.svg"
width="18"
height="16"
alt="Github logo"
/>
<span>Star Komiser</span>
<div className="flex h-full items-center justify-center gap-2 border-l border-black/10 bg-black/10 px-3 py-2.5">
<StarIcon
width={16}
height={16}
className="group-hover:fill-orange-400 group-hover:text-orange-400"
/>
{formatNumber(100000)}
</div>
</a>
</>
),
displayBanner: true,
dismissBanner: () => {},
style: 'secondary'
};

const mockBannerProps = {
base,
primary,
secondary
};

export default mockBannerProps;
30 changes: 30 additions & 0 deletions dashboard/components/banner/Banner.stories.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
import type { Meta, StoryObj } from '@storybook/react';
import Banner from './Banner';
import mockBannerProps from './Banner.mocks';

const meta: Meta<typeof Banner> = {
title: 'Komiser/Banner',
component: Banner,
tags: ['autodocs']
};

export default meta;
type Story = StoryObj<typeof Banner>;

export const Default: Story = {
args: {
...mockBannerProps.base
}
};

export const Primary: Story = {
args: {
...mockBannerProps.primary
}
};

export const Secondary: Story = {
args: {
...mockBannerProps.secondary
}
};
82 changes: 31 additions & 51 deletions dashboard/components/banner/Banner.tsx
Original file line number Diff line number Diff line change
@@ -1,60 +1,40 @@
import Image from 'next/image';
import { useContext } from 'react';
import classNames from 'classnames';
import formatNumber from '../../utils/formatNumber';
import GlobalAppContext from '../layout/context/GlobalAppContext';
import StarIcon from '../icons/StarIcon';
import { ReactNode } from 'react';

type BannerProps = {
githubStars: number | undefined;
export type BannerProps = {
children: ReactNode;
displayBanner: boolean;
dismissBanner: () => void;
style?: 'primary' | 'secondary';
};

function Banner({ githubStars }: BannerProps) {
const { displayBanner, dismissBanner } = useContext(GlobalAppContext);
function Banner({
children,
displayBanner,
dismissBanner,
style = 'primary'
}: BannerProps) {
const bannerStyle = classNames(
'top-0 z-10 flex w-full animate-fade-in-down-short items-center justify-center gap-6 bg-gradient-to-br py-3 opacity-0',
{
fixed: displayBanner,
hidden: !displayBanner,
'text-white from-darkcyan-500 to-darkcyan-700': style === 'primary',
'text-black bg-white shadow-right': style === 'secondary'
}
);
const buttonStyle = classNames(
'absolute right-8 cursor-pointer rounded-lg p-3 transition-colors',
{
'text-white hover:bg-white/10 active:bg-gray-950': style === 'primary',
'text-black hover:bg-black/10': style === 'secondary'
}
);

return (
<div
className={classNames(
'top-0 z-10 flex w-full animate-fade-in-down-short items-center justify-center gap-6 bg-gradient-to-br from-darkcyan-500 to-darkcyan-700 py-3 opacity-0',
{
fixed: displayBanner,
hidden: !displayBanner
}
)}
>
<span className="text-sm font-medium text-white">
Support Komiser by giving us a star on GitHub.
</span>

{githubStars && (
<a
href="https://github.com/tailwarden/komiser"
target="_blank"
rel="noreferrer"
className="group flex items-center gap-3 rounded border-[1.5px] border-white pl-4 text-sm text-white transition-colors hover:bg-white/10"
>
<Image
src="/assets/img/others/github-white.svg"
width="18"
height="16"
alt="Github logo"
/>
<span>Star Komiser</span>
<div className="flex h-full items-center justify-center gap-2 border-l border-white/10 bg-white/10 px-3 py-2.5">
<StarIcon
width={16}
height={16}
className="group-hover:fill-orange-400 group-hover:text-orange-400"
/>
{formatNumber(githubStars)}
</div>
</a>
)}

<button
onClick={dismissBanner}
className="absolute right-8 cursor-pointer rounded-lg p-3 text-white transition-colors hover:bg-white/10 active:bg-gray-950"
>
<div className={bannerStyle}>
{children}
<button onClick={dismissBanner} className={buttonStyle}>
<svg
xmlns="http://www.w3.org/2000/svg"
width="24"
Expand Down
8 changes: 4 additions & 4 deletions dashboard/components/layout/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import { useRouter } from 'next/router';
import { ReactNode, useEffect } from 'react';
import settingsService from '@services/settingsService';
import { ToastProvider } from '@components/toast/ToastProvider';
import GithubBanner from './components/github-banner/GithubBanner';
import environment from '../../environments/environment';
import Banner from '../banner/Banner';
import useGithubStarBanner from '../banner/hooks/useGithubStarBanner';
import useGithubStarBanner from './hooks/useGithubStarBanner';
import Button from '../button/Button';
import EmptyState from '../empty-state/EmptyState';
import ErrorState from '../error-state/ErrorState';
Expand Down Expand Up @@ -55,7 +55,7 @@ function Layout({ children }: LayoutProps) {
}
}, [telemetry]);

const betaFlagOnboardingWizard = true; // set this to true once wizard gets good support of the backend
const betaFlagOnboardingWizard = true; // set this to true once wizard gets good support of the backend
const isOnboarding =
betaFlagOnboardingWizard && router.pathname.startsWith('/onboarding');

Expand All @@ -77,7 +77,7 @@ function Layout({ children }: LayoutProps) {

{!isOnboarding && (
<>
<Banner githubStars={githubStars} />
<GithubBanner githubStars={githubStars} />
<Navbar />
<main
className={classNames(
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
import Banner from '@components/banner/Banner';
import { StarIcon } from '@components/icons';
import GlobalAppContext from '@components/layout/context/GlobalAppContext';
import Image from 'next/image';
import { useContext } from 'react';
import formatNumber from '../../../../utils/formatNumber';

type GithubBannerProps = {
githubStars: number | undefined;
};

function GithubBanner({ githubStars }: GithubBannerProps) {
const { displayBanner, dismissBanner } = useContext(GlobalAppContext);

return (
<Banner displayBanner={displayBanner} dismissBanner={dismissBanner}>
<span className="text-sm font-medium">
Support Komiser by giving us a star on GitHub.
</span>

{githubStars && (
<a
href="https://github.com/tailwarden/komiser"
target="_blank"
rel="noreferrer"
className="group flex items-center gap-3 rounded border-[1.5px] border-white pl-4 text-sm text-white transition-colors hover:bg-white/10"
>
<Image
src="/assets/img/others/github-white.svg"
width="18"
height="16"
alt="Github logo"
/>
<span>Star Komiser</span>
<div className="flex h-full items-center justify-center gap-2 border-l border-white/10 bg-white/10 px-3 py-2.5">
<StarIcon
width={16}
height={16}
className="group-hover:fill-orange-400 group-hover:text-orange-400"
/>
{formatNumber(githubStars)}
</div>
</a>
)}
</Banner>
);
}

export default GithubBanner;
Loading
Loading