GithubHelp home page GithubHelp logo

quickapp-dsl-vue's People

Contributors

deepkolos avatar diydyq avatar leeeeeem avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

quickapp-dsl-vue's Issues

[bug] animation-fill-mode 对translateX(200%) 以百分比为单位的不生效

animation-fill-mode: forwards;对于百分比单位的transform不生效, 在压入后台再切回前台的时候

hap-animation-fill-mode-percent-bug

.animated-x {
  animation-name: translateX;
  animation-delay: 1s;
  animation-duration: 1s;
  animation-fill-mode: forwards;
  transform: translateX(200%);
}

@keyframes translateX {
  0% {
    transform: translateX(200%);
  }
  100% {
    transform: translateX(0%);
  }
}

复现代码在
https://github.com/deepkolos/todomvc-vue/blob/master/src/pages/animation/index.vue#L19

template行为异常

hap-toolkit手动移除了保留组件列表的template, template可工作, 但是出现异常

const FRAG_TYPE = {
  IMPORT: 'import',
  // TEMPLATE: 'template',
  STYLE: 'style',
  SCRIPT: 'script'
};
<style>
.slot-el {
  margin: 10px;
  background-color: aqua;
  height: 100px;
  width: 100%;
}

.slot-el.typeA {
  background-color: burlywood;
}

.test-slot-el {
  background-color: blueviolet;
}
</style>

<template>
  <div>
    <test-slot v-bind="testSlotProps" :scope="{root}">
      <div class="slot-el" slot-scope="item">
        <text>default文字 {{item.propA}}</text>
      </div>

      <div class="slot-el typeA" slot="before" slot-scope="item">
        <text>before文本 {{item.attr}}</text>
      </div>
      <test-slot-el class="test-slot-el" slot="after" />

      <template slot-scope="item">
        <text>template文字 {{item.propA}}</text>
        <test-slot-el class="test-slot-el" />
        <test-slot-el class="test-slot-el" />
      </template>

      <test-tree slot="bottom" slot-scope="{ root }" v-bind="root" />
    </test-slot>
  </div>
</template>

<script>
import testTree from "../../blocks/test-tree";
import testSlot from "../../blocks/test-slot";
import testSlotEl from "../../blocks/test-slot-el";

export default {
  components: {
    testTree,
    testSlot,
    testSlotEl
  },
  data() {
    return {
      showTpl: true,
      testSlotProps: {
        propA: "string",
        propB: 1
      },
      root: {
        value: "根节点",
        children: [
          {
            value: "节点1",
            children: [
              {
                value: "节点1.1"
              }
            ]
          },
          {
            value: "节点2",
            children: [
              {
                value: "节点2.1"
              }
            ]
          },
          {
            value: "节点3",
            children: []
          }
        ]
      }
    };
  }
};
</script>

显示结果

hap template

异常描述

template部分输出了, 但是default文字 string的节点消失

把template注释后, default文字 string可以正常显示

     <!-- <template slot-scope="item">
        <text>template文字 {{item.propA}}</text>
        <test-slot-el class="test-slot-el" />
        <test-slot-el class="test-slot-el" />
      </template> -->

hap-template-1

list-item 组件在vue dsl渲染异常

<template>
  <div style="flex-direction: column;">
    <list>
      <template v-for="(item, index) in 10">
        <list-item :key="index">
          <text>item: {{ index }}</text>
        </list-item>
      </template>
    </list>
  </div>
</template>

image

不使用v-for指令, 并且添加type和tid后

<template>
  <div style="flex-direction: column;">
    <demo-title>List</demo-title>

    <list>
      <list-item type="item" tid="1">
        <text class="page-container-div">item: 1</text>
      </list-item>
    </list>
  </div>
</template>

image

style属性不能使用模版字符串

这个问题ux里面也有

<style>
.test {
  margin: 100px;
  background-color: aqua;
}
.loading {
  background-color: blueviolet;
}
</style>

<template>
  <test-class :class="`test ${state}`" :style="`background-color: ${bgColor}`" />
</template>

<script>
import testClass from "../../blocks/test-class";

export default {
  components: { testClass },
  data() {
    return {
      state: "loading",
      bgColor: "red"
    };
  }
};
</script>

hap-style-string-template

常见错误汇总

调试器闪退: 保证hap-toolkit版本号大于0.4.1
quickappp-dsls版本号大于0.1.1

build或者调试 命令行添加 --include-dsl-from-lib

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.