-
Notifications
You must be signed in to change notification settings - Fork 32
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
LoAF initial spec #122
LoAF initial spec #122
Conversation
This includes part of the long animation frame spec: - Intro - Security & privacy - Some of the attributes It doesn't include yet: - Scripts - desiredRenderStart - firstUIEventTimestamp Note also that it exports a few algorithms to be called from the HTML spec.
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.
Thanks! A pile of nits :)
index.bs
Outdated
readonly attribute DOMString name; | ||
readonly attribute DOMString entryType; | ||
readonly attribute DOMHighResTimeStamp startTime; | ||
readonly attribute DOMHighResTimeStamp duration; |
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.
You don't need to redefine the attributes that are in PerformanceEntry
index.bs
Outdated
|
||
The {{PerformanceLongAnimationFrameTiming/blockingDuration}} attribute's getter steps are: | ||
|
||
1. Let |workDuration| be [=this=]'s [=this=]'s [=PerformanceLongAnimationFrameTiming/timing info=]'s [=frame timing info/longest task duration=]. |
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.
Spurious "this's"?
index.bs
Outdated
|
||
1. Let |workDuration| be [=this=]'s [=this=]'s [=PerformanceLongAnimationFrameTiming/timing info=]'s [=frame timing info/longest task duration=]. | ||
1. Let |renderDuration| be the 0. | ||
1. If [=this=]'s [=PerformanceLongAnimationFrameTiming/timing info=]'s [=frame timing info=/update the rendering start time=] is not zero, then: |
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.
s/info=/info/
index.bs
Outdated
:: A {{DOMHighResTimeStamp}}, initially 0. | ||
</dl> | ||
|
||
A {{Document}} has a null-or-[=frame timing info=] <dfn>current frame timing info</dfn>, initially null. |
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.
Can we just append a "null-or-" to random structs without defining the whole thing?
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 don't understand
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 seems like your defining a new type named "null-or-frame timing info". But I see a similar pattern in Fetch, only without the "-". Maybe drop them?
index.bs
Outdated
</div> | ||
|
||
<div algorithm="Report task start time"> | ||
To <dfn export>report task start time</dfn> given an {{DOMHighResTimeStamp}} |taskStartTime|, and a {{Document}} |document|: |
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.
s/an/a/
index.bs
Outdated
1. If |root|'s [=current frame timing info=] is null, | ||
then set |root|'s [=current frame timing info=] to a new [=frame timing info=] whose [=frame timing info/start time=] is |taskStartTime|. | ||
|
||
1. Set |timingInfo|'s [=current frame timing info=]'s [=frame timing info/current task start time=] to |taskStartTime|. |
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.
What's |timingInfo| here?
index.bs
Outdated
</div> | ||
|
||
<div algorithm="Queue frame timing"> | ||
To <dfn export>flush frame timing</dfn> given a {{Document}} |document| and a {{DOMHighResTimeStamp}} |endTime|: |
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.
Generally, it might be better to prefix all the unsafe timestamps with "unsafe" (or something similar), rather than prefixing the safe ones.
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.
LGTM % nit
index.bs
Outdated
:: A {{DOMHighResTimeStamp}}, initially 0. | ||
</dl> | ||
|
||
A {{Document}} has a null-or-[=frame timing info=] <dfn>current frame timing info</dfn>, initially null. |
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 seems like your defining a new type named "null-or-frame timing info". But I see a similar pattern in Fetch, only without the "-". Maybe drop them?
This includes part of the long animation frame spec:
It doesn't include yet:
Note also that it exports a few algorithms to be called from the HTML spec.
Preview | Diff