-
Notifications
You must be signed in to change notification settings - Fork 17
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
feat: add new privacy type #954
base: master
Are you sure you want to change the base?
Conversation
Comments:
|
…into author-privacy-selection
…into author-privacy-selection
…into author-privacy-selection
Just tested and the design looks good |
…into author-privacy-selection
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.
Copilot reviewed 5 out of 20 changed files in this pull request and generated no suggestions.
Files not reviewed (15)
- apps/ui/src/components/FormSpaceVoting.vue: Evaluated as low risk
- apps/ui/src/components/Modal/SelectPrivacy.vue: Evaluated as low risk
- apps/ui/src/views/Space/Editor.vue: Evaluated as low risk
- apps/ui/src/views/Proposal/Overview.vue: Evaluated as low risk
- apps/ui/src/composables/useActions.ts: Evaluated as low risk
- packages/sx.js/src/types/index.ts: Evaluated as low risk
- packages/sx.js/src/clients/offchain/types.ts: Evaluated as low risk
- apps/ui/src/helpers/constants.ts: Evaluated as low risk
- packages/sx.js/src/clients/offchain/ethereum-sig/types.ts: Evaluated as low risk
- apps/ui/src/networks/starknet/actions.ts: Evaluated as low risk
- apps/ui/src/networks/types.ts: Evaluated as low risk
- apps/ui/src/networks/offchain/api/index.ts: Evaluated as low risk
- apps/ui/src/networks/evm/actions.ts: Evaluated as low risk
- apps/ui/src/networks/common/graphqlApi/index.ts: Evaluated as low risk
- apps/ui/src/networks/offchain/actions.ts: Evaluated as low risk
Comments skipped due to low confidence (1)
apps/ui/src/composables/useSpaceSettings.ts:164
- [nitpick] The use of an empty string ('') as a valid value for the privacy field might be ambiguous. Consider using a more descriptive value or ensure that its use is well-documented.
const privacy = ref<'' | 'shutter' | 'any'>('');
…into author-privacy-selection
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.
It look good to me, maybe only thing that I'd change is avoid using ""
as a value with meaning (like before we had "none"
for this that got converted at the edge when storing/retrieving settings). Any reason we ended up introducing it (other than to make it match offchain space settings)?
I'd rather keep clearer values like "none" | "any" | "shutter"
.
@@ -50,6 +50,7 @@ describe('EthereumSig', () => { | |||
discussion: 'https://snapshot.org', | |||
choices: ['For', 'Against', 'Abstain'], | |||
labels: ['1234e'], | |||
privacy: 'shutter', |
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.
Maybe instead od modifying existing test case we should add new one for shutter privacy (the rest can stay the same).
@@ -128,6 +128,7 @@ export function useEditor() { | |||
discussion: '', | |||
type, | |||
choices, | |||
privacy: '', |
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.
Looks like it doesn't matter there, but if space has configured Shielded voting privacy, and you submit proposal privacy will be ''
.
I tested it and proposal still ends up using Shutter, but it's a bit confusing.
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.
with out privacy
we need to pass this type on a condition 🙈 will add a layer of confusion
maybe we should just pass shutter
by default if space uses shutter?
Summary
Closes: https://github.com/snapshot-labs/workflow/issues/277
How to test