Skip to content

Commit 44f1f60

Browse files
committed
feat: add component for snow confetti
1 parent a23a3c9 commit 44f1f60

File tree

5 files changed

+23
-4
lines changed

5 files changed

+23
-4
lines changed

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@devtron-labs/devtron-fe-common-lib",
3-
"version": "1.11.2",
3+
"version": "1.11.2-patch-1",
44
"description": "Supporting common component library",
55
"type": "module",
66
"main": "dist/index.js",

src/Shared/Components/Confetti/Confetti.component.tsx

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,26 @@
1515
*/
1616

1717
import { ComponentProps } from 'react'
18+
import Snow from 'react-canvas-confetti/dist/presets/snow'
1819
import Pride from 'react-canvas-confetti/dist/presets/pride'
1920

21+
export const SnowConfetti = () => {
22+
const decorateOptions: ComponentProps<typeof Snow>['decorateOptions'] = (options) => ({
23+
...options,
24+
colors: ['#a864fd'],
25+
})
26+
27+
return (
28+
<Snow
29+
autorun={{ speed: 30 }}
30+
decorateOptions={decorateOptions}
31+
style={{
32+
height: '100%',
33+
}}
34+
/>
35+
)
36+
}
37+
2038
const Confetti = () => {
2139
const decorateOptions: ComponentProps<typeof Pride>['decorateOptions'] = (options) => ({
2240
...options,

src/Shared/Components/Confetti/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@
1414
* limitations under the License.
1515
*/
1616

17-
export { default as Confetti } from './Confetti.component'
17+
export { SnowConfetti, default as Confetti } from './Confetti.component'

src/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,7 @@ export interface customEnv {
155155
*/
156156
FEATURE_APPLICATION_TEMPLATES_ENABLE?: boolean
157157
GATEKEEPER_URL?: string
158+
LOGIN_PAGE_IMAGE?: string
158159
}
159160
declare global {
160161
interface Window {

0 commit comments

Comments
 (0)