// mycomponent/yz_comment_popup/commentCellItem/commentCellItem.js
Component({
  /**
   * 组件的属性列表
   */
  properties: {
    avatar: {
      type: String,
      value: ""
    },
    nickname: {
      type: String,
      value: ""
    },
    time: {
      type: String,
      value: ""
    },
    content: {
      type: String,
      value: ""
    },
    Responder: {
      type: String,
      value: ""
    },
    index: {
      type: Number,
      value: 0
    },
    childIndex: {
      type: Number,
      value: 0
    }
  },

  /**
   * 组件的初始数据
   */
  data: {

  },

  /**
   * 组件的方法列表
   */
  methods: {
    replyComment() {
      console.log(" =========== 点击二级评论 =============");
      let commentInputOptiones = {
        replyName: this.data.nickname,
        type: "childReply",
        placeholder: "请输入你的回复吧",
        index: this.data.index,
        childIndex: this.data.childIndex,
        content: this.data.content.slice(0, 10) + "..."
      };
      this.triggerEvent('showCOMInput', commentInputOptiones);
    }
  }
});