-
Notifications
You must be signed in to change notification settings - Fork 31
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
FRAME tweaks for Berkeley #772
Conversation
## Weight for the Pallet | ||
|
||
Or for all calls in the pallet: | ||
|
||
```rust [1] | ||
#[pallet::call(weight(<T as Config>::WeightInfo))] | ||
impl<T: Config> Pallet<T> { | ||
#[pallet::call_index(0)] | ||
pub fn transfer( | ||
origin: OriginFor<T>, | ||
dest: AccountIdLookupOf<T>, | ||
#[pallet::compact] value: T::Balance, | ||
) -> DispatchResult { | ||
let source = ensure_signed(origin)?; | ||
let dest = T::Lookup::lookup(dest)?; | ||
<Self as fungible::Mutate<_>>::transfer(&source, &dest, value, Expendable)?; | ||
Ok(()) | ||
} | ||
} | ||
``` |
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.
These code snippets seem rather dense for a "we'll actually cover this later" mention
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.
@notlesh only a single line is highlighted, which is the "weight" macro up top
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.
I need the larger code to show the difference between where the macro is located between the two options.
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.
👍
|
||
.no-bullet-padding ul, | ||
.no-bullet-padding ul>li::before { | ||
padding: 0 !important; | ||
/* Remove padding */ | ||
margin: 0 !important; | ||
/* Remove margins */ | ||
} |
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.
We want to remove per-module style in favor of global only style, with tweaks for specific elements via tailwind and/or other plugins.
@wirednkod wdyt about this globally? I think someone wanted the opposite earlier... @BradleyOlson64 IIRC
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.
IMO global styling should exist, but each module/lecture should have the capability on overwriting. Having it global is better in order to keep the homogeneity across the slides, but I find it correct to allow the freedom of each lecturer to adjust slides as see fit
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.
I agree "allow the freedom of each lecturer to adjust slides as see fit" is appropriate, but not in a custom CSS for some set of slides, or even a slide deck overall, rather per element settings. If we fic common patterns of use we should abstract them into a compsct form to everyone to use, and demo the in copy&paste templates as a template to build off of for everyone.
So in a single slide, setting a few cols with custom widths and override to get text of code fitting in them would be easy & encouraged. But marking the whole slide deck some custom font and global changes in colors, margin, padding, fonts, etc would be discouraged.
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.
#773 (comment) explained here
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.
I have provided my 2 cents in this #773 (comment)
cc @kianenigma