page-style.uts 2.0 KB
Newer Older
H
hdx 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99

export type PageStyleItem = {
  type : string
  value : UTSJSONObject
}

export const PageStyleMap = new Map<string, PageStyleItem>([
  ["navigationBarBackgroundColor", {
    type: "string",
    value: {
      oldValue: "#F8F8F8",
      newValue: "#F0F0F0",
    }
  } as PageStyleItem],
  ["navigationBarTextStyle", {
    type: "string",
    value: {
      oldValue: "white",
      newValue: "black",
    }
  } as PageStyleItem],
  ["navigationBarTitleText", {
    type: "string",
    value: {
      oldValue: "old title",
      newValue: "new title",
    }
  } as PageStyleItem],
  ["navigationStyle", {
    type: "string",
    value: {
      oldValue: "default",
      newValue: "custom",
    }
  } as PageStyleItem],
  ["backgroundColor", {
    type: "string",
    value: {
      oldValue: "#ffffff",
      newValue: "#000000",
    }
  } as PageStyleItem],
  ["backgroundColorContent", {
    type: "string",
    value: {
      oldValue: "#ffffff",
      newValue: "#000000",
    }
  } as PageStyleItem],
  ["backgroundTextStyle", {
    type: "string",
    value: {
      oldValue: "dark",
      newValue: "light",
    }
  } as PageStyleItem],
  ["enablePullDownRefresh", {
    type: "boolean",
    value: {
      oldValue: true,
      newValue: false,
    }
  } as PageStyleItem],
  ["onReachBottomDistance", {
    type: "number",
    value: {
      oldValue: 50,
      newValue: 100,
    }
  } as PageStyleItem],
  ["pageOrientation", {
    type: "string",
    value: {
      oldValue: "auto",
      newValue: "portrait",
    }
  } as PageStyleItem],
  ["backgroundColorTop", {
    type: "string",
    value: {
      oldValue: "#ffffff",
      newValue: "#000000",
    }
  } as PageStyleItem],
  ["backgroundColorBottom", {
    type: "string",
    value: {
      oldValue: "#ffffff",
      newValue: "#000000",
    }
  } as PageStyleItem],
  ["navigationBarAutoBackButton", {
    type: "boolean",
    value: {
      oldValue: true,
      newValue: false,
    }
  } as PageStyleItem],
])