Jump to content

User:Yurik/sandbox2

From Wikipedia, the free encyclopedia


<graph>

{
  "version": 2,
  "data": [{
  	"name": "oneElementDummyList",
  	"values": [null]
  }],
  "signals": [
    {
      "name": "imageUrlSignal",
      "init": null,
      "streams": [
        {"type": "@handle:mousedown","expr": "'wikirawupload://upload.wikimedia.org/wikipedia/en/thumb/0/00/Pablo_Picasso%2C_1901-02%2C_Femme_aux_Bras_Crois%C3%A9s%2C_Woman_with_Folded_Arms_%28Madchenbildnis%29%2C_oil_on_canvas%2C_81_%C3%97_58_cm_%2832_%C3%97_23_in%29.jpg/190px-Pablo_Picasso%2C_1901-02%2C_Femme_aux_Bras_Crois%C3%A9s%2C_Woman_with_Folded_Arms_%28Madchenbildnis%29%2C_oil_on_canvas%2C_81_%C3%97_58_cm_%2832_%C3%97_23_in%29.jpg'"},
        {"type": "mouseup","expr": "null"}
      ]
    }
  ],
  "marks": [
    {
      "name": "handle",
      "type": "path",
      "properties": {
        "enter": {
          "x": {"value": 200},
          "y": {"value": 40},
          "path": {"value": "m-5.5,-10l0,20l11.5,-10l-11.5,-10z"},
          "stroke": {"value": "#880"},
          "strokeWidth": {"value": 2.5}
        },
        "update": {"fill": {"value": "#fff"} },
        "hover": {"fill": {"value": "#f00"} }
      }
    },
    {
      "type": "image",
      "from":  {
      	"data":"oneElementDummyList",
      	"transform": [{"type": "filter", "test": "imageUrlSignal != null"}]
      },
      "properties": {
        "update": {
          "url": { "signal": "imageUrlSignal" },
          "width": {"value": 200},
          "height": {"value": 200}
        }
      }
    }
  ]
}

</graph>