Click here to Skip to main content
Click here to Skip to main content
Go to top

SharePoint 2013 Web Part ToolPane Tweak

, 25 Jan 2014
Rate this:
Please Sign up or sign in to vote.
5 minute trick


This is a 5 minute trick that - I think - should be done for all branded SharePoint projects, to solve the issue of Web Part Properties Tool Pane.

Instead of disturbing the page with the tool pane when editing the web part, make it fixed to the left and to slide out on hover only!


Using the Code

You only need to copy the CSS classes to your custom styles and the same for the JavaScript:


var IsEditMode = document.forms[MSOWebPartPageFormName].MSOLayout_InDesignMode.value;

if (IsEditMode == "1") {        
        $("form#aspnetForm").append($("<div id='editPanel'>"));
        $("#editPanel").css("height", (innerHeight - 240) + "px");
        $("#MSOTlPn_MainTD").css("width", "0");

        if ($("#MSOTlPn_Tbl").length > 0)
            $("#editPanel").css("min-width", "300px");

        $("#editPanel").animate({ "left": "-320px", "opacity": "1" }, 700);

        $("#editPanel").on("mouseenter", function () {
            $("#MSOTlPn_Tbl").animate({ "opacity": "1" }, 500);
            $(this).animate({ "left": "0" }, 500);

        $("#editPanel").on("mouseleave", function () {
            $("#MSOTlPn_Tbl").animate({ "opacity": "0" }, 500);
            $(this).animate({ "left": "-320px" }, 500);


 #MSOTlPn_Tbl {
    opacity: 0;

#editPanel {    
    opacity: 0;
    border-radius: 5px;
	box-shadow: 0 0 50px #aaa;
	border: 4px solid #74A1FF;
	position: fixed;
	bottom: 25px;
	z-index: 9999;
	left: -320px;
	overflow-y: auto;
	padding: 20px;
	background-color: #fff;

Give it a try!


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Ahmad F Hassan
Software Developer EXCEED IT Services
United Arab Emirates United Arab Emirates
No Biography provided

Comments and Discussions

QuestionGreat Idea, simple implementation PinmemberAndy Taw28-Jan-14 2:39 
AnswerRe: Great Idea, simple implementation PinmemberAhmad F Hassan29-Jan-14 21:21 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Mobile
Web02 | 2.8.140916.1 | Last Updated 25 Jan 2014
Article Copyright 2014 by Ahmad F Hassan
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid