Bin
2025-12-16 9e0b2ba2c317b1a86212f24cbae3195ad1f3dbfa
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
import type { Meta, StoryObj } from "@storybook/react";
import { EnterpriseUpgradeOverlay } from "./enterprise-upgrade-overlay";
 
const meta: Meta<typeof EnterpriseUpgradeOverlay> = {
  component: EnterpriseUpgradeOverlay,
  title: "UI/EnterpriseUpgradeOverlay",
  argTypes: {
    title: { control: "text" },
    description: { control: "text" },
    feature: { control: "text" },
    learnMoreUrl: { control: "text" },
    primaryButtonLabel: { control: "text" },
    secondaryButtonLabel: { control: "text" },
    showLearnMore: { control: "boolean" },
    className: { control: "text" },
    "data-testid": { control: "text" },
    onContactSales: { action: "contact sales clicked" },
    onLearnMore: { action: "learn more clicked" },
  },
  decorators: [
    (Story) => (
      <div style={{ position: "relative", height: "600px", background: "var(--color-neutral-background)" }}>
        <Story />
      </div>
    ),
  ],
};
 
export default meta;
type Story = StoryObj<typeof EnterpriseUpgradeOverlay>;
 
/**
 * Default overlay with standard messaging
 */
export const Default: Story = {
  args: {},
};
 
/**
 * Overlay customized for Project Dashboards feature
 */
export const ProjectDashboards: Story = {
  args: {
    title: "Get access to Project Dashboards!",
    description:
      "Performance analytics are available within the Enterprise plan. Contact our sales team to get access to this and more!",
    feature: "Project Dashboards",
    learnMoreUrl: "https://docs.humansignal.com/guide/dashboards.html",
  },
};
 
/**
 * Overlay for SSO & Security features
 */
export const SSOAndSecurity: Story = {
  args: {
    title: "SSO & Advanced Security",
    description: "Enable Single Sign-On, advanced security features, and compliance tools with our Enterprise plan.",
    feature: "SSO & Security Features",
    learnMoreUrl: "https://docs.humansignal.com/guide/security.html",
    secondaryButtonLabel: "Learn more",
  },
};
 
/**
 * Overlay for Custom Workflows
 */
export const CustomWorkflows: Story = {
  args: {
    title: "Advanced Workflows",
    description: "Create custom automation workflows and advanced labeling pipelines with our Enterprise plan.",
    feature: "Advanced Workflows",
    learnMoreUrl: "https://docs.humansignal.com/guide/workflows.html",
  },
};
 
/**
 * Overlay without the "Learn More" button
 */
export const WithoutLearnMore: Story = {
  args: {
    title: "Premium Feature",
    description: "This feature is available exclusively in our Enterprise plan. Contact sales to learn more.",
    feature: "Premium Features",
    showLearnMore: false,
  },
};
 
/**
 * Overlay with custom button labels
 */
export const CustomButtonLabels: Story = {
  args: {
    title: "Upgrade to Enterprise",
    description: "Access all premium features and dedicated support.",
    feature: "Enterprise Plan",
    primaryButtonLabel: "Talk to Sales",
    secondaryButtonLabel: "View Pricing",
    learnMoreUrl: "https://humansignal.com/pricing",
  },
};
 
/**
 * Overlay shown in context over blurred content
 */
export const InContext: Story = {
  render: () => (
    <div style={{ position: "relative", height: "600px", background: "var(--color-neutral-background)" }}>
      <div style={{ padding: "32px", opacity: 0.5, filter: "blur(2px)" }}>
        <div style={{ marginBottom: "24px" }}>
          <h2 style={{ fontSize: "24px", fontWeight: 600, marginBottom: "8px", color: "var(--color-neutral-content)" }}>
            Project Performance Dashboard
          </h2>
          <p style={{ color: "var(--color-neutral-content-subtler)", marginBottom: "24px" }}>
            Track your team's annotation progress and quality metrics
          </p>
        </div>
 
        <div style={{ display: "grid", gridTemplateColumns: "repeat(3, 1fr)", gap: "16px", marginBottom: "32px" }}>
          <div style={{ padding: "20px", background: "var(--color-neutral-background-subtle)", borderRadius: "8px" }}>
            <div style={{ fontSize: "14px", color: "var(--color-neutral-content-subtler)", marginBottom: "8px" }}>
              Total Tasks
            </div>
            <div style={{ fontSize: "32px", fontWeight: 600, color: "var(--color-neutral-content)" }}>1,247</div>
          </div>
          <div style={{ padding: "20px", background: "var(--color-neutral-background-subtle)", borderRadius: "8px" }}>
            <div style={{ fontSize: "14px", color: "var(--color-neutral-content-subtler)", marginBottom: "8px" }}>
              Completed
            </div>
            <div style={{ fontSize: "32px", fontWeight: 600, color: "var(--color-positive-content)" }}>892</div>
          </div>
          <div style={{ padding: "20px", background: "var(--color-neutral-background-subtle)", borderRadius: "8px" }}>
            <div style={{ fontSize: "14px", color: "var(--color-neutral-content-subtler)", marginBottom: "8px" }}>
              Agreement Score
            </div>
            <div style={{ fontSize: "32px", fontWeight: 600, color: "var(--color-neutral-content)" }}>94%</div>
          </div>
        </div>
 
        <div style={{ padding: "24px", background: "var(--color-neutral-background-subtle)", borderRadius: "8px" }}>
          <h3
            style={{ fontSize: "16px", fontWeight: 600, marginBottom: "16px", color: "var(--color-neutral-content)" }}
          >
            Annotation Velocity
          </h3>
          <div
            style={{
              height: "120px",
              background: "var(--color-neutral-background)",
              borderRadius: "4px",
              display: "flex",
              alignItems: "center",
              justifyContent: "center",
              color: "var(--color-neutral-content-subtler)",
            }}
          >
            Chart visualization would appear here
          </div>
        </div>
      </div>
      <EnterpriseUpgradeOverlay
        title="Get access to Project Dashboards!"
        description="Performance analytics are available within the Enterprise plan. Contact our sales team to get access to this and more!"
        feature="Dashboards"
      />
    </div>
  ),
};