-
Notifications
You must be signed in to change notification settings - Fork 6
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
Display account entitlements #7414
Conversation
WalkthroughThis pull request introduces several enhancements to the user interface and internationalization, focusing on account management, innovation pack creation, and user notifications. The changes span multiple components across the application, including translation files, UI components, and dialog management. Key modifications include adding new translation keys for account usage notices, creating reusable UI components like Changes
Suggested labels
Suggested reviewers
Possibly related PRs
Finishing Touches
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (13)
src/domain/innovationHub/CreateInnovationHub/CreateInnovationHubDialog.tsx (2)
57-58
: Enhance type checking for accountId.Consider using a more explicit check that covers both null and undefined cases:
- if (!accountId || !userId) { + if (accountId == null || userId == null) {
68-75
: Consider making locationType configurable.The
locationType
is hardcoded to "user". Consider making it configurable through props if this component might be used in different contexts.+type CreateInnovationHubDialogProps = { + // ... existing props + storageLocationType?: 'user' | 'other_types'; +}; // In the component -<StorageConfigContextProvider userId={userId} locationType="user"> +<StorageConfigContextProvider userId={userId} locationType={storageLocationType ?? 'user'}>src/core/ui/typography/TextWithTooltip.tsx (1)
5-11
: Enhance component type safety and performanceConsider the following improvements:
- Define an explicit interface for props
- Add React.memo for performance optimization
- Add aria-label for accessibility
+interface TextWithTooltipProps { + text: string; + tooltip: string; +} + -const TextWithTooltip = ({ text, tooltip }: { text: string; tooltip: string }) => { +const TextWithTooltip = React.memo(({ text, tooltip }: TextWithTooltipProps) => { return ( - <Tooltip arrow title={<Caption>{tooltip}</Caption>} placement="top"> + <Tooltip + arrow + title={<Caption>{tooltip}</Caption>} + placement="top" + aria-label={`${text} info`} + > <Text>{text}</Text> </Tooltip> ); -}; +}); + +TextWithTooltip.displayName = 'TextWithTooltip';src/core/ui/icon/RoundedIcon.tsx (2)
19-25
: Enhance accessibility and performanceThe disabled state should be reflected in ARIA attributes, and the theme usage could be optimized.
-const RoundedIcon = ({ size, iconSize = size, component: Icon, sx, disabled, ...containerProps }: RoundedIconProps) => ( +const RoundedIcon = React.memo(({ + size, + iconSize = size, + component: Icon, + sx, + disabled, + ...containerProps +}: RoundedIconProps) => ( <RoundedBadge color={disabled ? 'muted.main' : undefined} size={size} + aria-disabled={disabled} {...containerProps} sx={{ fontSize: theme => getFontSize(theme)(iconSize), ...sx }} > <Icon fontSize={iconSize === 'xsmall' ? 'inherit' : iconSize} /> </RoundedBadge> -); +)); + +RoundedIcon.displayName = 'RoundedIcon';
Line range hint
13-17
: Optimize getFontSize functionConsider memoizing the getFontSize function to prevent unnecessary recalculations.
-const getFontSize = (theme: Theme) => (iconSize: SvgIconProps['fontSize'] | 'xsmall') => { +const getFontSize = React.useMemo( + () => (theme: Theme) => (iconSize: SvgIconProps['fontSize'] | 'xsmall') => { if (iconSize === 'xsmall') { return theme.spacing(1.5); } -}; + }, + [] +);src/core/ui/button/CreationButton.tsx (3)
8-16
: Define explicit interface and add test IDThe props structure should be more formally defined and include a test ID for testing purposes.
+interface CreationButtonProps { + disabledTooltip: string; + onClick: () => void; + disabled?: boolean; + 'data-testid'?: string; +} + -const CreationButton = ({ +const CreationButton = React.memo(({ disabledTooltip, onClick, disabled, -}: { - disabledTooltip: string; - onClick: () => void; - disabled?: boolean; -}) => { + 'data-testid': testId = 'creation-button', +}: CreationButtonProps) => {
19-30
: Optimize button rendering and event handlingThe click handler should be memoized, and the button should include a test ID.
+ const handleClick = React.useCallback(() => { + onClick(); + }, [onClick]); + const button = ( <IconButton aria-label={t('common.add')} aria-disabled={disabled} aria-haspopup="true" size="small" - onClick={onClick} + onClick={handleClick} disabled={disabled} + data-testid={testId} >
32-38
: Simplify tooltip wrapper logicThe conditional rendering could be simplified using the MUI Tooltip's native behavior.
- return disabled && disabledTooltip ? ( - <Tooltip arrow placement="top" title={<Caption>{disabledTooltip}</Caption>}> - <Box>{button}</Box> - </Tooltip> - ) : ( - <>{button}</> - ); + return ( + <Tooltip + arrow + placement="top" + title={disabled ? <Caption>{disabledTooltip}</Caption> : ''} + > + <Box>{button}</Box> + </Tooltip> + );src/core/ui/content/PageContentBlock.tsx (1)
Line range hint
15-21
: Optimize OutlinedPaper componentConsider memoizing the OutlinedPaper component to prevent unnecessary re-renders.
-const OutlinedPaper = forwardRef( +const OutlinedPaper = React.memo(forwardRef( <D extends React.ElementType = PaperTypeMap['defaultComponent'], P = {}>( props: PaperProps<D, P>, ref: ForwardedRef<HTMLDivElement> ) => <Paper ref={ref} variant="outlined" {...props} /> -); +)); + +OutlinedPaper.displayName = 'OutlinedPaper';src/domain/innovationHub/InnovationHubsAdmin/InnovationHubForm.tsx (1)
94-94
: Consider extracting form field configuration.The form contains multiple FormikMarkdownField instances with similar props. Consider extracting the common configuration into a reusable constant or component.
+const MARKDOWN_FIELD_CONFIG = { + maxLength: MARKDOWN_TEXT_LENGTH, +}; <FormikMarkdownField title={t('common.description')} name="profile.description" - maxLength={MARKDOWN_TEXT_LENGTH} + {...MARKDOWN_FIELD_CONFIG} temporaryLocation={isNew} />Also applies to: 120-120
src/domain/InnovationPack/admin/InnovationPackForm.tsx (1)
121-124
: Consider prop type documentation.The
temporaryLocation
prop lacks type documentation. Consider adding a JSDoc comment explaining its purpose and type.+/** + * @param {object} props + * @param {boolean} props.temporaryLocation - Indicates if the markdown content should be stored in a temporary location + */ <FormikMarkdownField temporaryLocation={isNew} title={t('common.description')} name="profile.description" maxLength={MARKDOWN_TEXT_LENGTH} />src/domain/community/contributor/Account/ContributorAccountView.tsx (2)
197-217
: Consider extracting entitlement lookup logic.The repeated pattern of finding entitlements could be extracted into a helper function for better maintainability.
+const findEntitlementDetails = ( + entitlements: Pick<LicenseEntitlement, 'type' | 'limit' | 'usage'>[], + types: LicenseEntitlementType[] +) => { + return entitlements.find(entitlement => types.includes(entitlement.type)) ?? {}; +}; -const { limit: hostedSpaceLimit = 0, usage: hostedSpaceUsage = 0 } = - myAccountEntitlementDetails.find( - entitlement => - entitlement.type === LicenseEntitlementType.AccountSpaceFree || - entitlement.type === LicenseEntitlementType.AccountSpacePlus || - entitlement.type === LicenseEntitlementType.AccountSpacePremium - ) ?? {}; +const { limit: hostedSpaceLimit = 0, usage: hostedSpaceUsage = 0 } = findEntitlementDetails( + myAccountEntitlementDetails, + [ + LicenseEntitlementType.AccountSpaceFree, + LicenseEntitlementType.AccountSpacePlus, + LicenseEntitlementType.AccountSpacePremium + ] +);
424-434
: Consider accessibility improvements.The usage information could benefit from ARIA labels for screen readers.
<TextWithTooltip text={`${hostedSpaceUsage}/${hostedSpaceLimit}`} + aria-label={t('pages.admin.generic.sections.account.usageNotice', { + type: t('pages.admin.generic.sections.account.virtualContributors'), + usage: hostedSpaceUsage, + limit: hostedSpaceLimit, + })} tooltip={t('pages.admin.generic.sections.account.usageNotice', { type: t('pages.admin.generic.sections.account.virtualContributors'), usage: hostedSpaceUsage, limit: hostedSpaceLimit, })} />Also applies to: 475-485, 513-523, 549-559
📜 Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (3)
src/core/apollo/generated/apollo-helpers.ts
is excluded by!**/generated/**
src/core/apollo/generated/apollo-hooks.ts
is excluded by!**/generated/**
src/core/apollo/generated/graphql-schema.ts
is excluded by!**/generated/**
📒 Files selected for processing (13)
src/core/i18n/en/translation.en.json
(2 hunks)src/core/ui/button/CreationButton.tsx
(1 hunks)src/core/ui/content/PageContentBlock.tsx
(1 hunks)src/core/ui/content/PageContentColumn.tsx
(1 hunks)src/core/ui/forms/MarkdownInput/FormikMarkdownField.tsx
(1 hunks)src/core/ui/icon/RoundedIcon.tsx
(2 hunks)src/core/ui/typography/TextWithTooltip.tsx
(1 hunks)src/domain/InnovationPack/CreateInnovationPackDialog/CreateInnovationPackDialog.tsx
(2 hunks)src/domain/InnovationPack/admin/InnovationPackForm.tsx
(3 hunks)src/domain/account/queries/AccountInformation.graphql
(1 hunks)src/domain/community/contributor/Account/ContributorAccountView.tsx
(11 hunks)src/domain/innovationHub/CreateInnovationHub/CreateInnovationHubDialog.tsx
(2 hunks)src/domain/innovationHub/InnovationHubsAdmin/InnovationHubForm.tsx
(3 hunks)
✅ Files skipped from review due to trivial changes (2)
- src/core/ui/content/PageContentColumn.tsx
- src/core/ui/forms/MarkdownInput/FormikMarkdownField.tsx
🧰 Additional context used
📓 Path-based instructions (11)
src/core/ui/content/PageContentBlock.tsx (1)
Pattern src/**/*.{ts,tsx,js}
: Review the React.js/TypeScript/JavaScript code for best practices and potential bugs.
Ensure that the code adheres to TypeScript's typing system and modern standards.
Use the following code guide documentation in the codebase: 'docs/code-guidelines.md'.
Ensure sufficient error handling and logging is present, but note:
- We have a global error handler in place. So local
try/catch
blocks are not required unless they provide value beyond what the global error handler already covers. - Avoid flagging the absence of local error handling in cases where the global error handler suffices.
- Avoid flagging the absence of logging in cases where the global logger is already in place (graphql usage).
Inform about the recommendation of not using non-null assertion,
except on GraphQL queries where the variable is asserted non-null and followed by a
skip:
with the same variable.
Examples:
- Not Required: there's a skip
{
variables: { templateId: templateId! },
skip: !templateId,
}
Check for common security vulnerabilities such as:
- SQL Injection
- XSS (Cross-Site Scripting)
- CSRF (Cross-Site Request Forgery)
- Insecure dependencies
- Sensitive data exposure
src/domain/InnovationPack/admin/InnovationPackForm.tsx (1)
Pattern src/**/*.{ts,tsx,js}
: Review the React.js/TypeScript/JavaScript code for best practices and potential bugs.
Ensure that the code adheres to TypeScript's typing system and modern standards.
Use the following code guide documentation in the codebase: 'docs/code-guidelines.md'.
Ensure sufficient error handling and logging is present, but note:
- We have a global error handler in place. So local
try/catch
blocks are not required unless they provide value beyond what the global error handler already covers. - Avoid flagging the absence of local error handling in cases where the global error handler suffices.
- Avoid flagging the absence of logging in cases where the global logger is already in place (graphql usage).
Inform about the recommendation of not using non-null assertion,
except on GraphQL queries where the variable is asserted non-null and followed by a
skip:
with the same variable.
Examples:
- Not Required: there's a skip
{
variables: { templateId: templateId! },
skip: !templateId,
}
Check for common security vulnerabilities such as:
- SQL Injection
- XSS (Cross-Site Scripting)
- CSRF (Cross-Site Request Forgery)
- Insecure dependencies
- Sensitive data exposure
src/core/ui/icon/RoundedIcon.tsx (1)
Pattern src/**/*.{ts,tsx,js}
: Review the React.js/TypeScript/JavaScript code for best practices and potential bugs.
Ensure that the code adheres to TypeScript's typing system and modern standards.
Use the following code guide documentation in the codebase: 'docs/code-guidelines.md'.
Ensure sufficient error handling and logging is present, but note:
- We have a global error handler in place. So local
try/catch
blocks are not required unless they provide value beyond what the global error handler already covers. - Avoid flagging the absence of local error handling in cases where the global error handler suffices.
- Avoid flagging the absence of logging in cases where the global logger is already in place (graphql usage).
Inform about the recommendation of not using non-null assertion,
except on GraphQL queries where the variable is asserted non-null and followed by a
skip:
with the same variable.
Examples:
- Not Required: there's a skip
{
variables: { templateId: templateId! },
skip: !templateId,
}
Check for common security vulnerabilities such as:
- SQL Injection
- XSS (Cross-Site Scripting)
- CSRF (Cross-Site Request Forgery)
- Insecure dependencies
- Sensitive data exposure
src/domain/innovationHub/InnovationHubsAdmin/InnovationHubForm.tsx (1)
Pattern src/**/*.{ts,tsx,js}
: Review the React.js/TypeScript/JavaScript code for best practices and potential bugs.
Ensure that the code adheres to TypeScript's typing system and modern standards.
Use the following code guide documentation in the codebase: 'docs/code-guidelines.md'.
Ensure sufficient error handling and logging is present, but note:
- We have a global error handler in place. So local
try/catch
blocks are not required unless they provide value beyond what the global error handler already covers. - Avoid flagging the absence of local error handling in cases where the global error handler suffices.
- Avoid flagging the absence of logging in cases where the global logger is already in place (graphql usage).
Inform about the recommendation of not using non-null assertion,
except on GraphQL queries where the variable is asserted non-null and followed by a
skip:
with the same variable.
Examples:
- Not Required: there's a skip
{
variables: { templateId: templateId! },
skip: !templateId,
}
Check for common security vulnerabilities such as:
- SQL Injection
- XSS (Cross-Site Scripting)
- CSRF (Cross-Site Request Forgery)
- Insecure dependencies
- Sensitive data exposure
src/core/ui/typography/TextWithTooltip.tsx (1)
Pattern src/**/*.{ts,tsx,js}
: Review the React.js/TypeScript/JavaScript code for best practices and potential bugs.
Ensure that the code adheres to TypeScript's typing system and modern standards.
Use the following code guide documentation in the codebase: 'docs/code-guidelines.md'.
Ensure sufficient error handling and logging is present, but note:
- We have a global error handler in place. So local
try/catch
blocks are not required unless they provide value beyond what the global error handler already covers. - Avoid flagging the absence of local error handling in cases where the global error handler suffices.
- Avoid flagging the absence of logging in cases where the global logger is already in place (graphql usage).
Inform about the recommendation of not using non-null assertion,
except on GraphQL queries where the variable is asserted non-null and followed by a
skip:
with the same variable.
Examples:
- Not Required: there's a skip
{
variables: { templateId: templateId! },
skip: !templateId,
}
Check for common security vulnerabilities such as:
- SQL Injection
- XSS (Cross-Site Scripting)
- CSRF (Cross-Site Request Forgery)
- Insecure dependencies
- Sensitive data exposure
src/domain/account/queries/AccountInformation.graphql (1)
Pattern src/**/*.{graphql,gql}
: Review the GraphQL schema and queries for best practices, potential bugs, and adherence to the project's GraphQL standards.
Ensure that the schema is well-defined and queries are optimized.
Check for security vulnerabilities.
src/core/ui/button/CreationButton.tsx (1)
Pattern src/**/*.{ts,tsx,js}
: Review the React.js/TypeScript/JavaScript code for best practices and potential bugs.
Ensure that the code adheres to TypeScript's typing system and modern standards.
Use the following code guide documentation in the codebase: 'docs/code-guidelines.md'.
Ensure sufficient error handling and logging is present, but note:
- We have a global error handler in place. So local
try/catch
blocks are not required unless they provide value beyond what the global error handler already covers. - Avoid flagging the absence of local error handling in cases where the global error handler suffices.
- Avoid flagging the absence of logging in cases where the global logger is already in place (graphql usage).
Inform about the recommendation of not using non-null assertion,
except on GraphQL queries where the variable is asserted non-null and followed by a
skip:
with the same variable.
Examples:
- Not Required: there's a skip
{
variables: { templateId: templateId! },
skip: !templateId,
}
Check for common security vulnerabilities such as:
- SQL Injection
- XSS (Cross-Site Scripting)
- CSRF (Cross-Site Request Forgery)
- Insecure dependencies
- Sensitive data exposure
src/core/i18n/en/translation.en.json (1)
Pattern src/**/*.json
: Review the JSON files for correct syntax and structure.
Ensure that the configuration and data are accurate and follow the project's standards.
Check for sensitive data exposure and ensure that the data is properly validated.
src/domain/innovationHub/CreateInnovationHub/CreateInnovationHubDialog.tsx (1)
Pattern src/**/*.{ts,tsx,js}
: Review the React.js/TypeScript/JavaScript code for best practices and potential bugs.
Ensure that the code adheres to TypeScript's typing system and modern standards.
Use the following code guide documentation in the codebase: 'docs/code-guidelines.md'.
Ensure sufficient error handling and logging is present, but note:
- We have a global error handler in place. So local
try/catch
blocks are not required unless they provide value beyond what the global error handler already covers. - Avoid flagging the absence of local error handling in cases where the global error handler suffices.
- Avoid flagging the absence of logging in cases where the global logger is already in place (graphql usage).
Inform about the recommendation of not using non-null assertion,
except on GraphQL queries where the variable is asserted non-null and followed by a
skip:
with the same variable.
Examples:
- Not Required: there's a skip
{
variables: { templateId: templateId! },
skip: !templateId,
}
Check for common security vulnerabilities such as:
- SQL Injection
- XSS (Cross-Site Scripting)
- CSRF (Cross-Site Request Forgery)
- Insecure dependencies
- Sensitive data exposure
src/domain/InnovationPack/CreateInnovationPackDialog/CreateInnovationPackDialog.tsx (1)
Pattern src/**/*.{ts,tsx,js}
: Review the React.js/TypeScript/JavaScript code for best practices and potential bugs.
Ensure that the code adheres to TypeScript's typing system and modern standards.
Use the following code guide documentation in the codebase: 'docs/code-guidelines.md'.
Ensure sufficient error handling and logging is present, but note:
- We have a global error handler in place. So local
try/catch
blocks are not required unless they provide value beyond what the global error handler already covers. - Avoid flagging the absence of local error handling in cases where the global error handler suffices.
- Avoid flagging the absence of logging in cases where the global logger is already in place (graphql usage).
Inform about the recommendation of not using non-null assertion,
except on GraphQL queries where the variable is asserted non-null and followed by a
skip:
with the same variable.
Examples:
- Not Required: there's a skip
{
variables: { templateId: templateId! },
skip: !templateId,
}
Check for common security vulnerabilities such as:
- SQL Injection
- XSS (Cross-Site Scripting)
- CSRF (Cross-Site Request Forgery)
- Insecure dependencies
- Sensitive data exposure
src/domain/community/contributor/Account/ContributorAccountView.tsx (1)
Pattern src/**/*.{ts,tsx,js}
: Review the React.js/TypeScript/JavaScript code for best practices and potential bugs.
Ensure that the code adheres to TypeScript's typing system and modern standards.
Use the following code guide documentation in the codebase: 'docs/code-guidelines.md'.
Ensure sufficient error handling and logging is present, but note:
- We have a global error handler in place. So local
try/catch
blocks are not required unless they provide value beyond what the global error handler already covers. - Avoid flagging the absence of local error handling in cases where the global error handler suffices.
- Avoid flagging the absence of logging in cases where the global logger is already in place (graphql usage).
Inform about the recommendation of not using non-null assertion,
except on GraphQL queries where the variable is asserted non-null and followed by a
skip:
with the same variable.
Examples:
- Not Required: there's a skip
{
variables: { templateId: templateId! },
skip: !templateId,
}
Check for common security vulnerabilities such as:
- SQL Injection
- XSS (Cross-Site Scripting)
- CSRF (Cross-Site Request Forgery)
- Insecure dependencies
- Sensitive data exposure
🔇 Additional comments (15)
src/domain/innovationHub/CreateInnovationHub/CreateInnovationHubDialog.tsx (3)
16-25
: LGTM! Props are well-typed and follow best practices.The component signature is properly typed with TypeScript, and optional props have appropriate default values.
28-29
: LGTM! User context integration is properly implemented.The user context is correctly retrieved and safely accessed.
52-52
: LGTM! Mutation handling follows best practices.The onClose callback is safely called using optional chaining after successful mutation completion.
src/domain/InnovationPack/CreateInnovationPackDialog/CreateInnovationPackDialog.tsx (4)
8-10
: LGTM! Good use of global notification and storage context.The addition of the notification system and storage context provider enhances the component's functionality.
12-20
: Props interface is well-defined.The component's props are properly typed with clear optional flags and default values.
44-50
: Good error handling implementation.The mutation callbacks are well implemented with appropriate success/error notifications and cleanup.
54-54
: Verify user context availability.The component relies on the user context being available. Consider adding a loading state or fallback UI when the user context is not yet available.
Also applies to: 65-67
src/domain/innovationHub/InnovationHubsAdmin/InnovationHubForm.tsx (1)
Line range hint
139-144
: LGTM! Clean layout implementation.The Box component's layout properties are well organized for right-aligned buttons.
src/domain/InnovationPack/admin/InnovationPackForm.tsx (1)
48-50
: Good documentation practice.Clear JSDoc comment indicating the component's context requirements.
src/domain/community/contributor/Account/ContributorAccountView.tsx (2)
158-160
: Good state management practice.Separate state variables for each dialog improve code clarity and maintainability.
594-594
: Consider PII implications.The external subscription ID might be considered sensitive information. Verify if it should be displayed in the UI.
✅ Verification successful
External subscription ID display is consistent with codebase patterns
Based on the codebase analysis, the external subscription ID is treated as non-sensitive information throughout the system. The codebase shows clear patterns for handling sensitive data (with private modes and security indicators), and this ID is not subject to such special handling. Its display is consistent with other reference IDs in the UI.
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Check for other instances of external ID display rg -i "wingback.*id|external.*subscription.*id"Length of output: 1084
Script:
#!/bin/bash # Search for PII/privacy documentation and similar ID displays echo "=== Searching documentation for PII/privacy guidelines ===" rg -i "PII|personally identifiable|privacy|sensitive.*(data|information)" -g "*.md" -g "*.txt" echo -e "\n=== Checking for other ID displays in UI components ===" rg -i "id:.*{.*}|id=.*{.*}|\bid\b.*:.*{.*}" -g "*.tsx" -g "*.jsx" -A 2 echo -e "\n=== Looking for security/privacy configurations ===" fd -g "*security*.ts" -g "*privacy*.ts" -g "*sensitive*.ts"Length of output: 1397
Script:
#!/bin/bash # Search with corrected patterns echo "=== Checking for other ID displays in UI ===" rg -i "id:\s*['\"]?{|id=['\"]?{|\bid\b\s*:\s*['\"]?{" -g "*.tsx" -g "*.jsx" -A 2 echo -e "\n=== Looking for security/privacy related files ===" fd -e ts -e tsx -e js -e jsx | rg -i "security|privacy|sensitive" echo -e "\n=== Checking for sensitive data handling patterns ===" rg -i "sensitive|confidential|private|secure" -g "*.ts" -g "*.tsx" -g "*.js" -g "*.jsx"Length of output: 10281
src/domain/account/queries/AccountInformation.graphql (2)
5-5
: LGTM: External subscription ID field added correctlyThe
externalSubscriptionID
field is properly placed within the account object scope.
13-17
: LGTM: Well-structured entitlements fieldsThe entitlements structure with
type
,limit
, andusage
fields provides a clean way to track account usage limits.src/core/i18n/en/translation.en.json (2)
1961-1962
: LGTM: Clear account usage notificationsThe translations for account usage and limit notices are clear and informative:
- Usage notice properly includes placeholders for dynamic values
- Limit notice provides clear instruction for users
2166-2171
: LGTM: Consistent innovation pack notificationsThe translations for innovation pack operations follow a consistent pattern:
- Success/error messages are clear and concise
- Pack removal message includes the pack name placeholder
* wip * removed state from some dialogs --------- Co-authored-by: Carlos Cano <carlos@alkem.io>
* fix forum discussion styles * update contributors image for unauth users and fix styles (#7354) * update contributors image for unauth users and fix styles * resolve pr comments * Remove location from VC card * remove usage of anonymousReadAccess (#7332) * Fix dashboard access (#7360) * Fix dashboard access * fixed scope * change polling interval * fix pr comment * renamed to useSpaceTemplate*s*ManagerQuery --------- Co-authored-by: Carlos Cano <carlos@alkem.io> * Handling of scroll and page change in documentation. (#7359) * logs for the frame origin * add allow-scripts to the docs iframe * Improve the layout banner of Documentation page; * Subtitle for the Docs page * added new tabs to user + org admin pages; refactored contributor admin pages (#7367) * added new tabs to user + org admin pages; refactored how admin pages for users + orgs + vcs are managed; moved some global admin functionality out of domain down to platform admin; ... * updated generation to match api tidy ups related to set of preference types + ID passing for org mutations * fix compile errors related to dropping of separate UserPreferenceType enum * Synchronize icons, remove comments, make sure there are no redundant settings calls. * Links & Docs to BoK on VC creation (#7365) * VC documents and links BoK - refactor the AddContent * VC documents and links implementation without validation; * resolve rabbit comments --------- Co-authored-by: Petar Kolev <33326233+reactoholic@users.noreply.github.com> Co-authored-by: reactoholic <petar.georgiev.kolev@gmail.com> * Links and Docs - forgotten commit with Validation (#7377) * CalloutsSet entity (#7376) * codegen passing with updated api * fixed api + codegen passes * code compiling * pick up create callout privilege from the CalloutsSet * callouts showing up after creation * retrieving of callouts using only calloutsSet ID * moved code around to have notion of calloutsSet in tree * fix array dep breaking tool creation; small code optimizations; --------- Co-authored-by: bobbykolev <bobbykolev@abv.bg> * split useCallouts into also useCalloutsOnCollaboration (#7378) * Style UserAvatar tooltip (#7384) * Fix: Deleting subspace l2 from its settings throws errors on space dashboard * InnovationFlow States names validation - no commas (#7391) * Add arcadeSoftware to the whitelist of iframes (#7397) * bump client version (#7403) * implement image pasting in md editor (#7387) * codegen compilation * Fix: ENTITY_NOT_FOUND Error is triggered after first login server#4790 (#7396) * Remove `makeStyles` from `AlkemioAvatar` and `CommunityUpdatesView` (#7390) * Clean up alkemio avatar component The goal is to remove `@mui/styles`, but as the component is deprecated, it is replaced with the new avatar component in the user popup and the deprecated component is cleaned up from all unused features. The user popup is inlined in it to simplify more the interface of the component. * update contributors image for unauth user (#7410) * bug fix: verified label overlaps with text (#7415) * removed usage of AuthorizationCredential, replaced with RoleName; removed usage of UserGroups * added label to issue templates (#7425) * Limit the answers length on ApplicationForm (#7419) * Limit the answers length on ApplicationForm * Fix error message --------- Co-authored-by: Petar Kolev <33326233+reactoholic@users.noreply.github.com> * Display account entitlements (#7414) * wip * removed state from some dialogs --------- Co-authored-by: Carlos Cano <carlos@alkem.io> * Fix: ENTITY_NOT_FOUND Error is triggered after first login server#4790 (#7396) * Remove `makeStyles` from `AlkemioAvatar` and `CommunityUpdatesView` (#7390) * Clean up alkemio avatar component The goal is to remove `@mui/styles`, but as the component is deprecated, it is replaced with the new avatar component in the user popup and the deprecated component is cleaned up from all unused features. The user popup is inlined in it to simplify more the interface of the component. * update contributors image for unauth user (#7410) * bug fix: verified label overlaps with text (#7415) * added label to issue templates (#7425) * Limit the answers length on ApplicationForm (#7419) * Limit the answers length on ApplicationForm * Fix error message --------- Co-authored-by: Petar Kolev <33326233+reactoholic@users.noreply.github.com> * Display account entitlements (#7414) * wip * removed state from some dialogs --------- Co-authored-by: Carlos Cano <carlos@alkem.io> * update contributors image for unauth user (#7410) * first pass fixing * second pass * Third pass * 6 errors left * Removing scary words in translation.en.json (#7432) * moved to using UUIDs * Add Updates from leads block to the subspaces page (l1 & l2). (#7417) * Add Updates from leads block to the subspaces page (l1 & l2). * share url --------- Co-authored-by: Carlos Cano <carlos@alkem.io> * Fix Sidebar list of spaces not refreshing after subspace delete (#7418) Co-authored-by: Petar Kolev <33326233+reactoholic@users.noreply.github.com> * fix * [VC] Knowledge base instead of Subspace BoK in Written Knowledge step (#7381) * added new tabs to user + org admin pages; refactored how admin pages for users + orgs + vcs are managed; moved some global admin functionality out of domain down to platform admin; ... * updated generation to match api tidy ups related to set of preference types + ID passing for org mutations * fix compile errors related to dropping of separate UserPreferenceType enum * Synchronize icons, remove comments, make sure there are no redundant settings calls. * Links & Docs to BoK on VC creation (#7365) * VC documents and links BoK - refactor the AddContent * VC documents and links implementation without validation; * resolve rabbit comments --------- Co-authored-by: Petar Kolev <33326233+reactoholic@users.noreply.github.com> Co-authored-by: reactoholic <petar.georgiev.kolev@gmail.com> * Links and Docs - forgotten commit with Validation (#7377) * CalloutsSet entity (#7376) * codegen passing with updated api * fixed api + codegen passes * code compiling * pick up create callout privilege from the CalloutsSet * callouts showing up after creation * retrieving of callouts using only calloutsSet ID * moved code around to have notion of calloutsSet in tree * fix array dep breaking tool creation; small code optimizations; --------- Co-authored-by: bobbykolev <bobbykolev@abv.bg> * VC knowledge base instead of subspace init * Space creation after VC creation, loading, code opt & reorganization * Fix docs uploading, code organization and documentation; * fix uploading of docs in case there's no space under the acc; remove misleading createdSpaceId usage; * useLoadingState instead of a new React State * Fix - set properly the persona type depending on the 3 steps; * Ability to select SpaceLevel2 on create VC (#7386) * VC Knowledge Base callouts dialog (#7388) * VC Knowledge Base callouts dialog - init. * Filter available callout types. * disable rich media on VC callout creation. * Description component with update functionality. * Update the Create Written Knowledge UI and initial state; Fix dialog titles in VC flow. * Reingest logic in the Knowledge dialog. * Remove the icon logic for CalloutVisibilityChangeDialog. * Use the account hostname for space created in the VC flow. * fix VC dialog not opening; remove outdated copy; * storage config for KnowledgeBase description --------- Co-authored-by: Neil Smyth <neil@thesmyths.eu> Co-authored-by: Petar Kolev <33326233+reactoholic@users.noreply.github.com> Co-authored-by: reactoholic <petar.georgiev.kolev@gmail.com> Co-authored-by: Neil Smyth <30729240+techsmyth@users.noreply.github.com> Co-authored-by: Carlos Cano <carlos@alkem.io> * add cspell config (#7404) * resolveIds returns string and not the entity * proper check for available account for the vc flow (#7433) * VirtualContributor fixes * name ids * updated for renamed mutation * Client web/7416 disable image pasting when hide image options flag is true (#7428) * fix organization verified sign font size by simone's ask * disable image pasting if hideImageOptions flag is true * optimize paste handler * resolve pr comment * Extract the isImageOrHtmlWithImage and call it once per item. --------- Co-authored-by: Bobby Kolev <bobbykolev@abv.bg> * Fix can't add callout to VC KnowledgeBase. (#7437) Co-authored-by: Valentin Yanakiev <valentin.yanakiev@gmail.com> * url resolver * url builders * Create space link entitlements (#7442) * check for entitlements in the CreateSpaceLink (cherry picked from commit aed1830) * 0.79.7 (cherry picked from commit 7ec232c) * updated to work with fields for entryRole + elevatedRole availability * MD fixes - comments not visible with long Post description; `pre` long line not visible; (#7435) * move fragment * missing padding for the items on the left block on space and subspaces (#7448) * Optimize the Contributor Account Tab and VC flow (#7444) * Optimize subspace query under acc. Fix first VC/Space flow resulting in errors. * Fix add to community and navigation related to spaceId * polishing * fix navigation of subspaces * Optimize the main vcWizard account call. * pr fix --------- Co-authored-by: Carlos Cano <carlos@alkem.io> * Admin Roles management * Available users search. Organizations auth using rolesetAdmin * Organization roles management * fix style * clean up. first 0 errors * removed usage of platform role set id on mutations for roles on platform as not needed (only one) * check for the correct privilege for Callout creation * Add checkbox for adding tutorials when creating new space and fix UI issue in Mozilla regarding the URL input (#7447) * updated for adjusted privilege names * [VC Flow] Choose community step (#7457) * choose community step in vc flow * fix data reload on home dash; * refetch the BoK after VC callouts creation * Append visuals to create profile input (#7301) * profileData renamed to profile on CreateWhiteboardInput * Removed visualUrl from post, which doens't make sense on creation * graphical tweak and little rename * Fix #7316 Create template permission (#7319) * Filter file extensions robustly (#7326) * Fix creating a subspace on a Space by nameId (#7328) * Fix creating a subspace on a Space by nameId * remove unused var * Fix Tutorials Iframes (#7323) * Fix tutorials iframes * parse the iframe with the DOMParser instead of with regex --------- Co-authored-by: Valentin Yanakiev <valentin.yanakiev@gmail.com> * Add Callouts preview accordion on SubspacesList default subspace template selector (#7325) * Add Callouts preview accordion on SubspacesList default subspace template selector * usememo * memoize the Description component --------- Co-authored-by: Valentin Yanakiev <valentin.yanakiev@gmail.com> * codegen --------- Co-authored-by: Valentin Yanakiev <valentin.yanakiev@gmail.com> * restrict activities block to 10 results and add activities dialog (#7463) * Handle missing privileges for add VC to community. (#7470) * Fix the save as template option missing due to missing array deps (#7476) * Remove nameIds from VC dialogs * Entitlements view based on permissions and limits (#7467) * Fix #7451 * Common component to handle the --------- Co-authored-by: Svetoslav Petkov <svetoslav@alkem.io> * display usage-limit of spaces in the account page (#7468) * display usage-limit of spaces in the account page * making safer check --------- Co-authored-by: Svetoslav Petkov <svetoslav@alkem.io> * removed another url builder * Remove SpaceRoleSetContributorTypes query and a few unused queries more * Fix innovationHubs * Fix add checkbox for tutorials UI bug (#7466) * fix add checkbox for tutorials ui * restore graphql files --------- Co-authored-by: Bobby Kolev <bobbykolev@abv.bg> * Fix first-child + useEffect dynamic deps array length console errors; (#7477) Co-authored-by: Petar Kolev <33326233+reactoholic@users.noreply.github.com> * Bug fix: search bar in spaces page not working, and page refreshes on search term enter (#7462) * search spaces page not working * visualize subspaces as well * resolve pr comment * resolve pr comment * fix missing callouts in create template preview (#7482) Co-authored-by: Petar Kolev <33326233+reactoholic@users.noreply.github.com> * Fix organization provider * clean * Rename files * Removed variables from notification query (#7481) * First pass removing useCommunityAdmin * rename forlder * wip * VC Flow - proper filtering of Existing Spaces (#7490) * apply multiple filters on space activities (#7489) Co-authored-by: Bobby Kolev <bobbykolev@abv.bg> * Available users/orgs/vcs hook * support knowledge-base route on VC profile (#7480) * fix nameId issue on VC profile * fix userNameId issues on UserProfile * a bit of cleanup. 0 errors again * fix paste issue (#7493) * removing fragment CommunityRoleSetDetails * clean up * Moved files * Remove groups * VC Flow - proper filtering of Existing Spaces (#7490) * apply multiple filters on space activities (#7489) Co-authored-by: Bobby Kolev <bobbykolev@abv.bg> * support knowledge-base route on VC profile (#7480) * fix paste issue (#7493) * VC Flow - proper filtering of Existing Spaces (#7490) * UserPage clean nameId * Removed some unused code * ApplicationDialog * invitations in RolesetAdmin * Delete more group things * updatePreference mutation * remove useInviteUsers * fix md editor typing issue (#7501) * small refactor * no space creation when org has no spaces and vc is created * refetch * Account storage config for the account resources (#7486) * use account storage config for entities under the account (instead userStorage) * refactor a bit --------- Co-authored-by: Carlos Cano <carlos@alkem.io> * disable new posts on knowledgebase callouts (#7507) * knowledgebase-disable-new-posts (#7509) * No default callouts on space creation w tutorials (#7518) * update graphql schema * Add VC Callouts route (#7515) * Url for posts that are inside VC knowledge-base * fix url resolver * 0.80.0 (#7526) * reingest after creation of a VC with Space BoK (#7536) * 0.80.1 * BugFix anonymous user access to public space (#7541) * crowdin config (#7549) * Fix search in space (#7552) * Fix search in space * Also use the lookup for space details * Translations (#7553) * 0.80.2 * disabled Crowdin action --------- Co-authored-by: reactoholic <petar.georgiev.kolev@gmail.com> Co-authored-by: Petar Kolev <33326233+reactoholic@users.noreply.github.com> Co-authored-by: Carlos Cano <carlos@alkem.io> Co-authored-by: Neil Smyth <30729240+techsmyth@users.noreply.github.com> Co-authored-by: Valentin Yanakiev <valentin.yanakiev@gmail.com> Co-authored-by: Neil Smyth <neil@thesmyths.eu> Co-authored-by: Todorka Halacheva <56818790+thalacheva@users.noreply.github.com> Co-authored-by: Svetoslav Petkov <svetoslav@alkem.io> Co-authored-by: Simone <38861315+SimoneZaza@users.noreply.github.com> Co-authored-by: Evgeni Dimitrov <comoque@gmail.com>
Summary by CodeRabbit
Release Notes
New Features
Improvements
UI Updates
Localization