Thanks to visit codestin.com
Credit goes to github.com

Skip to content

希望r-anim对参数里的{}可以进行解析 #61

@DophinL

Description

@DophinL

比如说做一个顶部alert组件,为了一个linear down的动画效果,我希望组件的top值是自身高度的负值,所以自然而然会想到模板是这样的:

<div class="m-alert" r-hide={!show} r-anim="on:enter;class:show,3;style:'top:0';on:leave;class:show,4;style:'top:{top}'">
    <button class="close" on-click={this.close($event)}>&times;</button>
    {#include this.$body || cnt}
</div>

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions