Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
425c61d
chore: monorepo tooling: pnpm workspace, turbo scripts, CI regroup, docs
tyhonchik Jul 6, 2026
db643bb
chore: Update return type of useSimulateProposalCreation to distingui…
milosh86 Jul 8, 2026
347a8a8
feat: disable process list items where user is not eligible
milosh86 Jul 8, 2026
3182af7
fix: onClick type issue
milosh86 Jul 8, 2026
2edea33
fix: update text style and size
milosh86 Jul 8, 2026
e9a1db3
chore: add changeset
milosh86 Jul 8, 2026
e223875
Merge branch 'chore/monorepo-skeleton' into app-978-update-usesimulat…
milosh86 Jul 8, 2026
8902538
Merge branch 'app-978-update-usesimulateproposalcreation-params-and-r…
milosh86 Jul 8, 2026
d11d713
chore: add changeset
milosh86 Jul 8, 2026
8c2874e
chore: derive aria-disabled from isDisabled flag
milosh86 Jul 8, 2026
e7472c4
fix: var typo
milosh86 Jul 8, 2026
485e68b
Merge branch 'main' into app-978-update-usesimulateproposalcreation-p…
milosh86 Jul 9, 2026
d286402
Merge branch 'app-978-update-usesimulateproposalcreation-params-and-r…
milosh86 Jul 9, 2026
227e175
chore: remove #proposal-creation-eligibility ID
milosh86 Jul 9, 2026
97d28bc
fix: update eligibility presentation
milosh86 Jul 9, 2026
ab8cb94
feat: implement process sort by eligibility
milosh86 Jul 9, 2026
4b54a43
fix: add useMemo to transaction building
milosh86 Jul 9, 2026
657f4c9
chore: add changeset
milosh86 Jul 9, 2026
bcdc45d
Merge branch 'app-978-update-usesimulateproposalcreation-params-and-r…
milosh86 Jul 9, 2026
cc2d2b9
Merge branch 'app-979-add-simulation-to-processdatalistitem' into app…
milosh86 Jul 9, 2026
b29d127
refactor: simplify based on PR review
milosh86 Jul 9, 2026
2013f09
fix: cover corner case when dao is not loaded
milosh86 Jul 9, 2026
2d1739b
Merge branch 'app-978-update-usesimulateproposalcreation-params-and-r…
milosh86 Jul 9, 2026
565259f
Merge branch 'app-979-add-simulation-to-processdatalistitem' into app…
milosh86 Jul 9, 2026
e0cc7a9
feat: implement scrolling into proposal creation eligibility section …
milosh86 Jul 10, 2026
5f7ed63
refactor: don't render process description fallback if description no…
milosh86 Jul 10, 2026
debc1ff
refactor: don't refetch simulation on focus to prevent UI jump
milosh86 Jul 10, 2026
bb10987
fix: test should only check relevant flags
milosh86 Jul 10, 2026
6d3868a
chore: add changeset
milosh86 Jul 10, 2026
0cd4e32
Merge branch 'main' into app-983-fix-scroll-to-eligibility-section-an…
milosh86 Jul 15, 2026
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
5 changes: 5 additions & 0 deletions .changeset/app-983-fix-scroll-to-eligibility-section.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@aragon/app": patch
---

Implement scrolling into the proposal creation eligibility section and remove the "No description" fallback text
1 change: 0 additions & 1 deletion apps/app/src/assets/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -3863,7 +3863,6 @@
"defaultName": "No name {{type}} policy"
},
"processDataListItem": {
"defaultDescription": "No description",
"notEligible": "Not eligible",
"viewRequirements": "View requirements"
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,9 @@ describe('useSimulateProposalCreation hook', () => {
);

expect(useCallSpy).toHaveBeenCalledWith(
expect.objectContaining({ query: { enabled: false } }),
expect.objectContaining({
query: expect.objectContaining({ enabled: false }),
}),
);
});

Expand All @@ -135,7 +137,9 @@ describe('useSimulateProposalCreation hook', () => {
);

expect(useCallSpy).toHaveBeenCalledWith(
expect.objectContaining({ query: { enabled: false } }),
expect.objectContaining({
query: expect.objectContaining({ enabled: false }),
}),
);
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ export const useSimulateProposalCreation = (
...transactionData,
query: {
enabled: isEnabled,
refetchOnWindowFocus: false,
},
});

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
'use client';

import { Card, DateFormat, formatterUtils } from '@aragon/gov-ui-kit';
import { useEffect } from 'react';
import { FormProvider, useForm } from 'react-hook-form';
import type { ICreateDaoFormData } from '@/modules/createDao/components/createDaoForm';
import {
Expand All @@ -17,6 +18,7 @@ import type {
} from '@/modules/governance/types';
import { useDao } from '@/shared/api/daoService';
import { Page } from '@/shared/components/page';
import { proposalCreationEligibilityAnchor } from '@/shared/components/processDataListItem';
import { useTranslations } from '@/shared/components/translationsProvider';
import { useDaoPlugins } from '@/shared/hooks/useDaoPlugins';
import { useIsMounted } from '@/shared/hooks/useIsMounted';
Expand Down Expand Up @@ -139,6 +141,22 @@ export const DaoProcessDetailsPageClient: React.FC<
? (slotResult ?? fallback)
: fallback;

const hasProposalCreationEligibility =
settings != null && settings.length > 0;

useEffect(() => {
if (
!hasProposalCreationEligibility ||
window.location.hash !== `#${proposalCreationEligibilityAnchor}`
) {
return;
}

document
.getElementById(proposalCreationEligibilityAnchor)
?.scrollIntoView({ behavior: 'smooth', block: 'start' });
}, [hasProposalCreationEligibility]);

return (
<>
<Page.Header
Expand Down Expand Up @@ -171,8 +189,9 @@ export const DaoProcessDetailsPageClient: React.FC<
)}
</FormProvider>
</Page.MainSection>
{settings != null && settings.length > 0 && (
{hasProposalCreationEligibility && (
<Page.MainSection
id={proposalCreationEligibilityAnchor}
title={t(
'app.settings.daoProcessDetailsPage.section.creationEligibility',
)}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
export {
type IProcessDataListItemProps,
ProcessDataListItem,
proposalCreationEligibilityAnchor,
} from './processDataListItem';
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@ import { DaoTargetIndicator } from '@/shared/components/daoTargetIndicator';
import { daoUtils } from '@/shared/utils/daoUtils';
import { useTranslations } from '../translationsProvider';

/**
* Hash anchor of the proposal-creation eligibility section on the process
* settings page. Appended to the settings link so the settings page scrolls the
* section into view once it has rendered.
*/
export const proposalCreationEligibilityAnchor =
'proposal-creation-eligibility';

export type IProcessDataListItemProps = IDataListItemProps & {
/**
* Process to display the details for.
Expand Down Expand Up @@ -44,10 +52,8 @@ export const ProcessDataListItem: React.FC<IProcessDataListItemProps> = (

const { address, description, slug } = process;

const processedDescription =
description != null && description.length > 0
? description
: t('app.shared.processDataListItem.defaultDescription');
const processDescription =
description != null && description.length > 0 ? description : undefined;

return (
<DataList.Item
Expand Down Expand Up @@ -75,17 +81,22 @@ export const ProcessDataListItem: React.FC<IProcessDataListItemProps> = (
{slug}
</p>
</div>
<p className="line-clamp-2 font-normal text-neutral-500 text-sm leading-normal md:text-base">
{processedDescription}
</p>
{processDescription && (
<p className="line-clamp-2 font-normal text-neutral-500 text-sm leading-normal md:text-base">
{processDescription}
</p>
)}
</div>
<DaoTargetIndicator dao={dao} plugin={process} size="sm" />
</div>
{showNotEligibleHelpText && (
<div className="text-neutral-300 text-sm md:text-base">
{t('app.shared.processDataListItem.notEligible')} •{' '}
<Link
href={daoUtils.getDaoUrl(dao, `settings/${slug}`)}
href={daoUtils.getDaoUrl(
dao,
`settings/${slug}#${proposalCreationEligibilityAnchor}`,
)}
isExternal={true}
>
{t(
Expand Down
Loading