I'm not convinced about this API.  This should be enough to instantiate it:

    var activityPalette = new activitypalette();;

I'll check if I can do better.