Re: [Wikitech-l] Maps extension graphical editor.

2012-05-31 Thread Kim Eik
Just did some updates on it, added a slider to handle the opacity fields,
and a color picker for color fields.

On Thu, May 31, 2012 at 11:48 AM, Strainu  wrote:

> Looks like some email bug. :) Let's try without anything behind the URL:
>
>
> http://ec2-46-137-28-172.eu-west-1.compute.amazonaws.com/static/google-draw2.html
>
> 2012/5/31 Daniel Werner :
> > Looks good and helpful to me. One thing not working yet is the marker
> icons
> > switching color when assigned to a group. You could take the markers from
> > the maps extension directly for that.
> >
> > By the way, the url is
> > lwithout
> > the "-" in the end.
> >
> > 2012/5/31 Ole Palnatoke Andersen 
> >
> >> URL correction:
> >>
> >>
> http://ec2-46-137-28-172.eu-west-1.compute.amazonaws.com/static/google-draw2.html-
> >> there was no space between this and "and".
> >>
> >> On Thu, May 31, 2012 at 8:49 AM, Kim Eik  wrote:
> >>
> >> > Hi guys, i have created a simple map editor which works with the Maps
> >> > extension, i'm looking for some feedback on your impression of it.
> >> >
> >> > please take a look @
> >> >
> >> >
> >>
> http://ec2-46-137-28-172.eu-west-1.compute.amazonaws.com/static/google-draw2.htmland
> >> > let me know what you think.
> >> >
> >> > and also, please note it's a work in progress. My idea is to implement
> >> this
> >> > as a special page in the Maps extension so that people can easily
> create
> >> > and edit maps.
> >> >
> >> > Cheers
> >> > Kim
> >> > ___
> >> > Wikitech-l mailing list
> >> > Wikitech-l@lists.wikimedia.org
> >> > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> >> >
> >>
> >>
> >>
> >> --
> >> http://palnatoke.org * @palnatoke * +4522934588
> >> ___
> >> Wikitech-l mailing list
> >> Wikitech-l@lists.wikimedia.org
> >> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> >>
> >
> >
> >
> > --
> > Daniel Werner
> > Software Engineer
> >
> > Wikimedia Deutschland e.V. | NEU: Obentrautstr. 72 | 10963 Berlin
> > Tel. (030) 219 158 26-0
> >
> > http://wikimedia.de
> >
> > Wikimedia Deutschland - Gesellschaft zur Förderung Freien Wissens e.V.
> > Eingetragen im Vereinsregister des Amtsgerichts Berlin-Charlottenburg
> unter
> > der Nummer 23855 B. Als gemeinnützig anerkannt durch das Finanzamt für
> > Körperschaften I Berlin, Steuernummer 27/681/51985.
> > ___
> > Wikitech-l mailing list
> > Wikitech-l@lists.wikimedia.org
> > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
> ___
> Wikitech-l mailing list
> Wikitech-l@lists.wikimedia.org
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


[Wikitech-l] Maps extension graphical editor.

2012-05-30 Thread Kim Eik
Hi guys, i have created a simple map editor which works with the Maps
extension, i'm looking for some feedback on your impression of it.

please take a look @
http://ec2-46-137-28-172.eu-west-1.compute.amazonaws.com/static/google-draw2.htmland
let me know what you think.

and also, please note it's a work in progress. My idea is to implement this
as a special page in the Maps extension so that people can easily create
and edit maps.

Cheers
Kim
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


Re: [Wikitech-l] Patch for gallery tag, review questions.

2012-04-12 Thread Kim Eik
My latest patch reuses regex already defined in Parser.php. please
review @ https://gerrit.wikimedia.org/r/#change,4609

On Thu, Apr 12, 2012 at 10:43 AM, Antoine Musso  wrote:
> Le 12/04/12 08:33, Roan Kattouw a écrit :
> 
>> ZOMG. Anyway, what I'd do if I had a MediaWiki clone handy is look through
>> Sanitizer.php to see if there's anything in there that handles URLs.
>
> Parser.php already has some code when dealing with link= parameter for
> image tags.  That is the code I copy pasted above :-D
>
> --
> Antoine "hashar" Musso
>
>
> ___
> Wikitech-l mailing list
> Wikitech-l@lists.wikimedia.org
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l

___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


[Wikitech-l] Patch for gallery tag, review questions.

2012-04-11 Thread Kim Eik
I have created a patch for the gallery tag and have been given the
following review.

https://gerrit.wikimedia.org/r/4609

* JavaScript injection: you can inject javascript: URIs which execute
code when clicked
* plain links ("link=Firefox") are taken as relative URLs which will
randomly work or not work depending on where they're viewed from
* need parser test cases to demo it working

So my questions are:

What would be the recommended way of stripping away javascript from
uris? Are there any shared functions which do exactly this?
And how would i solve the plain links problem? do a regex check for an
absolute uri? e.g http://example.org/foo/bar?
And what is "parser test cases", phpunit tests? or some other form of testing?

Thank you!
Kim Eik.

___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


Re: [Wikitech-l] Announcing a new extension - SideBarMenu,

2012-03-10 Thread Kim Eik
Do you have a wiki where my extension is used? Would be interesting too see
it in action in a production environment.

-Kim

On Sat, Mar 10, 2012 at 6:49 PM, Alex Brollo  wrote:

> Thank you, we did, but we wrapped the needed  jQuery code into a gadget, so
> that users can set it as a personal preference. Our gadgets are growinig
> and growing in number and performance! :-)
>
> Alex
> ___
> Wikitech-l mailing list
> Wikitech-l@lists.wikimedia.org
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


Re: [Wikitech-l] Announcing a new extension - SideBarMenu,

2012-03-10 Thread Kim Eik
The extension can be customized to your needs by hooking into
the .sidebar-menu-container css class.

setting this to include position: fixed; will get desired result.
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


Re: [Wikitech-l] Announcing a new extension - SideBarMenu,

2012-03-08 Thread Kim Eik
By fixed do you mean the css style position: fixed; ?

On Thu, Mar 8, 2012 at 5:08 PM, Alex Brollo  wrote:

> 2012/3/8 Kim Eik 
>
> > The SideBarMenu simplifies creating multilevel menues.
> >
> > http://www.mediawiki.org/wiki/Extension:SideBarMenu
> >
> > This is my first development project including mediawiki and has been by
> > request of a large oil company in Norway; Statoil.
> >
> > Any feedback of any kind, is appreciated.
> >
>
> Very good!  Thanks!
> Wikisource needs lots of gadgets/tools, youe extension could be inspiring
> and very useful when there's any need to add lots of tools-links into
> SideBarMenu. We found to that sidebar menu is much more comfortable if it
> is fixed so that it doesn't scroll any more when scrolling long texts in
> edit mode.
>
> Alex brollo
> ___
> Wikitech-l mailing list
> Wikitech-l@lists.wikimedia.org
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


[Wikitech-l] Announcing a new extension - SideBarMenu,

2012-03-08 Thread Kim Eik
The SideBarMenu simplifies creating multilevel menues.

http://www.mediawiki.org/wiki/Extension:SideBarMenu

This is my first development project including mediawiki and has been by
request of a large oil company in Norway; Statoil.

Any feedback of any kind, is appreciated.

-Kim
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


Re: [Wikitech-l] How do i allow users of my extension to use their own css file?

2012-03-07 Thread Kim Eik
Ok, thanks.

On Wed, Mar 7, 2012 at 6:14 PM, Chad  wrote:

> If your extension's output has classes or IDs, they can style it in site
> CSS.
>
> -Chad
> On Mar 7, 2012 12:10 PM, "Kim Eik"  wrote:
>
> > Hm i wasn't thinking of individual users of an instance of mediawiki, I
> was
> > thinking more along the lines of how can an admin of an mediawiki
> > installation customize/override default css specified in my extension.
> >
> > Is there any standard way of doing this?
> >
> > On Wed, Mar 7, 2012 at 4:45 PM, Bináris  wrote:
> >
> > > 2012/3/7 Kim Eik 
> > >
> > > > Is there any standard way of doing this?
> > > >
> > >
> > > I guess you should define and document classes in your output, and then
> > > users may make use of these classes as written by alex.
> > >
> > > --
> > > Bináris
> > > ___
> > > Wikitech-l mailing list
> > > Wikitech-l@lists.wikimedia.org
> > > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> > >
> > ___
> > Wikitech-l mailing list
> > Wikitech-l@lists.wikimedia.org
> > https://lists.wikimedia.org/mailman/listinfo/wikitech-l
> >
> ___
> Wikitech-l mailing list
> Wikitech-l@lists.wikimedia.org
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


Re: [Wikitech-l] How do i allow users of my extension to use their own css file?

2012-03-07 Thread Kim Eik
Hm i wasn't thinking of individual users of an instance of mediawiki, I was
thinking more along the lines of how can an admin of an mediawiki
installation customize/override default css specified in my extension.

Is there any standard way of doing this?

On Wed, Mar 7, 2012 at 4:45 PM, Bináris  wrote:

> 2012/3/7 Kim Eik 
>
> > Is there any standard way of doing this?
> >
>
> I guess you should define and document classes in your output, and then
> users may make use of these classes as written by alex.
>
> --
> Bináris
> ___
> Wikitech-l mailing list
> Wikitech-l@lists.wikimedia.org
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
>
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


[Wikitech-l] How do i allow users of my extension to use their own css file?

2012-03-07 Thread Kim Eik
Is there any standard way of doing this?

-Kim
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


Re: [Wikitech-l] Having some trouble figuring out how to approach this problem.

2012-03-07 Thread Kim Eik
Nevermind, i solved it by outputting raw  above my
extension output with my configuration needs. and then i removed my
javascript hook "ResourceLoaderGetConfigVars".

On Wed, Mar 7, 2012 at 12:09 PM, Kim Eik  wrote:

> So just to get things straight, i'm rather new with mediawiki development.
>
> I have created an extension where i hook into the tag , and
> so when this tag is present in the wiki the following method is called:
>
> public static function renderFromTag( $input, array $args, Parser $parser,
> PPFrame $frame )
>
> Now my issue is that i want to publish some $args with certain keys to the
> output as javascript variables so they are available in
> mw.config.get('my-key'). I have tried using $wgOut->addJsConfigVars(..),
> but this doesn't seem to do anything.
>
> i also have the following hook
>
> $wgHooks['ResourceLoaderGetConfigVars'][] =
> 'SideBarMenuHooks::javascriptConfigVars';
>
> which calls this method.
>
> public static function javascriptConfigVars(&$vars).
>
> And this works fine, all variables i add to the $vars is present in
> mw.config.get()...
>
> so how can i pass my  tag parameters to mw.config?
>
> Any help is appreciated.
> Best regards.
> Kim
>
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


[Wikitech-l] Having some trouble figuring out how to approach this problem.

2012-03-07 Thread Kim Eik
So just to get things straight, i'm rather new with mediawiki development.

I have created an extension where i hook into the tag , and so
when this tag is present in the wiki the following method is called:

public static function renderFromTag( $input, array $args, Parser $parser,
PPFrame $frame )

Now my issue is that i want to publish some $args with certain keys to the
output as javascript variables so they are available in
mw.config.get('my-key'). I have tried using $wgOut->addJsConfigVars(..),
but this doesn't seem to do anything.

i also have the following hook

$wgHooks['ResourceLoaderGetConfigVars'][] =
'SideBarMenuHooks::javascriptConfigVars';

which calls this method.

public static function javascriptConfigVars(&$vars).

And this works fine, all variables i add to the $vars is present in
mw.config.get()...

so how can i pass my  tag parameters to mw.config?

Any help is appreciated.
Best regards.
Kim
___
Wikitech-l mailing list
Wikitech-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l