System.register(["cc"], function (_export, _context) {
  "use strict";

  var _cclegacy, _decorator, Component, ScrollView, UIOpacity, tween, Sprite, SpriteFrame, resources, _dec, _dec2, _class, _class2, _descriptor, _temp, _crd, ccclass, property, Typescript;

  function _initializerDefineProperty(target, property, descriptor, context) { if (!descriptor) return; Object.defineProperty(target, property, { enumerable: descriptor.enumerable, configurable: descriptor.configurable, writable: descriptor.writable, value: descriptor.initializer ? descriptor.initializer.call(context) : void 0 }); }

  function _applyDecoratedDescriptor(target, property, decorators, descriptor, context) { var desc = {}; Object.keys(descriptor).forEach(function (key) { desc[key] = descriptor[key]; }); desc.enumerable = !!desc.enumerable; desc.configurable = !!desc.configurable; if ('value' in desc || desc.initializer) { desc.writable = true; } desc = decorators.slice().reverse().reduce(function (desc, decorator) { return decorator(target, property, desc) || desc; }, desc); if (context && desc.initializer !== void 0) { desc.value = desc.initializer ? desc.initializer.call(context) : void 0; desc.initializer = undefined; } if (desc.initializer === void 0) { Object.defineProperty(target, property, desc); desc = null; } return desc; }

  function _initializerWarningHelper(descriptor, context) { throw new Error('Decorating class property failed. Please ensure that ' + 'proposal-class-properties is enabled and runs after the decorators transform.'); }

  return {
    setters: [function (_cc) {
      _cclegacy = _cc.cclegacy;
      _decorator = _cc._decorator;
      Component = _cc.Component;
      ScrollView = _cc.ScrollView;
      UIOpacity = _cc.UIOpacity;
      tween = _cc.tween;
      Sprite = _cc.Sprite;
      SpriteFrame = _cc.SpriteFrame;
      resources = _cc.resources;
    }],
    execute: function () {
      _crd = true;

      _cclegacy._RF.push({}, "a5aedJRAMhAuKDqQQ/jXnnB", "test", undefined);

      ({
        ccclass,
        property
      } = _decorator);

      _export("Typescript", Typescript = (_dec = ccclass('Typescript'), _dec2 = property(ScrollView), _dec(_class = (_class2 = (_temp = class Typescript extends Component {
        constructor(...args) {
          super(...args);

          _initializerDefineProperty(this, "scrollview", _descriptor, this);
        }

        start() {
          let cards = this.scrollview.content.children;

          for (let i = 0; i < cards.length; ++i) {
            let path = "shield/spriteFrame";
            resources.load(path, SpriteFrame, (err, asset) => {
              if (!err) {
                cards[i].getChildByName("shield").getComponent(Sprite).spriteFrame = asset;
              }
            });
          } // opacity = 0,加载图标不显示


          for (let i = 0; i < cards.length; ++i) {
            cards[i].getComponent(UIOpacity).opacity = 0;
            tween(cards[i].getComponent(UIOpacity)).delay(1).to(1, {
              opacity: 255
            }).start();
          } // // opacity = 1，正常
          // for (let i = 0; i < cards.length; ++i) {
          //     cards[i].getComponent(UIOpacity).opacity = 1;
          //     tween(cards[i].getComponent(UIOpacity))
          //         .delay(1)
          //         .to(1, { opacity: 255 })
          //         .start();
          // }
          // // opacity = 0，delay=0.01，正常
          // for (let i = 0; i < cards.length; ++i) {
          //     cards[i].getComponent(UIOpacity).opacity = 0;
          //     tween(cards[i].getComponent(UIOpacity))
          //         .delay(0.01)
          //         .to(1, { opacity: 255 })
          //         .start();
          // }

        }

      }, _temp), (_descriptor = _applyDecoratedDescriptor(_class2.prototype, "scrollview", [_dec2], {
        configurable: true,
        enumerable: true,
        writable: true,
        initializer: function () {
          return null;
        }
      })), _class2)) || _class));

      _cclegacy._RF.pop();

      _crd = false;
    }
  };
});
//# sourceMappingURL=test.js.map